This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug rtl-optimization/17428] [4.0 Regression] internal compiler error: in spill_failure, at reload1.c:1880
- From: "reichelt at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 28 Oct 2004 09:28:44 -0000
- Subject: [Bug rtl-optimization/17428] [4.0 Regression] internal compiler error: in spill_failure, at reload1.c:1880
- References: <20040912034129.17428.opticcow@linux-militia.net>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From reichelt at gcc dot gnu dot org 2004-10-28 09:28 -------
Because of the patch http://gcc.gnu.org/ml/gcc-cvs/2004-10/msg01513.html
that adds "-funroll-loops" to "-fprofile-generate" the testcase from
comment #4 has to be compiled with
"-msse -O2 -fspeculative-prefetching -fprofile-generate -fno-unroll-loops"
to still trigger the bug. Alternatively one can increase the number of
iterations of the loop from 2 to 20.
The bug finally disappeared with Zdenek's patch
http://gcc.gnu.org/ml/gcc-cvs/2004-10/msg01561.html
which seems to address Andrew's suggestion from comment #5.
Zdenek, is this a real fix or is this just papering over the problem?
I.e. is your patch from comment #9 still needed or not?
Alas, the original testcase still segfaults with mainline. Here's a testcase:
==============================================================
int foo(int, int) __attribute__((pure));
void bar()
{
int i;
if (foo(0,0))
for (i = 0; i < 2; i++)
;
}
==============================================================
Compile with "-O -march=pentium4 -fprofile-generate -fspeculative-prefetching
-funroll-loops"
to trigger the bug.
Phils's regression tester about this bug:
: Search converges between 2004-10-01-014001-trunk (#570) and
2004-10-01-161002-trunk (#571).
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17428