[FFmpeg-devel] [PATCHv2] avcodec/aac_tablegen: get rid of hardcoded tables entirely
gajjanag at mit.edu
Sat Nov 28 13:50:23 CET 2015
On Sat, Nov 28, 2015 at 3:38 AM, Rostislav Pehlivanov
<atomnuker at gmail.com> wrote:
> On Fri, 2015-11-27 at 19:35 -0500, Ganesh Ajjanagadde wrote:
>> @@ -40,6 +39,57 @@
>> * Tables in this file are shared by the AAC decoders and encoder
>> +#define POW_SF2_ZERO 200 ///< ff_aac_pow2sf_tab index
>> corresponding to pow(2, 0);
> Move POW_SF2_ZERO to aac.h, which is already included by aactab.h and
> by everything else which uses it, so it'll be fine. Just put it like
>> 152 #define SCALE_DIFF_ZERO 60 //....
>> 153 +
>> 154 + #define POW_SF2_ZERO 200 //....
>> 156 #define NOISE_PRE 256 //....
>> +extern float ff_aac_pow2sf_tab;
>> +extern float ff_aac_pow34sf_tab;
>> +static av_cold inline void ff_aac_tableinit(void)
> The av_cold attribute seems pointless here. Since the function is
> inlined and always executed on the already av_cold decoder and encoder
> table init functions there shouldn't be a branch making it pointless.
Personally, I don't want this inlined, but could not do so in a way
that keeps the compiler and linker happy after some attempts (see the
caveat I posted). I want to try this again, unless you know what to do
> Other than those 2 remarks, looks good to me.
> ffmpeg-devel mailing list
> ffmpeg-devel at ffmpeg.org
More information about the ffmpeg-devel