summaryrefslogtreecommitdiff
path: root/libavutil/tx_priv.h
diff options
context:
space:
mode:
authorLynne <dev@lynne.ee>2021-02-27 04:11:04 +0100
committerLynne <dev@lynne.ee>2021-02-27 04:21:05 +0100
commit8e94b7cff03539bcb4c360d2550a031a5378df03 (patch)
treed22c567906393c503244f1d43caa4d9c500528fe /libavutil/tx_priv.h
parent9ddaf0c9f06fab9194161425a32615c4cfc2ec20 (diff)
downloadffmpeg-8e94b7cff03539bcb4c360d2550a031a5378df03.tar.gz
lavu/tx: invert permutation lookups
out[lut[i]] = in[i] lookups were 4.04 times(!) slower than out[i] = in[lut[i]] lookups for an out-of-place FFT of length 4096. The permutes remain unchanged for anything but out-of-place monolithic FFT, as those benefit quite a lot from the current order (it means there's only 1 lookup necessary to add to an offset, rather than a full gather). The code was based around non-power-of-two FFTs, so this wasn't benchmarked early on.
Diffstat (limited to 'libavutil/tx_priv.h')
-rw-r--r--libavutil/tx_priv.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavutil/tx_priv.h b/libavutil/tx_priv.h
index e9fba02a35..e2f4314a4f 100644
--- a/libavutil/tx_priv.h
+++ b/libavutil/tx_priv.h
@@ -123,7 +123,7 @@ struct AVTXContext {
/* Shared functions */
int ff_tx_type_is_mdct(enum AVTXType type);
int ff_tx_gen_compound_mapping(AVTXContext *s);
-int ff_tx_gen_ptwo_revtab(AVTXContext *s);
+int ff_tx_gen_ptwo_revtab(AVTXContext *s, int invert_lookup);
int ff_tx_gen_ptwo_inplace_revtab_idx(AVTXContext *s);
/* Also used by SIMD init */