comparison gcc/testsuite/gcc.dg/20041104-1.c @ 111:04ced10e8804

gcc 7
author kono
date Fri, 27 Oct 2017 22:46:09 +0900
parents
children
comparison
equal deleted inserted replaced
68:561a7518be6b 111:04ced10e8804
1 /* This testcase exposed the same bug as PR 15342. */
2 /* { dg-options "-O2 -frename-registers -fno-schedule-insns" } */
3
4 void *memcpy (void *, const void *, __SIZE_TYPE__);
5
6 void f (int n, int (*x)[4])
7 {
8 while (n--)
9 {
10 int f = x[0][0];
11 if (f <= 0)
12 memcpy (&x[1], &x[0], sizeof (x[0]));
13 else
14 memcpy (&x[f], &x[0], sizeof (x[0]));
15 f = x[0][2];
16 x[0][1] = f;
17 }
18 }