diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2013-11-19 14:46:01 +0100 |
---|---|---|
committer | Anton Khirnov <anton@khirnov.net> | 2014-01-21 18:01:29 +0100 |
commit | 7597e6efe492cb2449bb771054d64cc7fdf62ff5 (patch) | |
tree | 82b6ef044935f05591281b2c791adaa9fc410558 /libswscale/x86/rgb2rgb.c | |
parent | 9047491f8bcd87673eed55fb310647a03b0981e9 (diff) | |
download | ffmpeg-7597e6efe492cb2449bb771054d64cc7fdf62ff5.tar.gz |
swscale/x86/rgb2rgb: add support for AVX
This does not yet include any actual AVX code
Signed-off-by: Anton Khirnov <anton@khirnov.net>
Diffstat (limited to 'libswscale/x86/rgb2rgb.c')
-rw-r--r-- | libswscale/x86/rgb2rgb.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/libswscale/x86/rgb2rgb.c b/libswscale/x86/rgb2rgb.c index 98cf1ff697..9cfe831e3c 100644 --- a/libswscale/x86/rgb2rgb.c +++ b/libswscale/x86/rgb2rgb.c @@ -89,6 +89,7 @@ DECLARE_ASM_CONST(8, uint64_t, blue_15mask) = 0x0000001f0000001fULL; #define COMPILE_TEMPLATE_MMXEXT 0 #define COMPILE_TEMPLATE_AMD3DNOW 0 #define COMPILE_TEMPLATE_SSE2 0 +#define COMPILE_TEMPLATE_AVX 0 //MMX versions #undef RENAME @@ -109,10 +110,18 @@ DECLARE_ASM_CONST(8, uint64_t, blue_15mask) = 0x0000001f0000001fULL; #define RENAME(a) a ## _sse2 #include "rgb2rgb_template.c" +//AVX versions +#undef RENAME +#undef COMPILE_TEMPLATE_AVX +#define COMPILE_TEMPLATE_AVX 1 +#define RENAME(a) a ## _avx +#include "rgb2rgb_template.c" + //3DNOW versions #undef RENAME #undef COMPILE_TEMPLATE_MMXEXT #undef COMPILE_TEMPLATE_SSE2 +#undef COMPILE_TEMPLATE_AVX #undef COMPILE_TEMPLATE_AMD3DNOW #define COMPILE_TEMPLATE_MMXEXT 0 #define COMPILE_TEMPLATE_SSE2 0 @@ -142,5 +151,7 @@ av_cold void rgb2rgb_init_x86(void) rgb2rgb_init_mmxext(); if (INLINE_SSE2(cpu_flags)) rgb2rgb_init_sse2(); + if (INLINE_AVX(cpu_flags)) + rgb2rgb_init_avx(); #endif /* HAVE_INLINE_ASM */ } |