// test case, compile with -O3
int foo1 (void);
void foo2 (int);
static int foo9 (int k)
{
return ((k == 0x00) || (k == 0x10) || (k == 0x14));
}
static int foo8 (int *p)
{
return *p;
}
void foo6 (int *p)
{
int a, b, c, d, e = 0;
foo8 (p);
b = 0;
do
{
b++;
a = foo1();
}
while (b < 3 && (!foo9 (a)));
repeat:
d = 3;
do
{
c = foo1 ();
if (c)
foo1 ();
d--;
}
while (c && d);
if (c && !e)
{
foo2 (c);
return;
}
if (!e)
{
e = 1;
goto repeat;
}
}
// compiler output:
sd.i: In function 'foo6':
sd.i:15: internal compiler error: in check_loop_closed_ssa_use, at
tree-ssa-loop-manip.c:398
--
Summary: ICE in check_loop_closed_ssa_use, at tree-ssa-loop-
manip.c:398
Product: gcc
Version: 4.1.0
Status: UNCONFIRMED
Keywords: ice-on-valid-code
Severity: normal
Priority: P2
Component: tree-optimization
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: belyshev at depni dot sinp dot msu dot ru
CC: gcc-bugs at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23817