aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-ssa-loop-unswitch.c
diff options
context:
space:
mode:
authorYuri Rumyantsev <ysrumyan@gmail.com>2016-05-06 12:07:25 +0000
committerIlya Enkovich <ienkovich@gcc.gnu.org>2016-05-06 12:07:25 +0000
commit19aa23d84ee1f001e748f8f8a6da9982dcc30a39 (patch)
tree7460f88f930ef5913a1a8a12d79564b581d3e484 /gcc/tree-ssa-loop-unswitch.c
parentac0e4fdebcb5796d4f21c47f2b75bad7866f6366 (diff)
downloadgcc-19aa23d84ee1f001e748f8f8a6da9982dcc30a39.zip
gcc-19aa23d84ee1f001e748f8f8a6da9982dcc30a39.tar.gz
gcc-19aa23d84ee1f001e748f8f8a6da9982dcc30a39.tar.bz2
re PR debug/70935 (ICE: verify_ssa failed (error: definition in block 9 does not dominate use in block 12) w/ -O3 -g)
gcc/ 2016-05-06 Yuri Rumyantsev <ysrumyan@gmail.com> PR debug/70935 * tree-ssa-loop-unswitch.c (find_loop_guard): Reject guard edge with loop latch destination. gcc/testsuite/ 2016-05-06 Yuri Rumyantsev <ysrumyan@gmail.com> PR debug/70935 * gcc.dg/torture/pr70935.c: New test. From-SVN: r235962
Diffstat (limited to 'gcc/tree-ssa-loop-unswitch.c')
-rw-r--r--gcc/tree-ssa-loop-unswitch.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/gcc/tree-ssa-loop-unswitch.c b/gcc/tree-ssa-loop-unswitch.c
index 77acd66..bf9fafa6 100644
--- a/gcc/tree-ssa-loop-unswitch.c
+++ b/gcc/tree-ssa-loop-unswitch.c
@@ -536,6 +536,12 @@ find_loop_guard (struct loop *loop)
guard_edge->src->index, guard_edge->dest->index);
return NULL;
}
+ if (guard_edge->dest == loop->latch)
+ {
+ if (dump_file && (dump_flags & TDF_DETAILS))
+ fprintf (dump_file, "Guard edge destination is loop latch.\n");
+ return NULL;
+ }
if (dump_file && (dump_flags & TDF_DETAILS))
fprintf (dump_file,