From 16d4c28cbb9add358d4e6f30c412860638dc4f90 Mon Sep 17 00:00:00 2001 From: Ganesh Ajjanagadde Date: Wed, 25 Nov 2015 16:26:08 -0500 Subject: avcodec/mpegaudio_tablegen: speed up dynamic table creation This does some miscellaneous stuff mainly avoiding the usage of pow to achieve significant speedups. This is not speed critical, but is unnecessary latency and cycles wasted for a user. All tables tested and are identical to the old ones (bit-exact even in floating point case). Sample benchmark (x86-64, Haswell, GNU/Linux): old: 102329530 decicycles in mpegaudio_tableinit, 1 runs, 0 skips new: 34111900 decicycles in mpegaudio_tableinit, 1 runs, 0 skips Reviewed-by: Ronald S. Bultje Signed-off-by: Ganesh Ajjanagadde --- libavcodec/mpegaudio_tablegen.c | 1 + 1 file changed, 1 insertion(+) (limited to 'libavcodec/mpegaudio_tablegen.c') diff --git a/libavcodec/mpegaudio_tablegen.c b/libavcodec/mpegaudio_tablegen.c index 90c9de430a..9a9bb4d056 100644 --- a/libavcodec/mpegaudio_tablegen.c +++ b/libavcodec/mpegaudio_tablegen.c @@ -23,6 +23,7 @@ #include #define CONFIG_HARDCODED_TABLES 0 #include "mpegaudio_tablegen.h" +#include "libavutil/tablegen.h" #include "tableprint.h" int main(void) -- cgit v1.2.3