[FFmpeg-devel] [RFC] current compilation status when no optimizations enabled

Baptiste Coudurier baptiste.coudurier
Sat Jun 21 07:37:08 CEST 2008


Hi guys

While I was compiling ffmpeg with --enable-debug, I noticed the option did
not have much effect on CFLAGS.

I edited config.mak and removed "-fomit-frame-pointer -O3", and added
"-ggdb3"

gcc (Debian 4.3.1-2) 4.3.1
Copyright (C) 2008 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

model name      : Intel(R) Core(TM)2 Duo CPU     T7250  @ 2.00GHz

Report of compilation:

gcc -DHAVE_AV_CONFIG_H -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_ISOC9X_SOURCE -I.
-I"/home/bcouduri/src/ffmpeg/svn2" -pthread -ggdb3 -Wdeclaration-after-statement -Wall -Wno-switch
-Wdisabled-optimization -Wpointer-arith -Wredundant-decls -Wno-pointer-sign -Wcast-qual
-Wwrite-strings -Wtype-limits -fno-math-errno -fno-signed-zeros       -c -o
libavcodec/i386/dsputil_mmx.o libavcodec/i386/dsputil_mmx.c
cc1: warning: -funit-at-a-time is required for inlining of functions that are only called once
In file included from libavcodec/i386/dsputil_mmx.c:31:
libavcodec/i386/mmx.h:24:2: warning: #warning Everything in this header is deprecated, use plain
asm()! New code using this header will be rejected.
libavcodec/i386/dsputil_mmx.c: In function 'transpose4x4':
libavcodec/i386/dsputil_mmx.c:617: error: can't find a register in class 'GENERAL_REGS' while
reloading 'asm'
libavcodec/i386/dsputil_mmx.c:617: error: 'asm' operand has impossible constraints
make: *** [libavcodec/i386/dsputil_mmx.o] Error 1

Compilation pass adding -O1

gcc -DHAVE_AV_CONFIG_H -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_ISOC9X_SOURCE -I.
-I"/home/bcouduri/src/ffmpeg/svn2" -pthread -ggdb3 -Wdeclaration-after-statement -Wall -Wno-switch
-Wdisabled-optimization -Wpointer-arith -Wredundant-decls -Wno-pointer-sign -Wcast-qual
-Wwrite-strings -Wtype-limits -fno-math-errno -fno-signed-zeros       -c -o libavcodec/h264.o
libavcodec/h264.c
cc1: warning: -funit-at-a-time is required for inlining of functions that are only called once
In file included from libavcodec/h264.h:32,
                 from libavcodec/h264.c:31:
libavcodec/cabac.h: In function 'get_cabac_noinline':
libavcodec/cabac.h:529: error: can't find a register in class 'GENERAL_REGS' while reloading 'asm'
libavcodec/cabac.h:529: error: 'asm' operand has impossible constraints
In file included from libavcodec/h264.c:8106:
libavcodec/svq3.c: In function 'svq3_decode_slice_header':
libavcodec/svq3.c:707: warning: cast discards qualifiers from pointer target type
make: *** [libavcodec/h264.o] Error 1

Compilation pass adding -fomit-frame-pointer (no -On needed)

gcc -DHAVE_AV_CONFIG_H -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_ISOC9X_SOURCE -I.
-I"/home/bcouduri/src/ffmpeg/svn2" -pthread -ggdb3 -Wdeclaration-after-statement -Wall -Wno-switch
-Wdisabled-optimization -Wpointer-arith -Wredundant-decls -Wno-pointer-sign -Wcast-qual
-Wwrite-strings -Wtype-limits -fno-math-errno -fno-signed-zeros       -c -o libavcodec/h264_parser.o
libavcodec/h264_parser.c
cc1: warning: -funit-at-a-time is required for inlining of functions that are only called once
In file included from libavcodec/h264.h:32,
                 from libavcodec/h264_parser.h:31,
                 from libavcodec/h264_parser.c:29:
libavcodec/cabac.h: In function 'get_cabac_noinline':
libavcodec/cabac.h:529: error: can't find a register in class 'GENERAL_REGS' while reloading 'asm'
libavcodec/cabac.h:529: error: 'asm' operand has impossible constraints
make: *** [libavcodec/h264_parser.o] Error 1

First this is weird, same error from cabac.h but from another file ?
Double inclusion problem ?

Compilation pass adding -O1

gcc -DHAVE_AV_CONFIG_H -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_ISOC9X_SOURCE -I.
-I"/home/bcouduri/src/ffmpeg/svn2" -pthread -ggdb3 -Wdeclaration-after-statement -Wall -Wno-switch
-Wdisabled-optimization -Wpointer-arith -Wredundant-decls -Wno-pointer-sign -Wcast-qual
-Wwrite-strings -Wtype-limits -fno-math-errno -fno-signed-zeros       -c -o libavcodec/cabac.o
libavcodec/cabac.c
cc1: warning: -funit-at-a-time is required for inlining of functions that are only called once
In file included from libavcodec/cabac.c:31:
libavcodec/cabac.h: In function 'get_cabac_noinline':
libavcodec/cabac.h:529: error: can't find a register in class 'GENERAL_REGS' while reloading 'asm'
libavcodec/cabac.h:529: error: 'asm' operand has impossible constraints
make: *** [libavcodec/cabac.o] Error 1

Same error

Compilation pass adding -O1

gcc -DHAVE_AV_CONFIG_H -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_ISOC9X_SOURCE -I.
-I"/home/bcouduri/src/ffmpeg/svn2" -pthread -ggdb3 -Wdeclaration-after-statement -Wall -Wno-switch
-Wdisabled-optimization -Wpointer-arith -Wredundant-decls -Wno-pointer-sign -Wcast-qual
-Wwrite-strings -Wtype-limits -fno-math-errno -fno-signed-zeros       -c -o
libavcodec/i386/snowdsp_mmx.o libavcodec/i386/snowdsp_mmx.c
cc1: warning: -funit-at-a-time is required for inlining of functions that are only called once
libavcodec/i386/snowdsp_mmx.c: In function 'ff_snow_vertical_compose97i_sse2':
libavcodec/i386/snowdsp_mmx.c:451: error: can't find a register in class 'GENERAL_REGS' while
reloading 'asm'
libavcodec/i386/snowdsp_mmx.c:451: error: 'asm' operand has impossible constraints
make: *** [libavcodec/i386/snowdsp_mmx.o] Error 1

Compilation pass adding -fomit-frame-pointer

Is the 7REGS define broken or am I crazy ?

-- 
Baptiste COUDURIER                              GnuPG Key Id: 0x5C1ABAAA
Smartjog USA Inc.                                http://www.smartjog.com
Key fingerprint                 8D77134D20CC9220201FC5DB0AC9325C5C1ABAAA





More information about the ffmpeg-devel mailing list