[FFmpeg-devel] Disable inlining when using --disable-optimizations

Jeff Downs heydowns
Thu Jul 30 21:28:58 CEST 2009


When debugging issues and crashes in ffmpeg recently, I found it helpful 
to have a way to disable inlining so you can get real stack frames for 
each function. --disable-optimizations gets you most of the way there, but 
functions marked av_always_inline will still get inlined.

Turns out there is already a case for disabling av_always_inline 
(--enable-small); I extended the conditions for that to include 
disabled optimizations.

I've been using this for several weeks here and found it useful, so I 
figured I'd post it.
When using this I noticed that the existing way of turning off 
av_always_inline causes warnings of redefinition; patch 
silences the warnings, too.

	-Jeff
-------------- next part --------------
Index: configure
===================================================================
--- configure	(revision 19505)
+++ configure	(working copy)
@@ -2655,7 +2655,8 @@
 
 echo "#define restrict $_restrict" >> $TMPH
 
-if enabled small; then
+if enabled small || disabled optimizations; then
+    echo "#undef av_always_inline"  >> $TMPH
     echo "#define av_always_inline"  >> $TMPH
 fi
 



More information about the ffmpeg-devel mailing list