GCC ICE: internal compiler error: in push_minipool_fix

Bug #788841 reported by Khem Raj
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Linaro GCC
Won't Fix
Medium
Michael Collison
4.6
Triaged
Medium
Unassigned

Bug Description

GCC 4.6 is ICEing with the attached testcase. And this is not related to https://bugs.launchpad.net/gcc-linaro/+bug/711819
as the ICE happens after those patches applied.

The options needed are

-march=armv7-a -mfloat-abi=softfp -O2

my gcc is configures as below

./work/angstrom/build/tmp-angstrom_2010_x-eglibc/sysroots/x86_64-linux/usr/bin/armv7a-angstrom-linux-gnueabi/arm-angstrom-linux-gnueabi-gcc -v
Using built-in specs.
COLLECT_GCC=./work/angstrom/build/tmp-angstrom_2010_x-eglibc/sysroots/x86_64-linux/usr/bin/armv7a-angstrom-linux-gnueabi/arm-angstrom-linux-gnueabi-gcc
COLLECT_LTO_WRAPPER=/home/kraj/work/angstrom/build/tmp-angstrom_2010_x-eglibc/sysroots/x86_64-linux/usr/libexec/armv7a-angstrom-linux-gnueabi/gcc/arm-angstrom-linux-gnueabi/4.6.0/lto-wrapper
Target: arm-angstrom-linux-gnueabi
Configured with: /home/kraj/work/angstrom/build/tmp-angstrom_2010_x-eglibc/work/armv7a-angstrom-linux-gnueabi/gcc-cross-4.6-r0/gcc-4.6.0/configure --build=x86_64-linux --host=x86_64-linux --target=arm-angstrom-linux-gnueabi --prefix=/home/kraj/work/angstrom/build/tmp-angstrom_2010_x-eglibc/sysroots/x86_64-linux/usr --exec_prefix=/home/kraj/work/angstrom/build/tmp-angstrom_2010_x-eglibc/sysroots/x86_64-linux/usr --bindir=/home/kraj/work/angstrom/build/tmp-angstrom_2010_x-eglibc/sysroots/x86_64-linux/usr/bin/armv7a-angstrom-linux-gnueabi --sbindir=/home/kraj/work/angstrom/build/tmp-angstrom_2010_x-eglibc/sysroots/x86_64-linux/usr/bin/armv7a-angstrom-linux-gnueabi --libexecdir=/home/kraj/work/angstrom/build/tmp-angstrom_2010_x-eglibc/sysroots/x86_64-linux/usr/libexec/armv7a-angstrom-linux-gnueabi --datadir=/home/kraj/work/angstrom/build/tmp-angstrom_2010_x-eglibc/sysroots/x86_64-linux/usr/share --sysconfdir=/home/kraj/work/angstrom/build/tmp-angstrom_2010_x-eglibc/sysroots/x86_64-linux/etc --sharedstatedir=/home/kraj/work/angstrom/build/tmp-angstrom_2010_x-eglibc/sysroots/x86_64-linux/com --localstatedir=/home/kraj/work/angstrom/build/tmp-angstrom_2010_x-eglibc/sysroots/x86_64-linux/var --libdir=/home/kraj/work/angstrom/build/tmp-angstrom_2010_x-eglibc/sysroots/x86_64-linux/usr/lib/armv7a-angstrom-linux-gnueabi --includedir=/home/kraj/work/angstrom/build/tmp-angstrom_2010_x-eglibc/sysroots/x86_64-linux/usr/include --oldincludedir=/home/kraj/work/angstrom/build/tmp-angstrom_2010_x-eglibc/sysroots/x86_64-linux/usr/include --infodir=/home/kraj/work/angstrom/build/tmp-angstrom_2010_x-eglibc/sysroots/x86_64-linux/usr/share/info --mandir=/home/kraj/work/angstrom/build/tmp-angstrom_2010_x-eglibc/sysroots/x86_64-linux/usr/share/man --disable-silent-rules --with-libtool-sysroot=/home/kraj/work/angstrom/build/tmp-angstrom_2010_x-eglibc/sysroots/x86_64-linux --with-gnu-ld --enable-shared --enable-languages=c,c++ --enable-threads=posix --disable-multilib --enable-c99 --enable-long-long --enable-symvers=gnu --enable-libstdcxx-pch --program-prefix=arm-angstrom-linux-gnueabi- --enable-target-optspace --enable-lto --enable-libssp --disable-bootstrap --disable-libgomp --disable-libmudflap --enable-cheaders=c_global --with-float=soft --with-local-prefix=/home/kraj/work/angstrom/build/tmp-angstrom_2010_x-eglibc/sysroots/beagleboard/usr --with-gxx-include-dir=/usr/include/c++ --with-sysroot=/home/kraj/work/angstrom/build/tmp-angstrom_2010_x-eglibc/sysroots/beagleboard --with-build-sysroot=/home/kraj/work/angstrom/build/tmp-angstrom_2010_x-eglibc/sysroots/beagleboard --enable-poison-system-directories --disable-libunwind-exceptions --with-mpfr=/home/kraj/work/angstrom/build/tmp-angstrom_2010_x-eglibc/sysroots/x86_64-linux/usr --with-system-zlib --enable-nls --enable-__cxa_atexit --enable-__cxa_atexit
Thread model: posix
gcc version 4.6.0 (GCC)

Revision history for this message
Khem Raj (khem-raj) wrote :
Revision history for this message
Michael Hope (michaelh1) wrote :

Thank you for the bug report. I've confirmed this with gcc-linaro-4.6-2011.05-0 on ARM:

michaelh@ursa1:~/linaro/bugs$ /tools/toolchains/arch/armv7l/gcc-linaro-4.6-2011.05-0-armv7l-maverick-cbuild114-ursa3-cortexa9r1/bin/gcc -c -O2 -marm lp788841.i
svga_tgsi_insn.c: In function 'svga_shader_emit_instructions':
svga_tgsi_insn.c:2889:1: internal compiler error: in push_minipool_fix, at config/arm/arm.c:12138
...

michaelh@ursa1:~/linaro/bugs$ /tools/toolchains/gcc-4.6.0-armv7l-maverick-cbuild93-ursa1-cortexa8r1/bin/gcc -c -O2 -marm lp788841.i
svga_tgsi_insn.c: In function 'svga_shader_emit_instructions':
svga_tgsi_insn.c:2889:1: internal compiler error: in push_minipool_fix, at config/arm/arm.c:12084
...

The work-around is to compile at -O1. The fault also exists in gcc-4.6.0. It does not exist in linaro-gcc-4.5-2011.05, gcc-4.5.2, or gcc-trunk r174044. As this is a regression in 4.6 compared to 4.5, Could you please also report this in GCC bugzilla and attach it to this ticket?

I've set it to medium as it is a ftbfs, the fault exists upstream, and there is a work-around.

Changed in gcc-linaro:
importance: Undecided → Medium
status: New → Triaged
Revision history for this message
Michael Hope (michaelh1) wrote :

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49135 may be related as it's on the same line, but note that the bug is against 4.7 not 4.6.

Revision history for this message
Khem Raj (khem-raj) wrote :

gcc.c-torture/execute/920302-1.c compiles fine with 4.6 and with the above option set.

Revision history for this message
Michael Hope (michaelh1) wrote :

(notes for michaelh) trunk r172224 and later don't show this problem where 4.6.0 does. 4.6 was branched at 170935.

...which is git range b4344328e74ba5bd83660a59a509b7a9aac0b7f6 to 9a4818f1445b5efcd959580be695bbbbdedeca03.

Revision history for this message
Michael Hope (michaelh1) wrote :

I did some bisecting and this problem is cleared by trunk r170984:

Author: rguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>
Date: Tue Mar 15 11:09:09 2011 +0000

    2011-03-15 Richard Guenther <email address hidden>
        PR tree-optimization/41490

Revision history for this message
Michael Collison (michael-collison) wrote :

Will not fix for older releases. Issue fixed and does not impact linaro 4.8 or 4.9.

Changed in gcc-linaro:
assignee: nobody → Michael Collison (michael-collison)
status: Triaged → Won't Fix
Revision history for this message
Christophe Lyon (christophe-lyon) wrote :

See bug #1296601 (duplicate of this one), in fact the problem is still present in 4.8/4.9 but difficult to reproduce.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Bug attachments

Remote bug watches

Bug watches keep track of this bug in other bug trackers.