[Bug optimization/15274] New: loop2 creates invalid rtl
amodra at bigpond dot net dot au
gcc-bugzilla@gcc.gnu.org
Tue May 4 03:36:00 GMT 2004
/* Taken from libf2c/libI77/util.c, the following ICEs on powerpc-linux
with -O1 -S.
"internal compiler error: in do_SUBST, at combine.c:440" */
void
g_char (char *a, unsigned long alen, char *b)
{
char *x = a + alen, *y = b + alen;
for (;; y--)
{
if (x <= a)
{
*b = 0;
return;
}
if (*--x != ' ')
break;
}
*y-- = 0;
do
*y-- = *x;
while (x-- > a);
}
The problem appears to be that loop-iv.c uses get_mode_bounds to find that the
max value for an unsigned SImode is 0xffffffff, and then uses this constant
directly in SImode RTL expressions, without converting the value via
trunc_int_for_mode.
--
Summary: loop2 creates invalid rtl
Product: gcc
Version: 3.5.0
Status: UNCONFIRMED
Keywords: ice-on-valid-code
Severity: normal
Priority: P2
Component: optimization
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: amodra at bigpond dot net dot au
CC: gcc-bugs at gcc dot gnu dot org
GCC target triplet: powerpc-linux
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15274
More information about the Gcc-bugs
mailing list