x86/synth_filter: add synth_filter_avx

Sandy Bridge Win64:
180 cycles in ff_synth_filter_inner_sse2
150 cycles in ff_synth_filter_inner_avx

Also switch some instructions to a three operand format to avoid
assembly errors with Yasm 1.1.0 or older.

Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Anton Khirnov <anton@khirnov.net>
This commit is contained in:
James Almer
2014-03-20 15:37:55 -03:00
committed by Anton Khirnov
parent 2025d8026f
commit 81e02fae6e
2 changed files with 57 additions and 32 deletions

View File

@@ -81,6 +81,7 @@ static void synth_filter_##opt(FFTContext *imdct, \
SYNTH_FILTER_FUNC(sse)
#endif
SYNTH_FILTER_FUNC(sse2)
SYNTH_FILTER_FUNC(avx)
#endif /* HAVE_YASM */
av_cold void ff_synth_filter_init_x86(SynthFilterContext *s)
@@ -96,5 +97,8 @@ av_cold void ff_synth_filter_init_x86(SynthFilterContext *s)
if (EXTERNAL_SSE2(cpu_flags)) {
s->synth_filter_float = synth_filter_sse2;
}
if (EXTERNAL_AVX(cpu_flags)) {
s->synth_filter_float = synth_filter_avx;
}
#endif /* HAVE_YASM */
}