#if FFT_FIXED_32
#include "fft_table.h"
-
-static void av_cold fft_lut_init(void)
-{
- int n = 0;
- ff_fft_lut_init(ff_fft_offsets_lut, 0, 1 << 17, &n);
-}
-
#else /* FFT_FIXED_32 */
/* cos(2*pi*x/n) for 0<=x<=n/4, followed by its reverse */
{ init_ff_cos_tabs_131072, AV_ONCE_INIT },
};
+av_cold void ff_init_ff_cos_tabs(int index)
+{
+ ff_thread_once(&cos_tabs_init_once[index].control, cos_tabs_init_once[index].func);
+}
#endif
COSTABLE_CONST FFTSample * const FFT_NAME(ff_cos_tabs)[] = {
NULL, NULL, NULL, NULL,
else return split_radix_permutation(i, m, inverse)*4 - 1;
}
-av_cold void ff_init_ff_cos_tabs(int index)
-{
-#if (!CONFIG_HARDCODED_TABLES) && (!FFT_FIXED_32)
- ff_thread_once(&cos_tabs_init_once[index].control, cos_tabs_init_once[index].func);
-#endif
-}
static const int avx_tab[] = {
0, 4, 1, 5, 8, 12, 9, 13, 2, 6, 3, 7, 10, 14, 11, 15
#endif
#if FFT_FIXED_32
- {
- static AVOnce control = AV_ONCE_INIT;
- ff_thread_once(&control, fft_lut_init);
- }
+ ff_fft_lut_init();
#else /* FFT_FIXED_32 */
#if FFT_FLOAT
if (ARCH_AARCH64) ff_fft_init_aarch64(s);
if (ARCH_ARM) ff_fft_init_arm(s);
if (ARCH_PPC) ff_fft_init_ppc(s);
if (ARCH_X86) ff_fft_init_x86(s);
- if (CONFIG_MDCT) s->mdct_calcw = s->mdct_calc;
if (HAVE_MIPSFPU) ff_fft_init_mips(s);
-#else
- if (CONFIG_MDCT) s->mdct_calcw = ff_mdct_calcw_c;
- if (ARCH_ARM) ff_fft_fixed_init_arm(s);
#endif
for(j=4; j<=nbits; j++) {
ff_init_ff_cos_tabs(j);
#endif /* FFT_FIXED_32 */
- if (s->fft_permutation == FF_FFT_PERM_AVX) {
+ if (ARCH_X86 && FFT_FLOAT && s->fft_permutation == FF_FFT_PERM_AVX) {
fft_perm_avx(s);
} else {
#define PROCESS_FFT_PERM_SWAP_LSBS(num) do {\