aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2010-11-03 10:49:16 +0100
committerJakub Jelinek <jakub@gcc.gnu.org>2010-11-03 10:49:16 +0100
commit71056fef3b000a8b1e4793b3aa064c033588908f (patch)
tree7b8b7d7ad30b46e210beddd0a1730b34001839c7 /gcc/testsuite
parent48215350c24d524b635d6110eca1e70996f5fb82 (diff)
downloadgcc-71056fef3b000a8b1e4793b3aa064c033588908f.zip
gcc-71056fef3b000a8b1e4793b3aa064c033588908f.tar.gz
gcc-71056fef3b000a8b1e4793b3aa064c033588908f.tar.bz2
re PR tree-optimization/46107 (-ftree-loop-distribute-patterns caused verify_loop_structure problem)
PR tree-optimization/46107 * cfgloopmanip.c (loop_version): Set irred_flag back into entry->flags if cfg_hook_duplicate_loop_to_header_edge failed. * gcc.c-torture/compile/pr46107.c: New test. From-SVN: r166234
Diffstat (limited to 'gcc/testsuite')
-rw-r--r--gcc/testsuite/ChangeLog3
-rw-r--r--gcc/testsuite/gcc.c-torture/compile/pr46107.c16
2 files changed, 19 insertions, 0 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index bb14d86..7af642f 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,5 +1,8 @@
2010-11-03 Jakub Jelinek <jakub@redhat.com>
+ PR tree-optimization/46107
+ * gcc.c-torture/compile/pr46107.c: New test.
+
PR debug/46252
* gcc.dg/pr46252.c: New test.
diff --git a/gcc/testsuite/gcc.c-torture/compile/pr46107.c b/gcc/testsuite/gcc.c-torture/compile/pr46107.c
new file mode 100644
index 0000000..41582b8
--- /dev/null
+++ b/gcc/testsuite/gcc.c-torture/compile/pr46107.c
@@ -0,0 +1,16 @@
+/* PR tree-optimization/46107 */
+
+int foo (void) __attribute__ ((noreturn));
+
+void
+bar (int x, int *y, int z)
+{
+ static void *j[] = { &&l1, &&l2 };
+l1:
+ if (*y)
+ goto *j[z];
+ foo ();
+l2:
+ *y ^= (x & 1) ? -1 : 0;
+ goto *j[x];
+}