diff options
Diffstat (limited to 'gcc/testsuite/gcc.dg/tree-ssa/ssa-dom-dse-1.c')
-rw-r--r-- | gcc/testsuite/gcc.dg/tree-ssa/ssa-dom-dse-1.c | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.dg/tree-ssa/ssa-dom-dse-1.c b/gcc/testsuite/gcc.dg/tree-ssa/ssa-dom-dse-1.c new file mode 100644 index 000000000..504e4bc03 --- /dev/null +++ b/gcc/testsuite/gcc.dg/tree-ssa/ssa-dom-dse-1.c @@ -0,0 +1,19 @@ +/* { dg-do compile } */ +/* { dg-options "-O -fdump-tree-optimized" } */ + +int x; +void +foo (void) +{ + if (x == 0) + x = 0; +} +void +bar (int i) +{ + if (x == i) + x = i; +} + +/* { dg-final { scan-tree-dump-not "x =" "optimized" } } */ +/* { dg-final { cleanup-tree-dump "optimized" } } */ |