[Bug tree-optimization/43012] New: wrong code for -floop-strip-mine in 453.povray
janis at gcc dot gnu dot org
gcc-bugzilla@gcc.gnu.org
Tue Feb 9 21:27:00 GMT 2010
SPEC CPU2006 test 453.povray is miscompiled by GCC mainline on powerpc64-linux
for "-O2 -floop-strip-line" with either -m32 or -m64. Here's the function that
is miscompiled; I'll attach a complete executable testcase:
----------------------------------------------------
void
pre_init_tokenizer ()
{
int i;
for (i = 0; i < LAST_TOKEN; i++)
{
Table[i] = i;
if (i < FLOAT_FUNCT_TOKEN)
Table[i] = FLOAT_FUNCT_TOKEN;
else
{
if (i < VECTOR_FUNCT_TOKEN)
Table[i] = VECTOR_FUNCT_TOKEN;
else
{
if (i < COLOUR_KEY_TOKEN)
Table[i] = COLOUR_KEY_TOKEN;
}
}
}
}
----------------------------------------------------
Array elements 51-63 and 89-101 are not assigned values when the code is
compiled with "-O2 -floop-strip-mine".
The testcase (and 453.povray) work with GCC 4.4.2 with those options, so this
is a regression in GCC 4.5. The failure starts with this patch:
http://gcc.gnu.org/viewcvs?view=rev&rev=154637
r154637 | spop | 2009-11-25 05:30:35 +0000 (Wed, 25 Nov 2009)
--
Summary: wrong code for -floop-strip-mine in 453.povray
Product: gcc
Version: 4.5.0
Status: UNCONFIRMED
Keywords: wrong-code
Severity: normal
Priority: P3
Component: tree-optimization
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: janis at gcc dot gnu dot org
GCC target triplet: powerpc64-linux
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43012
More information about the Gcc-bugs
mailing list