[FFmpeg-devel] manually hacked configure options increase h264 decoding speed significantly

Reimar Döffinger Reimar.Doeffinger at gmx.de
Thu Oct 20 15:22:32 CEST 2011


On Thu, Oct 20, 2011 at 02:31:19PM +0200, madshi wrote:
> 2011/10/20 Reimar Döffinger <Reimar.Doeffinger at gmx.de>
> > It should also need -fomit-frame-pointer, and it makes more
> > sense to just look in config.log which options were used and
> > why it failed.
> 
> config.log says:
> 
> # ./configure --enable-shared --disable-static --enable-pthreads --arch=x86
> --cpu=i686 --extra-cflags='-march=i686 -mfpmath=sse -mmmx -msse
> -DPTW32_STATIC_LIB'
> 
> [...]
> 
> BEGIN /tmp/ffconf.FxAVoQLM.c
>     1    #include <signal.h>
>     2    static void sighandler(int sig){
>     3        raise(SIGTERM);
>     4    }
>     5    int main(void){
>     6        signal(SIGILL, sighandler);
>     7        signal(SIGFPE, sighandler);
>     8        signal(SIGSEGV, sighandler);
>     9    #ifdef SIGBUS
>    10        signal(SIGBUS, sighandler);
>    11    #endif
>    12        {     volatile int i=0;
>    13        __asm__ volatile (
>    14            "xorl %%ebp, %%ebp"
>    15        ::: "%ebp");
>    16        return i; }
>    17    }
> END /tmp/ffconf.FxAVoQLM.c
> gcc -D_ISOC99_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE
> -U__STRICT_ANSI__ -march=i686 -mfpmath=sse -mmmx -msse -DPTW32_STATIC_LIB
> -march=i686 -std=c99 -fno-common -fomit-frame-pointer -c -o
> /tmp/ffconf.mjvtCbzL.o /tmp/ffconf.FxAVoQLM.c
> C:/DOKUME~1/LOKALE~1/LOKALE~1/Temp/ffconf.FxAVoQLM.c: In function 'main':
> C:/DOKUME~1/LOKALE~1/LOKALE~1/Temp/ffconf.FxAVoQLM.c:17:1: error: bp cannot
> be used in asm here
> check_asm ebx_available ""::"b"(0)

Hm, with all those signal() calls in there main is no longer a leaf
function and thus -fomit-frame-pointer does not work I think.

> configure --enable-shared --disable-static --enable-pthreads --arch=x86
> --cpu=i686 --extra-cflags='-o3 -fomit-frame-pointer -march=i686 -mfpmath=sse
> -mmmx -msse -DPTW32_STATIC_LIB'

-O3, not -o3. But those flags are already set, but adding those signal()
calls seems to have broken the test.


More information about the ffmpeg-devel mailing list