Debian Codegraph @

gcc/testsuite/gcc.dg/torture/pr79351.c

raw
1 /* { dg-do run } */
2
3 static struct state {
4 int k;
5 int dummy;
6 } states[256];
7
8 __attribute((noipa))
9 static void
10 ismatch(int n)
11 {
12 for (int j=0; j<n; j++) {
13 states[j] = (struct state){0};
14 for (int i = 0; i <= j; i++) {
15 states[i].k++;
16 }
17 }
18 }
19
20 int
21 main()
22 {
23 ismatch(2);
24 if (states[0].k != 2)
25 __builtin_abort();
26 }