mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-04-13 21:01:29 +08:00
re PR middle-end/55481 (-O2 generates a wrong-code infinite loop in C++Benchmark's simple_types_constant_folding int8 xor test)
2013-03-01 Richard Biener <rguenther@suse.de> PR tree-optimization/55481 * gcc.dg/torture/pr56488.c: New testcase. From-SVN: r196377
This commit is contained in:
parent
76c1a7ec3d
commit
d3e1a77949
@ -1,3 +1,8 @@
|
||||
2013-03-01 Richard Biener <rguenther@suse.de>
|
||||
|
||||
PR tree-optimization/55481
|
||||
* gcc.dg/torture/pr56488.c: New testcase.
|
||||
|
||||
2013-02-28 Konstantin Serebryany <konstantin.s.serebryany@gmail.com>
|
||||
Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
|
31
gcc/testsuite/gcc.dg/torture/pr56488.c
Normal file
31
gcc/testsuite/gcc.dg/torture/pr56488.c
Normal file
@ -0,0 +1,31 @@
|
||||
/* { dg-do run } */
|
||||
|
||||
int a, c, d = 1;
|
||||
struct S { int s; } b, f;
|
||||
short e;
|
||||
|
||||
static void
|
||||
foo (int x)
|
||||
{
|
||||
int g[] = { };
|
||||
for (e = 0; e != 1; e = e + 5)
|
||||
{
|
||||
int *h[1] = { &g[0] };
|
||||
if (!x)
|
||||
return;
|
||||
f = b;
|
||||
}
|
||||
}
|
||||
|
||||
int
|
||||
main ()
|
||||
{
|
||||
int i, j;
|
||||
for (i = 0; i < 6; i++)
|
||||
for (j = 8; j; j--)
|
||||
a = 0;
|
||||
foo (d);
|
||||
while (c)
|
||||
;
|
||||
return 0;
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user