summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/tree-ssa/20040216-1.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/gcc.dg/tree-ssa/20040216-1.c')
-rw-r--r--gcc/testsuite/gcc.dg/tree-ssa/20040216-1.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.dg/tree-ssa/20040216-1.c b/gcc/testsuite/gcc.dg/tree-ssa/20040216-1.c
new file mode 100644
index 000000000..c770340a7
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/tree-ssa/20040216-1.c
@@ -0,0 +1,18 @@
+/* { dg-do compile } */
+/* { dg-options "-O1 -fdump-tree-dse1-details" } */
+
+foo(int *z, int *y, int xx)
+{
+ *z = 1;
+ if (xx)
+ xx = 20;
+ else
+ xx = 30;
+ *z = 2;
+ *z = 3;
+ return xx;
+}
+
+/* We should convert two COND_EXPRs into straightline code. */
+/* { dg-final { scan-tree-dump-times "Deleted dead store" 2 "dse1"} } */
+/* { dg-final { cleanup-tree-dump "dse1" } } */