Debian Codegraph @

gcc/testsuite/gcc.dg/tree-ssa/ssa-dce-4.c

raw
1 /* { dg-do compile } */
2 /* { dg-options "-O -fno-tree-fre -fdump-tree-cddce1" } */
3
4 int foo(int b)
5 {
6 int a[128];
7 a[b] = 1;
8 if (b)
9 {
10 b = 2;
11 a[2] = 0;
12 }
13 a[2] = 3;
14 return a[2] + b;
15 }
16
17 /* Verify DCE removes all accesses to a but the last store and the
18 read from a[2]. */
19 /* { dg-final { scan-tree-dump-times "a\\\[\[^\n\]\\\]" 2 "cddce1" } } */