new loop c-torture test
Joern Rennecke
amylaar@cygnus.co.uk
Tue Aug 25 16:02:00 GMT 1998
This fails at -O2 for x86; it's slightly modified from loop-4.c to
trigger an overflow to positive in check_dbra_loop.
I think we should also have an existing problem with loop-4.c when
cross-compiling from a 64 bit host to a 32 bit target.
int
f()
{
int j = 1;
long i;
i = 0x60000000L;
do
{
j <<= 1;
i += 0x10000000L;
} while (i < -0x60000000L);
return j;
}
int
main ()
{
if (f () != 2)
abort ();
exit (0);
}
More information about the Gcc
mailing list