Commit f4406ec1 authored by Diego Biurrun's avatar Diego Biurrun

HAVE_3DNOW --> HAVE_AMD3DNOW to sync with latest configure changes.

Originally committed as revision 28358 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale
parent ebc3209a
......@@ -139,11 +139,11 @@ DECLARE_ASM_CONST(8, uint64_t, blue_15mask) = 0x0000001f0000001fULL;
//plain C versions
#undef HAVE_MMX
#undef HAVE_MMX2
#undef HAVE_3DNOW
#undef HAVE_AMD3DNOW
#undef HAVE_SSE2
#define HAVE_MMX 0
#define HAVE_MMX2 0
#define HAVE_3DNOW 0
#define HAVE_AMD3DNOW 0
#define HAVE_SSE2 0
#define RENAME(a) a ## _C
#include "rgb2rgb_template.c"
......@@ -167,9 +167,9 @@ DECLARE_ASM_CONST(8, uint64_t, blue_15mask) = 0x0000001f0000001fULL;
//3DNOW versions
#undef RENAME
#undef HAVE_MMX2
#undef HAVE_3DNOW
#undef HAVE_AMD3DNOW
#define HAVE_MMX2 0
#define HAVE_3DNOW 1
#define HAVE_AMD3DNOW 1
#define RENAME(a) a ## _3DNOW
#include "rgb2rgb_template.c"
......@@ -183,7 +183,7 @@ DECLARE_ASM_CONST(8, uint64_t, blue_15mask) = 0x0000001f0000001fULL;
*/
void sws_rgb2rgb_init(int flags){
#if (HAVE_MMX2 || HAVE_3DNOW || HAVE_MMX) && CONFIG_GPL
#if (HAVE_MMX2 || HAVE_AMD3DNOW || HAVE_MMX) && CONFIG_GPL
if (flags & SWS_CPU_CAPS_MMX2)
rgb2rgb_init_MMX2();
else if (flags & SWS_CPU_CAPS_3DNOW)
......@@ -191,7 +191,7 @@ void sws_rgb2rgb_init(int flags){
else if (flags & SWS_CPU_CAPS_MMX)
rgb2rgb_init_MMX();
else
#endif /* HAVE_MMX2 || HAVE_3DNOW || HAVE_MMX */
#endif /* HAVE_MMX2 || HAVE_AMD3DNOW || HAVE_MMX */
rgb2rgb_init_C();
}
......
......@@ -43,7 +43,7 @@
#define MMREG_SIZE 8
#endif
#if HAVE_3DNOW
#if HAVE_AMD3DNOW
#define PREFETCH "prefetch"
#define PREFETCHW "prefetchw"
#define PAVGB "pavgusb"
......@@ -56,7 +56,7 @@
#define PREFETCHW " # nop"
#endif
#if HAVE_3DNOW
#if HAVE_AMD3DNOW
/* On K6 femms is faster than emms. On K7 femms is directly mapped to emms. */
#define EMMS "femms"
#else
......@@ -1914,7 +1914,7 @@ static inline void RENAME(planar2x)(const uint8_t *src, uint8_t *dst, long srcWi
dst+= dstStride;
for (y=1; y<srcHeight; y++){
#if HAVE_MMX2 || HAVE_3DNOW
#if HAVE_MMX2 || HAVE_AMD3DNOW
const long mmxSize= srcWidth&~15;
__asm__ volatile(
"mov %4, %%"REG_a" \n\t"
......@@ -2229,7 +2229,7 @@ static inline void RENAME(rgb24toyv12)(const uint8_t *src, uint8_t *ydst, uint8_
"1: \n\t"
PREFETCH" 64(%0, %%"REG_d") \n\t"
PREFETCH" 64(%1, %%"REG_d") \n\t"
#if HAVE_MMX2 || HAVE_3DNOW
#if HAVE_MMX2 || HAVE_AMD3DNOW
"movq (%0, %%"REG_d"), %%mm0 \n\t"
"movq (%1, %%"REG_d"), %%mm1 \n\t"
"movq 6(%0, %%"REG_d"), %%mm2 \n\t"
......@@ -2290,7 +2290,7 @@ static inline void RENAME(rgb24toyv12)(const uint8_t *src, uint8_t *ydst, uint8_
"packssdw %%mm1, %%mm0 \n\t" // V1 V0 U1 U0
"psraw $7, %%mm0 \n\t"
#if HAVE_MMX2 || HAVE_3DNOW
#if HAVE_MMX2 || HAVE_AMD3DNOW
"movq 12(%0, %%"REG_d"), %%mm4 \n\t"
"movq 12(%1, %%"REG_d"), %%mm1 \n\t"
"movq 18(%0, %%"REG_d"), %%mm2 \n\t"
......
......@@ -83,7 +83,7 @@ unsigned swscale_version(void)
#undef PAVGB
//#undef HAVE_MMX2
//#define HAVE_3DNOW
//#define HAVE_AMD3DNOW
//#undef HAVE_MMX
//#undef ARCH_X86
//#define WORDS_BIGENDIAN
......@@ -968,7 +968,7 @@ static inline void yuv2rgbXinC_full(SwsContext *c, int16_t *lumFilter, int16_t *
#if ARCH_X86
#if ((HAVE_MMX && !HAVE_3DNOW && !HAVE_MMX2) || defined (RUNTIME_CPUDETECT)) && CONFIG_GPL
#if ((HAVE_MMX && !HAVE_AMD3DNOW && !HAVE_MMX2) || defined (RUNTIME_CPUDETECT)) && CONFIG_GPL
#define COMPILE_MMX
#endif
......@@ -976,18 +976,18 @@ static inline void yuv2rgbXinC_full(SwsContext *c, int16_t *lumFilter, int16_t *
#define COMPILE_MMX2
#endif
#if ((HAVE_3DNOW && !HAVE_MMX2) || defined (RUNTIME_CPUDETECT)) && CONFIG_GPL
#if ((HAVE_AMD3DNOW && !HAVE_MMX2) || defined (RUNTIME_CPUDETECT)) && CONFIG_GPL
#define COMPILE_3DNOW
#endif
#endif //ARCH_X86
#undef HAVE_MMX
#undef HAVE_MMX2
#undef HAVE_3DNOW
#undef HAVE_AMD3DNOW
#undef HAVE_ALTIVEC
#define HAVE_MMX 0
#define HAVE_MMX2 0
#define HAVE_3DNOW 0
#define HAVE_AMD3DNOW 0
#define HAVE_ALTIVEC 0
#ifdef COMPILE_C
......@@ -1010,7 +1010,7 @@ static inline void yuv2rgbXinC_full(SwsContext *c, int16_t *lumFilter, int16_t *
#undef RENAME
#undef HAVE_MMX
#undef HAVE_MMX2
#undef HAVE_3DNOW
#undef HAVE_AMD3DNOW
#define ARCH_X86
#define RENAME(a) a ## _X86
#include "swscale_template.c"
......@@ -1020,10 +1020,10 @@ static inline void yuv2rgbXinC_full(SwsContext *c, int16_t *lumFilter, int16_t *
#undef RENAME
#undef HAVE_MMX
#undef HAVE_MMX2
#undef HAVE_3DNOW
#undef HAVE_AMD3DNOW
#define HAVE_MMX 1
#define HAVE_MMX2 0
#define HAVE_3DNOW 0
#define HAVE_AMD3DNOW 0
#define RENAME(a) a ## _MMX
#include "swscale_template.c"
#endif
......@@ -1033,10 +1033,10 @@ static inline void yuv2rgbXinC_full(SwsContext *c, int16_t *lumFilter, int16_t *
#undef RENAME
#undef HAVE_MMX
#undef HAVE_MMX2
#undef HAVE_3DNOW
#undef HAVE_AMD3DNOW
#define HAVE_MMX 1
#define HAVE_MMX2 1
#define HAVE_3DNOW 0
#define HAVE_AMD3DNOW 0
#define RENAME(a) a ## _MMX2
#include "swscale_template.c"
#endif
......@@ -1046,10 +1046,10 @@ static inline void yuv2rgbXinC_full(SwsContext *c, int16_t *lumFilter, int16_t *
#undef RENAME
#undef HAVE_MMX
#undef HAVE_MMX2
#undef HAVE_3DNOW
#undef HAVE_AMD3DNOW
#define HAVE_MMX 1
#define HAVE_MMX2 0
#define HAVE_3DNOW 1
#define HAVE_AMD3DNOW 1
#define RENAME(a) a ## _3DNow
#include "swscale_template.c"
#endif
......@@ -1661,7 +1661,7 @@ static SwsFunc getSwsFunc(int flags){
#else //RUNTIME_CPUDETECT
#if HAVE_MMX2
return swScale_MMX2;
#elif HAVE_3DNOW
#elif HAVE_AMD3DNOW
return swScale_3DNow;
#elif HAVE_MMX
return swScale_MMX;
......@@ -2198,7 +2198,7 @@ SwsContext *sws_getContext(int srcW, int srcH, enum PixelFormat srcFormat, int d
flags &= ~(SWS_CPU_CAPS_MMX|SWS_CPU_CAPS_MMX2|SWS_CPU_CAPS_3DNOW|SWS_CPU_CAPS_ALTIVEC|SWS_CPU_CAPS_BFIN);
#if HAVE_MMX2
flags |= SWS_CPU_CAPS_MMX|SWS_CPU_CAPS_MMX2;
#elif HAVE_3DNOW
#elif HAVE_AMD3DNOW
flags |= SWS_CPU_CAPS_MMX|SWS_CPU_CAPS_3DNOW;
#elif HAVE_MMX
flags |= SWS_CPU_CAPS_MMX;
......
......@@ -29,14 +29,14 @@
#undef EMMS
#undef SFENCE
#if HAVE_3DNOW
#if HAVE_AMD3DNOW
/* On K6 femms is faster than emms. On K7 femms is directly mapped to emms. */
#define EMMS "femms"
#else
#define EMMS "emms"
#endif
#if HAVE_3DNOW
#if HAVE_AMD3DNOW
#define PREFETCH "prefetch"
#define PREFETCHW "prefetchw"
#elif HAVE_MMX2
......@@ -55,7 +55,7 @@
#if HAVE_MMX2
#define PAVGB(a,b) "pavgb " #a ", " #b " \n\t"
#elif HAVE_3DNOW
#elif HAVE_AMD3DNOW
#define PAVGB(a,b) "pavgusb " #a ", " #b " \n\t"
#endif
......
......@@ -55,9 +55,9 @@ DECLARE_ASM_CONST(8, uint64_t, mmx_grnmask) = 0xfcfcfcfcfcfcfcfcULL;
//MMX versions
#undef RENAME
#undef HAVE_MMX2
#undef HAVE_3DNOW
#undef HAVE_AMD3DNOW
#define HAVE_MMX2 0
#define HAVE_3DNOW 0
#define HAVE_AMD3DNOW 0
#define RENAME(a) a ## _MMX
#include "yuv2rgb_template.c"
......
......@@ -30,7 +30,7 @@
#undef EMMS
#undef SFENCE
#if HAVE_3DNOW
#if HAVE_AMD3DNOW
/* On K6 femms is faster than emms. On K7 femms is directly mapped to emms. */
#define EMMS "femms"
#else
......
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