Commit 8b37cc6a authored by Loren Merritt's avatar Loren Merritt

conflate HAVE_MMXEXT with HAVE_SSE2, since they were never used distinctly.


git-svn-id: svn://svn.videolan.org/x264/trunk@634 df754926-b1dd-0310-bc7b-ec298dee348c
parent 11ef32f4
......@@ -41,7 +41,7 @@ RSC=rc.exe
# PROP Intermediate_Dir "Release"
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_MBCS" /D "_LIB" /YX /FD /c
# ADD CPP /nologo /G6 /W3 /GX /O2 /Ob2 /I "./common" /I "./encode" /I "./decode" /I "../../extras" /I "../.." /D "NDEBUG" /D "_LIB" /D "WIN32" /D "_MBCS" /D "__X264__" /D "HAVE_MMXEXT" /D "HAVE_SSE2" /D "ARCH_X86" /D "HAVE_STDINT_H" /FD /c
# ADD CPP /nologo /G6 /W3 /GX /O2 /Ob2 /I "./common" /I "./encode" /I "./decode" /I "../../extras" /I "../.." /D "NDEBUG" /D "_LIB" /D "WIN32" /D "_MBCS" /D "__X264__" /D "HAVE_MMX" /D "ARCH_X86" /D "HAVE_STDINT_H" /FD /c
# SUBTRACT CPP /YX
# ADD BASE RSC /l 0x804 /d "NDEBUG"
# ADD RSC /l 0x804 /d "NDEBUG"
......@@ -65,7 +65,7 @@ LIB32=link.exe -lib
# PROP Intermediate_Dir "Debug"
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_MBCS" /D "_LIB" /YX /FD /GZ /c
# ADD CPP /nologo /W3 /Gm /GX /Zi /Od /I "./common" /I "./encode" /I "./decode" /I "../../extras" /I "../.." /D "_DEBUG" /D "_LIB" /D "WIN32" /D "_MBCS" /D "__X264__" /D "HAVE_MMXEXT" /D "HAVE_SSE2" /D "ARCH_X86" /D "HAVE_STDINT_H" /FD /GZ /c
# ADD CPP /nologo /W3 /Gm /GX /Zi /Od /I "./common" /I "./encode" /I "./decode" /I "../../extras" /I "../.." /D "_DEBUG" /D "_LIB" /D "WIN32" /D "_MBCS" /D "__X264__" /D "HAVE_MMX" /D "ARCH_X86" /D "HAVE_STDINT_H" /FD /GZ /c
# SUBTRACT CPP /YX
# ADD BASE RSC /l 0x804 /d "_DEBUG"
# ADD RSC /l 0x804 /d "_DEBUG"
......
......@@ -25,7 +25,7 @@
InlineFunctionExpansion="2"
OptimizeForProcessor="2"
AdditionalIncludeDirectories="./common,./encode,./decode,../../extras,../.."
PreprocessorDefinitions="NDEBUG;_LIB;WIN32;__X264__;HAVE_MMXEXT;ARCH_X86;HAVE_STDINT_H;HAVE_SSE2"
PreprocessorDefinitions="NDEBUG;_LIB;WIN32;__X264__;HAVE_MMX;ARCH_X86;HAVE_STDINT_H"
StringPooling="TRUE"
RuntimeLibrary="4"
EnableFunctionLevelLinking="TRUE"
......@@ -75,7 +75,7 @@
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="./common,./encode,./decode,../../extras,../.."
PreprocessorDefinitions="_DEBUG;_LIB;WIN32;__X264__;HAVE_MMXEXT;ARCH_X86;HAVE_STDINT_H;HAVE_SSE2"
PreprocessorDefinitions="_DEBUG;_LIB;WIN32;__X264__;HAVE_MMX;ARCH_X86;HAVE_STDINT_H"
BasicRuntimeChecks="3"
RuntimeLibrary="5"
PrecompiledHeaderFile=".\Debug/libx264.pch"
......@@ -127,7 +127,7 @@
InlineFunctionExpansion="2"
OptimizeForProcessor="2"
AdditionalIncludeDirectories="./common,./encode,./decode,../../extras,../.."
PreprocessorDefinitions="NDEBUG;_LIB;WIN32;__X264__;HAVE_MMXEXT;ARCH_X86;HAVE_STDINT_H"
PreprocessorDefinitions="NDEBUG;_LIB;WIN32;__X264__;HAVE_MMX;ARCH_X86;HAVE_STDINT_H"
StringPooling="TRUE"
RuntimeLibrary="4"
EnableFunctionLevelLinking="TRUE"
......
......@@ -42,7 +42,7 @@ RSC=rc.exe
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
# ADD CPP /nologo /W3 /GX /O2 /I "./common" /I "./encode" /I "./decode" /I "../../extras" /I "../.." /D "NDEBUG" /D "_CONSOLE" /D "WIN32" /D "_MBCS" /D "__X264__" /D "HAVE_MMXEXT" /D "HAVE_SSE2" /D "HAVE_STDINT_H" /YX /FD /c
# ADD CPP /nologo /W3 /GX /O2 /I "./common" /I "./encode" /I "./decode" /I "../../extras" /I "../.." /D "NDEBUG" /D "_CONSOLE" /D "WIN32" /D "_MBCS" /D "__X264__" /D "HAVE_MMX" /D "HAVE_STDINT_H" /YX /FD /c
# ADD BASE RSC /l 0x804 /d "NDEBUG"
# ADD RSC /l 0x804 /d "NDEBUG"
BSC32=bscmake.exe
......@@ -66,7 +66,7 @@ LINK32=link.exe
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
# ADD CPP /nologo /W3 /Gm /GX /Zi /Od /I "../../common" /I "../../encode" /I "../../decode" /I "../../extras" /I "../.." /D "_DEBUG" /D "_CONSOLE" /D "WIN32" /D "_MBCS" /D "__X264__" /D "HAVE_MMXEXT" /D "HAVE_SSE2" /D "HAVE_STDINT_H" /YX /FD /GZ /c
# ADD CPP /nologo /W3 /Gm /GX /Zi /Od /I "../../common" /I "../../encode" /I "../../decode" /I "../../extras" /I "../.." /D "_DEBUG" /D "_CONSOLE" /D "WIN32" /D "_MBCS" /D "__X264__" /D "HAVE_MMX" /D "HAVE_STDINT_H" /YX /FD /GZ /c
# ADD BASE RSC /l 0x804 /d "_DEBUG"
# ADD RSC /l 0x804 /d "_DEBUG"
BSC32=bscmake.exe
......
......@@ -23,7 +23,7 @@
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="../../common;../../encode;../../decode;../../extras;../..;L:\gpac\include"
PreprocessorDefinitions="_DEBUG;_CONSOLE;WIN32;__X264__;HAVE_MMXEXT;HAVE_STDINT_H;AVIS_INPUT"
PreprocessorDefinitions="_DEBUG;_CONSOLE;WIN32;__X264__;HAVE_MMX;HAVE_STDINT_H;AVIS_INPUT"
BasicRuntimeChecks="3"
RuntimeLibrary="5"
UsePrecompiledHeader="2"
......@@ -85,7 +85,7 @@
Optimization="2"
InlineFunctionExpansion="1"
AdditionalIncludeDirectories="./common;./encode;./decode;../../extras;../..;L:\gpac\include"
PreprocessorDefinitions="NDEBUG;_CONSOLE;WIN32;__X264__;HAVE_MMXEXT;HAVE_STDINT_H;AVIS_INPUT"
PreprocessorDefinitions="NDEBUG;_CONSOLE;WIN32;__X264__;HAVE_MMX;HAVE_STDINT_H;AVIS_INPUT"
StringPooling="TRUE"
RuntimeLibrary="0"
EnableFunctionLevelLinking="TRUE"
......@@ -146,7 +146,7 @@
Optimization="2"
InlineFunctionExpansion="1"
AdditionalIncludeDirectories="./common;./encode;./decode;../../extras;../..;..\..\..\gpac\include"
PreprocessorDefinitions="NDEBUG;_CONSOLE;WIN32;__X264__;HAVE_MMXEXT;HAVE_STDINT_H;AVIS_INPUT;MP4_OUTPUT"
PreprocessorDefinitions="NDEBUG;_CONSOLE;WIN32;__X264__;HAVE_MMX;HAVE_STDINT_H;AVIS_INPUT;MP4_OUTPUT"
StringPooling="TRUE"
RuntimeLibrary="0"
EnableFunctionLevelLinking="TRUE"
......
......@@ -49,6 +49,9 @@ uint32_t x264_cpu_detect( void )
uint32_t eax, ebx, ecx, edx;
int b_amd;
#ifndef HAVE_MMX
return 0;
#endif
if( !x264_cpu_cpuid_test() )
{
......
......@@ -22,7 +22,7 @@
*****************************************************************************/
#include "common.h"
#ifdef HAVE_MMXEXT
#ifdef HAVE_MMX
# include "i386/dct.h"
#endif
#ifdef ARCH_PPC
......@@ -398,7 +398,7 @@ void x264_dct_init( int cpu, x264_dct_function_t *dctf )
dctf->dct2x2dc = dct2x2dc;
dctf->idct2x2dc = dct2x2dc;
#ifdef HAVE_MMXEXT
#ifdef HAVE_MMX
if( cpu&X264_CPU_MMX )
{
dctf->sub4x4_dct = x264_sub4x4_dct_mmx;
......@@ -420,9 +420,8 @@ void x264_dct_init( int cpu, x264_dct_function_t *dctf )
dctf->add16x16_idct8= x264_add16x16_idct8_mmx;
#endif
}
#endif
#if defined(HAVE_SSE2) && defined(ARCH_X86_64)
#ifdef ARCH_X86_64
if( cpu&X264_CPU_SSE2 )
{
dctf->sub8x8_dct8 = x264_sub8x8_dct8_sse2;
......@@ -432,6 +431,7 @@ void x264_dct_init( int cpu, x264_dct_function_t *dctf )
dctf->add16x16_idct8= x264_add16x16_idct8_sse2;
}
#endif
#endif //HAVE_MMX
#ifdef ARCH_PPC
if( cpu&X264_CPU_ALTIVEC )
......@@ -588,13 +588,15 @@ void x264_zigzag_init( int cpu, x264_zigzag_function_t *pf, int b_interlaced )
pf->scan_4x4ac = zigzag_scan_4x4ac_field;
pf->sub_4x4 = zigzag_sub_4x4_field;
pf->sub_4x4ac = zigzag_sub_4x4ac_field;
#if defined(HAVE_MMXEXT) && defined(ARCH_X86)
#ifdef HAVE_MMX
#ifdef ARCH_X86
if( cpu&X264_CPU_MMX )
pf->scan_4x4 = x264_zigzag_scan_4x4_field_mmx;
#endif
#if defined(HAVE_SSE2) && defined(ARCH_X86_64)
#ifdef ARCH_X86_64
if( cpu&X264_CPU_SSE2 )
pf->scan_4x4 = x264_zigzag_scan_4x4_field_sse2;
#endif
#endif
}
else
......
......@@ -703,7 +703,7 @@ void x264_frame_deblock( x264_t *h )
x264_frame_deblock_row( h, mb_y );
}
#ifdef HAVE_MMXEXT
#ifdef HAVE_MMX
void x264_deblock_v_chroma_mmxext( uint8_t *pix, int stride, int alpha, int beta, int8_t *tc0 );
void x264_deblock_h_chroma_mmxext( uint8_t *pix, int stride, int alpha, int beta, int8_t *tc0 );
void x264_deblock_v_chroma_intra_mmxext( uint8_t *pix, int stride, int alpha, int beta );
......@@ -735,7 +735,7 @@ void x264_deblock_init( int cpu, x264_deblock_function_t *pf )
pf->deblock_v_chroma_intra = deblock_v_chroma_intra_c;
pf->deblock_h_chroma_intra = deblock_h_chroma_intra_c;
#ifdef HAVE_MMXEXT
#ifdef HAVE_MMX
if( cpu&X264_CPU_MMXEXT )
{
pf->deblock_v_chroma = x264_deblock_v_chroma_mmxext;
......
......@@ -27,7 +27,7 @@
#include "common.h"
#include "clip1.h"
#ifdef HAVE_MMXEXT
#ifdef HAVE_MMX
#include "i386/mc.h"
#endif
#ifdef ARCH_PPC
......@@ -371,13 +371,11 @@ void x264_mc_init( int cpu, x264_mc_functions_t *pf )
pf->prefetch_fenc = prefetch_fenc_null;
pf->prefetch_ref = prefetch_ref_null;
#ifdef HAVE_MMXEXT
#ifdef HAVE_MMX
if( cpu&X264_CPU_MMXEXT ) {
x264_mc_mmxext_init( pf );
pf->mc_chroma = x264_mc_chroma_mmxext;
}
#endif
#ifdef HAVE_SSE2
if( cpu&X264_CPU_SSE2 )
x264_mc_sse2_init( pf );
#endif
......@@ -402,7 +400,7 @@ void x264_frame_filter( int cpu, x264_frame_t *frame, int b_interlaced, int mb_y
return;
mb_y >>= b_interlaced;
#ifdef HAVE_MMXEXT
#ifdef HAVE_MMX
if ( cpu & X264_CPU_MMXEXT )
{
// buffer = 4 for deblock + 3 for 6tap, rounded to 8
......
......@@ -26,7 +26,7 @@
#include "common.h"
#include "clip1.h"
#ifdef HAVE_MMXEXT
#ifdef HAVE_MMX
# include "i386/pixel.h"
#endif
#ifdef ARCH_PPC
......@@ -470,7 +470,7 @@ void x264_pixel_init( int cpu, x264_pixel_function_t *pixf )
pixf->ads[PIXEL_16x8] = pixel_ads2;
pixf->ads[PIXEL_8x8] = pixel_ads1;
#ifdef HAVE_MMXEXT
#ifdef HAVE_MMX
if( cpu&X264_CPU_MMX )
{
INIT( ssd, _mmx );
......@@ -501,9 +501,7 @@ void x264_pixel_init( int cpu, x264_pixel_function_t *pixf )
pixf->intra_satd_x3_8x8c = x264_intra_satd_x3_8x8c_mmxext;
pixf->intra_satd_x3_4x4 = x264_intra_satd_x3_4x4_mmxext;
}
#endif
#ifdef HAVE_SSE2
// disable on AMD processors since it is slower
if( (cpu&X264_CPU_SSE2) && !(cpu&X264_CPU_3DNOW) )
{
......@@ -551,7 +549,7 @@ void x264_pixel_init( int cpu, x264_pixel_function_t *pixf )
pixf->sa8d[PIXEL_8x8] = x264_pixel_sa8d_8x8_ssse3;
#endif
}
#endif
#endif //HAVE_MMX
#ifdef ARCH_PPC
if( cpu&X264_CPU_ALTIVEC )
......
......@@ -29,9 +29,9 @@
#include "clip1.h"
#ifdef _MSC_VER
#undef HAVE_MMXEXT /* not finished now */
#undef HAVE_MMX /* not finished now */
#endif
#ifdef HAVE_MMXEXT
#ifdef HAVE_MMX
# include "i386/predict.h"
#endif
......@@ -843,7 +843,7 @@ void x264_predict_16x16_init( int cpu, x264_predict_t pf[7] )
pf[I_PRED_16x16_DC_TOP ]= predict_16x16_dc_top;
pf[I_PRED_16x16_DC_128 ]= predict_16x16_dc_128;
#ifdef HAVE_MMXEXT
#ifdef HAVE_MMX
if( cpu&X264_CPU_MMXEXT )
{
x264_predict_16x16_init_mmxext( pf );
......@@ -861,7 +861,7 @@ void x264_predict_8x8c_init( int cpu, x264_predict_t pf[7] )
pf[I_PRED_CHROMA_DC_TOP ]= predict_8x8c_dc_top;
pf[I_PRED_CHROMA_DC_128 ]= predict_8x8c_dc_128;
#ifdef HAVE_MMXEXT
#ifdef HAVE_MMX
if( cpu&X264_CPU_MMXEXT )
{
x264_predict_8x8c_init_mmxext( pf );
......@@ -884,13 +884,11 @@ void x264_predict_8x8_init( int cpu, x264_predict8x8_t pf[12] )
pf[I_PRED_8x8_DC_TOP] = predict_8x8_dc_top;
pf[I_PRED_8x8_DC_128] = predict_8x8_dc_128;
#ifdef HAVE_MMXEXT
#ifdef HAVE_MMX
if( cpu&X264_CPU_MMXEXT )
{
x264_predict_8x8_init_mmxext( pf );
}
#endif
#ifdef HAVE_SSE2
if( cpu&X264_CPU_SSE2 )
{
x264_predict_8x8_init_sse2( pf );
......@@ -913,7 +911,7 @@ void x264_predict_4x4_init( int cpu, x264_predict_t pf[12] )
pf[I_PRED_4x4_DC_TOP] = predict_4x4_dc_top;
pf[I_PRED_4x4_DC_128] = predict_4x4_dc_128;
#ifdef HAVE_MMXEXT
#ifdef HAVE_MMX
if( cpu&X264_CPU_MMXEXT )
{
x264_predict_4x4_init_mmxext( pf );
......
......@@ -22,7 +22,7 @@
#include "common.h"
#ifdef HAVE_MMXEXT
#ifdef HAVE_MMX
#include "i386/quant.h"
#endif
#ifdef ARCH_PPC
......@@ -226,7 +226,7 @@ void x264_quant_init( x264_t *h, int cpu, x264_quant_function_t *pf )
maxQdc = q;
}
#ifdef HAVE_MMXEXT
#ifdef HAVE_MMX
/* select quant_8x8 based on CPU and maxQ8 */
#if defined(ARCH_X86_64) && defined(HAVE_SSE3)
......@@ -290,7 +290,7 @@ void x264_quant_init( x264_t *h, int cpu, x264_quant_function_t *pf )
pf->dequant_4x4 = x264_dequant_4x4_mmx;
pf->dequant_8x8 = x264_dequant_8x8_mmx;
}
#endif /* HAVE_MMXEXT */
#endif /* HAVE_MMX */
#ifdef ARCH_PPC
if( cpu&X264_CPU_ALTIVEC ) {
......
......@@ -147,7 +147,7 @@ esac
case "${MACHINE%%-*}" in
i*86)
ARCH="X86"
CFLAGS="$CFLAGS -DHAVE_MMXEXT -DHAVE_SSE2"
CFLAGS="$CFLAGS -DHAVE_MMX"
AS="nasm"
ASFLAGS="-O2"
if [ "$SYS" = MACOSX ]; then
......@@ -162,7 +162,7 @@ case "${MACHINE%%-*}" in
;;
x86_64)
ARCH="X86_64"
CFLAGS="$CFLAGS -DHAVE_MMXEXT -DHAVE_SSE2"
CFLAGS="$CFLAGS -DHAVE_MMX"
AS="yasm"
ASFLAGS="-f elf -m amd64"
;;
......
......@@ -5,7 +5,7 @@
#include "common/common.h"
#include "common/cpu.h"
#ifdef HAVE_MMXEXT
#ifdef HAVE_MMX
#include "common/i386/pixel.h"
#include "common/i386/dct.h"
#include "common/i386/mc.h"
......@@ -758,11 +758,11 @@ int main(int argc, char *argv[])
buf3[i] = buf4[i] = 0;
}
#ifdef HAVE_MMXEXT
#ifdef HAVE_MMX
fprintf( stderr, "x264: MMXEXT against C\n" );
cpu1 = X264_CPU_MMX | X264_CPU_MMXEXT;
ret = check_all( 0, cpu1 );
#ifdef HAVE_SSE2
if( x264_cpu_detect() & X264_CPU_SSE2 )
{
fprintf( stderr, "\nx264: SSE2 against C\n" );
......@@ -778,7 +778,6 @@ int main(int argc, char *argv[])
ret |= check_all( cpu0, cpu1 );
}
}
#endif
#elif ARCH_PPC
if( x264_cpu_detect() & X264_CPU_ALTIVEC )
{
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment