[Ffmpeg-devel] Re: [RFC] mpeg2 422 encoding.
Thu Apr 13 14:56:38 CEST 2006
Michael Niedermayer wrote:
> you did, but gcc doesnt like your code, the mpeg4 mb encode code is 7%
> slower now (meassured with START/STOP_TIMER)
> the problem with gcc likely is that there are various limits on inlining
> and gcc includes the manual inlining from always_inline so that
> forcing a function to be inlined will cause another function to no longer
> be inlined
> A. add always_inline everywhere (not realistic)
> B. change the limits via command line paramaters to gcc
> C. inline fewer functions
> D. reduce the size of the inlined stuff
> E. use the preprocessor to do the inlineing so that gcc doesnt know (ugly)
> F. combination of the above
> note, "nm mpegvideo.o" shows which functions are in there (the missing ones
> where inlined everywhere), and IIRC there is a option for gcc too which
> prints warnings if something wasnt inlined which had a inline keyword ...
All right. I added -Winline to gcc parameters and indeed, even atm some
functions are not inlined. Basically add_dct, put_dct.
Im not feeling really confortable in code optimization. I miss the basics.
I'll only check for 420 in the code for now. May I ask what is the exact
performance test you are using ? START/STOP_TIMER around encode_mb ?
What is a "significant" number of runs ?
Btw, I still have a bug with -mbd bits, and it's a bit annoying (green
bottom chroma macroblock in P frames, if using -bf > 8 the bug vanish).
Since you best know mpegvideo.c, do you see where it could be located ?
I fixed INTERLACED_DCT for 422, wrap_c need to be /2 as wrap_y.
Thanks a lot,
Baptiste COUDURIER GnuPG Key Id: 0x5C1ABAAA
SMARTJOG S.A. http://www.smartjog.com
Key fingerprint 8D77134D20CC9220201FC5DB0AC9325C5C1ABAAA
Phone: +33 1 49966312
More information about the ffmpeg-devel