2012-07-06 Tom de Vries <tom@codesourcery.com>
PR tree-optimization/52009
* gcc.dg/pr51879-7.c: New test.
* gcc.dg/pr51879-18.c: New test.
From-SVN: r189322
+2012-07-06 Tom de Vries <tom@codesourcery.com>
+
+ PR tree-optimization/52009
+ * gcc.dg/pr51879-7.c: New test.
+ * gcc.dg/pr51879-18.c: New test.
+
2012-07-05 Jason Merrill <jason@redhat.com>
PR c++/50852
--- /dev/null
+/* { dg-do compile } */
+/* { dg-options "-O2 -fdump-tree-pre -fno-tree-copy-prop -fno-tree-dominator-opts -fno-tree-copyrename" } */
+
+extern int foo (void);
+
+void bar (int c, int *p)
+{
+ int *q = p;
+
+ if (c)
+ *p = foo ();
+ else
+ *q = foo ();
+}
+
+/* { dg-final { scan-tree-dump-times "foo \\(" 1 "pre"} } */
+/* { dg-final { cleanup-tree-dump "pre" } } */
--- /dev/null
+/* { dg-do compile } */
+/* { dg-options "-O2 -fdump-tree-pre" } */
+
+int bar (int);
+
+int z;
+
+void
+foo (int y)
+{
+ if (y == 6)
+ z = 5;
+ else
+ z = 5;
+}
+
+/* { dg-final { scan-tree-dump-times "z = 5" 1 "pre"} } */
+/* { dg-final { cleanup-tree-dump "pre" } } */