[forwarded from http://bugs.debian.org/202762] seen with 3.3 CVS 20030728, works with 3.2.3 and HEAD CVS 20030722. trying to compile kernel 2.4.22-pre8 on alpha: $ gcc -O2 -fno-strict-aliasing -fno-common -fomit-frame-pointer -pipe -mno-fp-regs -ffixed-8 -mcpu=ev56 -Wa,-mev6 -c fork.i fork.c: In function `dup_mmap': fork.c:144: error: unrecognizable insn: (insn 59 52 61 0 0x20000ce7760 (set (reg/f:DI 82) (symbol_ref:DI ("@Smmlist_nr"))) -1 (nil) (expr_list:REG_EQUAL (symbol_ref:DI ("@Smmlist_nr")) (nil))) fork.c:144: internal compiler error: in extract_insn, at recog.c:2175 Please submit a full bug report, with preprocessed source if appropriate. See <URL:http://gcc.gnu.org/bugs.html> for instructions. make[3]: *** [fork.o] Error 1
Created attachment 4511 [details] preprocessed source
With 3.3.1 (20030714), I do not get the ICE. I will try a newer version now.
With a cross compiler from powerpc-apple-darwin6.6 and gcc 3.3.1 (20030728), ./cc1 -O2 -fno-strict-aliasing -fno-common -fomit-frame-pointer -mno-fp-regs -ffixed-8 - mcpu=ev56 pr11717.i I do not get the ICE. Is this a modified compiler?
Never I figured out I needed -mexplicit-relocs since I had no as so configure did not pick it up by default.
I now found option which makes gcc ice, it also ICEs in 3.3.1 20030714.
*** Bug 11732 has been marked as a duplicate of this bug. ***
Created attachment 4594 [details] Smaller testcase (derived from different example) This one doesn't require any extra options: falk@juist:/tmp% gcc -v -c mpeg.i Reading specs from /usr/lib/gcc-lib/alpha-linux/3.3.1/specs Configured with: ../src/configure -v --enable-languages=c,c++,java,f77,pascal,objc,ada,treelang --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --with-gxx-include-dir=/usr/include/c++/3.3 --enable-shared --with-system-zlib --enable-nls --without-included-gettext --enable-__cxa_atexit --enable-clocale=gnu --enable-debug --enable-java-gc=boehm --enable-java-awt=xlib --enable-objc-gc alpha-linux Thread model: posix gcc version 3.3.1 (Debian) /usr/lib/gcc-lib/alpha-linux/3.3.1/cc1 -fpreprocessed mpeg.i -quiet -dumpbase mpeg.i -auxbase mpeg -version -o /tmp/ccrOtoGz.s GNU C version 3.3.1 (Debian) (alpha-linux) compiled by GNU C version 3.3.1 (Debian). GGC heuristics: --param ggc-min-expand=64 --param ggc-min-heapsize=64064 mpeg.i: In function `mpeg_mux_init': mpeg.i:23: error: unrecognizable insn: (insn 17 16 18 0 0x20000354688 (set (reg/f:DI 73) (symbol_ref:DI ("@Smpeg1vcd_mux"))) -1 (nil) (expr_list:REG_EQUAL (symbol_ref:DI ("@Smpeg1vcd_mux")) (nil))) mpeg.i:23: internal compiler error: in extract_insn, at recog.c:2175 Please submit a full bug report, with preprocessed source if appropriate. See <URL:http://gcc.gnu.org/bugs.html> for instructions. Changing most anything makes the ICE go away, for example removing the ; within {;}...
I also have this bug with 3.3.1 on alpha. With 3.3 it didn't occur.
I can't get mpeg.i to fail on gcc-3_3-branch for alpha-linux with any compile option I could come up with easily. With or without -mno-explicit-relocs as well. Can you still duplicate this with the branch?
I can reproduce this with alpha linux kernel 2.4.21 cross compiled under darwin using gcc 3.3.2- 200308. The cross compiler was built with Darwin's gcc 3.1, I haven't tried with Apple's recent 3.3 update. $ alpha-linux-gcc -D__KERNEL__ -I/Volumes/Linux/build/linux-2.4.21/include -Wall -Wstrict- prototypes -Wno-trigraphs -O2 -fno-strict-aliasing -fno-common -fomit-frame-pointer -pipe - mno-fp-regs -ffixed-8 -mcpu=ev4 -Wa,-mev6 -nostdinc -iwithprefix include - DKBUILD_BASENAME=fork -c -o fork.o fork.c fork.c: In function `dup_mmap': fork.c:144: error: unrecognizable insn: (insn 59 52 61 0 0xceaf80 (set (reg/f:DI 82) (symbol_ref:DI ("@Smmlist_nr"))) -1 (nil) (expr_list:REG_EQUAL (symbol_ref:DI ("@Smmlist_nr")) (nil))) fork.c:144: internal compiler error: in extract_insn, at recog.c:2175 Please submit a full bug report, with preprocessed source if appropriate. See <URL:http://gcc.gnu.org/bugs.html> for instructions. $ alpha-linux-gcc -v Reading specs from /Users/fthain/xcompiler/alpha-linux-local/lib/gcc-lib/alpha-linux/3.3.2/ specs Configured with: ../gcc-core-3.3-20030811/configure --prefix=/Users/fthain/xcompiler/alpha- linux-local --target=alpha-linux --enable-languages=c --with-headers=/Users/fthain/ xcompiler/alpha-linux-local/alpha-linux/include --with-sysroot=/Users/fthain/xcompiler/alpha- linux-local --disable-shared --enable-threads=single Thread model: single gcc version 3.3.2 20030811 (experimental)
I can still reproduce the ICE with 3.3.2 20030819 and both fork.i with the mentioned options and mpeg.i without any options. Did you build a native compiler? Maybe it doesn't occur with a cross compiler (although I couldn't think why). Note mpeg.i is invalid, it declares mpeg1vcd_mux first as extern and then as static. However, when removing the "static", it still ICEs.
Still a problem. Maybe you using an old binutils which does not have the support for -mexplicit-relocs so it does not dect it at configure time.
Still get the same failure with gcc 3.3.2-20030818. I built the cross compiler against glibc headers from the glibc CVS as at 20030811. I notice the original Debian bug report was using glibc 2.3.1-17, so I guess this may not be relevant. $ alpha-linux-ld -v GNU ld version 2.14.90.0.5 20030722 $ alpha-linux-gcc -v Reading specs from /Users/fthain/xcompiler/alpha-linux-local/lib/gcc-lib/alpha-linux/3.3.2/ specs Configured with: ../gcc-core-3.3-20030818/configure --prefix=/Users/fthain/xcompiler/alpha- linux-local --target=alpha-linux --enable-languages=c --with-headers=/Users/fthain/ xcompiler/alpha-linux-local/alpha-linux/include --with-sysroot=/Users/fthain/xcompiler/alpha- linux-local --disable-shared --enable-threads=single Thread model: single gcc version 3.3.2 20030818 (prerelease)
I'm afraid I still get exactly the same ICE with the current snapshot. $ alpha-linux-gcc -v Reading specs from /Users/fthain/xcompiler/alpha-linux-local/lib/gcc-lib/alpha-linux/3.3.2/ specs Configured with: ../gcc-core-3.3-20030825/configure --prefix=/Users/fthain/xcompiler/alpha- linux-local --target=alpha-linux --enable-languages=c --with-headers=/Users/fthain/ xcompiler/alpha-linux-local/alpha-linux/include --with-sysroot=/Users/fthain/xcompiler/alpha- linux-local --disable-shared --enable-threads=single Thread model: single gcc version 3.3.2 20030825 (prerelease)
2003-09-17 Richard Henderson <rth@redhat.com> * config/alpha/alpha.c (alpha_expand_mov): Do gen_movdi_er_maybe_g always during initial code generation. * config/alpha/alpha.md (movdi_er_maybe_g): Don't conditionalize on flag_inline_functions.
*** Bug 12488 has been marked as a duplicate of this bug. ***