Hi Arcady. Sorry if I assigned the bug wrongly, but you seem to be the most prominent on the xine-lib bugs. Oh, and I did not find this reported either, although there are bunch of xine-lib related bugs. I hope I did not overlook something.. Apparently xine-lib (-1_rc1) does not like -fpmath=sse in CFLAGs, at least on pentium3. Build with -fpmath flag omitted proceeds fine. George Portage 2.0.49-r13 (default-x86-1.4, gcc-3.2.3, glibc-2.3.2-r1, 2.4.20-ck6) System uname: 2.4.20-ck6 i686 Pentium III (Coppermine) CFLAGS="-march=pentium3 -O2 -pipe -fforce-addr -fomit-frame-pointer -falign-functions=4 -mfpmath=sse" gcc -DHAVE_CONFIG_H -I. -I. -I../.. -I../.. -I../../include -I../../include -I../../src -I../../src/xine-engine -I../../src/xine-engine -I../../src/xine-utils -Wall -D_REENTRANT -D_FILE_OFFSET_BITS=64 -DXINE_COMPILE -Wpointer-arith -Wnested-externs -Wcast-align -Wchar-subscripts -Wmissing-declarations -Wmissing-prototypes -march=pentium3 -O2 -pipe -fforce-addr -fomit-frame-pointer -falign-functions=4 -mfpmath=sse -I/usr/kde/3.1/include/artsc -c cfft.c -MT cfft.lo -MD -MP -MF .deps/cfft.TPlo -o .libs/cfft.o cfft.c: In function `passf2': cfft.c:99: unable to find a register to spill in class `SSE_REGS' cfft.c:99: this is the insn: (insn 337 335 358 (set (subreg:SF (reg/v:DI 29 rmm0 [138]) 0) (minus:SF (reg:SF 21 exmm0 [175]) (mem:SF (reg/f:SI 0 eax [148]) [4 S4 A32]))) 547 {*fop_sf_1_sse} (insn_list 332 (nil)) (expr_list:REG_DEAD (reg:SF 21 exmm0 [175]) (nil))) cfft.c:99: confused by earlier errors, bailing out make[4]: *** [cfft.lo] Ошибка 1
I can verify the same thing happens with my p3. Removing -mfpmath=sse allows it to compile.
I can confirm it on a P4 2Ghz. Remove -fpmath=sse in CFLAGS works great. I remove the -msse2 flasg too for sure...
You should use "-mfpmath=sse,387" instead. This solves stability issues and compilation errors on a lot of things. No problems compiling xine-lib with that flag. You will also have to filter -fforce-addr.
*** Bug 45419 has been marked as a duplicate of this bug. ***
*** Bug 45877 has been marked as a duplicate of this bug. ***
*** Bug 45371 has been marked as a duplicate of this bug. ***
*** Bug 46095 has been marked as a duplicate of this bug. ***
*** Bug 35719 has been marked as a duplicate of this bug. ***
This isn't working for me. I tried setting CFLAGS to various things, including "" and "-mfpmath=sse,387", and I keep getting the same result: gcc -DHAVE_CONFIG_H -I. -I. -I../../../.. -I../../../.. -I../../../../include -I../../../../include -I../../../../src -I../../../../src/xine-engine -I../../../../src/xine-engine -I../../../../src/xine-utils -I../../../../src/input -I../../../../src/input -DSIMPLE_IDCT -DHAVE_AV_CONFIG_H -DRUNTIME_CPUDETECT -DUSE_FASTMEMCPY -DCONFIG_RISKY -DCONFIG_DECODERS -DXINE_MPEG_ENCODER -DCONFIG_ZLIB -Wall -DNDEBUG -D_REENTRANT -D_FILE_OFFSET_BITS=64 -DXINE_COMPILE -Wnested-externs -Wcast-align -Wchar-subscripts -Wmissing-declarations -Wmissing-prototypes -mfpmath=sse,387 -mno-sse2 -c dsputil_mmx.c -MT dsputil_mmx.lo -MD -MP -MF .deps/dsputil_mmx.TPlo cc1: warning: SSE instruction set disabled, using 387 arithmetics dsputil_mmx.c: In function `h263_h_loop_filter_mmx': dsputil_mmx.c:614: error: can't find a register in class `GENERAL_REGS' while reloading `asm' dsputil_mmx.c: In function `dsputil_init_mmx': dsputil_mmx.c:2116: warning: unused variable `dct_algo' dsputil_mmx.c: At top level: dsputil_mmx_rnd.h:363: warning: `avg_no_rnd_pixels8_l2_mmx' defined but not used dsputil_mmx_rnd.h:410: warning: `avg_no_rnd_pixels16_l2_mmx' defined but not used dsputil_mmx_avg.h:57: warning: `put_pixels8_l2_3dnow' defined but not used dsputil_mmx_avg.h:129: warning: `put_pixels16_l2_3dnow' defined but not used dsputil_mmx_avg.h:57: warning: `put_pixels8_l2_mmx2' defined but not used dsputil_mmx_avg.h:129: warning: `put_pixels16_l2_mmx2' defined but not used dsputil_mmx.c:1976: warning: `try_8x8basis_mmx' defined but not used dsputil_mmx.c:2024: warning: `add_8x8basis_mmx' defined but not used make[5]: *** [dsputil_mmx.lo] Error 1 make[5]: Leaving directory `/space/var/tmp/portage/xine-lib-1_rc3-r2/work/xine-lib-1-rc3b/src/libffmpeg/libavcodec/i386' make[4]: *** [all-recursive] Error 1 make[4]: Leaving directory `/space/var/tmp/portage/xine-lib-1_rc3-r2/work/xine-lib-1-rc3b/src/libffmpeg/libavcodec' make[3]: *** [all-recursive] Error 1 make[3]: Leaving directory `/space/var/tmp/portage/xine-lib-1_rc3-r2/work/xine-lib-1-rc3b/src/libffmpeg' make[2]: *** [all-recursive] Error 1 make[2]: Leaving directory `/space/var/tmp/portage/xine-lib-1_rc3-r2/work/xine-lib-1-rc3b/src' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/space/var/tmp/portage/xine-lib-1_rc3-r2/work/xine-lib-1-rc3b' make: *** [all] Error 2 !!! ERROR: media-libs/xine-lib-1_rc3-r2 failed. !!! Function src_compile, Line 108, Exitcode 2 !!! Parallel make failed
Heh, looks like this is a bug in gcc: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13850 fixed by using CFLAGS="-O" of all things.
*** Bug 47796 has been marked as a duplicate of this bug. ***
*** Bug 47871 has been marked as a duplicate of this bug. ***
Created attachment 29404 [details, diff] xine-lib.diff This patch allows the ebuildto filter -fforce-addr which make xine-lib not compilable. It owrks well using this.
*** Bug 49071 has been marked as a duplicate of this bug. ***
*** Bug 49508 has been marked as a duplicate of this bug. ***
Doesn't even work with CFLAGS="-O2" for me. USE="3dnow X aalib acpi alsa avi berkdb bonobo cdr crypt cups dvd encode fbcon flac flash foomaticdb gb gd gdbm gif gnome gphoto2 gpm gtk gtk2 guile imlib java jpeg ldap libg++ libwww mad matroska mbox mikmod mmx motif mozilla mpeg ncurses nls oggvorbis opengl oss pam pdflib perl png python quicktime readline samba sdl slang spell sse ssl svga tcltk tcpd theora tiff truetype usb v4l v4l2 x86 xml xml2 xmms xv zlib" CHOST="i686-pc-linux-gnu" COMPILER="gcc3" last words are: dsputil_mmx.lo -MD -MP -MF .deps/dsputil_mmx.TPlo -o .libs/dsputil_mmx.o dsputil_mmx.c: In function `h263_h_loop_filter_mmx': dsputil_mmx.c:614: error: can't find a register in class `GENERAL_REGS' while reloading `asm' dsputil_mmx.c: In function `dsputil_init_mmx': dsputil_mmx.c:2116: warning: unused variable `dct_algo' dsputil_mmx.c: At top level: dsputil_mmx_rnd.h:363: warning: `avg_no_rnd_pixels8_l2_mmx' defined but not useddsputil_mmx_rnd.h:410: warning: `avg_no_rnd_pixels16_l2_mmx' defined but not used dsputil_mmx_avg.h:57: warning: `put_pixels8_l2_3dnow' defined but not used dsputil_mmx_avg.h:129: warning: `put_pixels16_l2_3dnow' defined but not used dsputil_mmx_avg.h:57: warning: `put_pixels8_l2_mmx2' defined but not used dsputil_mmx_avg.h:129: warning: `put_pixels16_l2_mmx2' defined but not used dsputil_mmx.c:1976: warning: `try_8x8basis_mmx' defined but not used dsputil_mmx.c:2024: warning: `add_8x8basis_mmx' defined but not used make[5]: *** [dsputil_mmx.lo] Error 1 make[5]: Leaving directory `/var/tmp/portage/xine-lib-1_rc4/work/xine-lib-1-rc4/src/libffmpeg/libavcodec/i386' make[4]: *** [all-recursive] Error 1 make[4]: Leaving directory `/var/tmp/portage/xine-lib-1_rc4/work/xine-lib-1-rc4/src/libffmpeg/libavcodec' make[3]: *** [all-recursive] Error 1 make[3]: Leaving directory `/var/tmp/portage/xine-lib-1_rc4/work/xine-lib-1-rc4/src/libffmpeg' make[2]: *** [all-recursive] Error 1 make[2]: Leaving directory `/var/tmp/portage/xine-lib-1_rc4/work/xine-lib-1-rc4/src' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/var/tmp/portage/xine-lib-1_rc4/work/xine-lib-1-rc4'make: *** [all] Error 2 !!! ERROR: media-libs/xine-lib-1_rc4 failed. !!! Function src_compile, Line 112, Exitcode 2 !!! Parallel make failed I also tried with -j1 because of the "Parallel make" thing. Still no luck.
Julian, which gcc version?
*** Bug 51122 has been marked as a duplicate of this bug. ***
-fpmath=sse is filtered now
I have successfully built xine-lib with these CFLAGS: CFLAGS="-march=athlon-xp -O3 -mfpmath=sse -fforce-addr -fomit-frame-pointer -funroll-loops -pipe" But it always fails with these CFLAGS: CFLAGS="-march=athlon-xp -O3 -mfpmath=sse -fforce-addr -fomit-frame-pointer -funroll-loops -funroll-all-loops -fprefetch-loop-arrays -maccumulate-outgoing-args -pipe" i.e. xine-lib successfully builds, when I remove "-funroll-all-loops -fprefetch-loop-arrays -maccumulate-outgoing-args" from my CFLAGS. Hope it helps! :)