On 4 January 2017 at 14:14, Peter Barfuss <bofh....@gmail.com> wrote:
> First off, many thanks. > > > + const int inv_1 = l_ptwo << ((4 - b_ptwo) & 3); > > + const int inv_2 = 0xeeeeeeef & ((1U << b_ptwo) - 1); > > It would be nice to add a comment here that the expression for inv_1 > is (2^b_ptwo)^-1 mod 15 and inv_2 is 15^-1 mod 2^b_ptwo. (A general > PFA FFT would need to use extended Euclidean algorithm here, but > because both cases are fixed, it simplifies to these expressions. I > have a sketch of a proof (basically solving the relevant diophantine > equation you get) in case anyone is nervous, though it's easy to > verify by hand for 1 < b_ptwo < 18, which are all the cases that > ffmpeg's power-of-two FFT currently supports). > > Rest of patch seems good. > > -Peter > _______________________________________________ > ffmpeg-devel mailing list > ffmpeg-devel@ffmpeg.org > http://ffmpeg.org/mailman/listinfo/ffmpeg-devel > Done Also I didn't like how s->exptab[20].re needed a negative sign so I removed it and moved the subtraction to the 5-point FFT, just so you know. I'll push both patches tomorrow evening if no one else has anything to say. _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel