aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-vect-data-refs.c
diff options
context:
space:
mode:
authorIra Rosen <irar@il.ibm.com>2010-09-14 09:21:15 +0000
committerIra Rosen <irar@gcc.gnu.org>2010-09-14 09:21:15 +0000
commit5a2c19863869535ff6487951a5732adb114bfb4a (patch)
tree6da9c4af4cb3e9b8356610815ee0416a055f567b /gcc/tree-vect-data-refs.c
parent2f78283b38be196f4c8050688853404d41e7d8d1 (diff)
downloadgcc-5a2c19863869535ff6487951a5732adb114bfb4a.zip
gcc-5a2c19863869535ff6487951a5732adb114bfb4a.tar.gz
gcc-5a2c19863869535ff6487951a5732adb114bfb4a.tar.bz2
re PR tree-optimization/45470 (ICE: verify_flow_info failed: BB 2 can not throw but has an EH edge with -ftree-vectorize -fnon-call-exceptions)
PR tree-optimization/45470 * tree-vect-data-refs.c (vect_analyze_data_refs): Fail if a statement can throw an exception. * tree-vect-stmts.c (vectorizable_call): Likewise. From-SVN: r164270
Diffstat (limited to 'gcc/tree-vect-data-refs.c')
-rw-r--r--gcc/tree-vect-data-refs.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/gcc/tree-vect-data-refs.c b/gcc/tree-vect-data-refs.c
index ff4f0db..264a107 100644
--- a/gcc/tree-vect-data-refs.c
+++ b/gcc/tree-vect-data-refs.c
@@ -2542,6 +2542,17 @@ vect_analyze_data_refs (loop_vec_info loop_vinfo,
offset = unshare_expr (DR_OFFSET (dr));
init = unshare_expr (DR_INIT (dr));
+ if (stmt_could_throw_p (stmt))
+ {
+ if (vect_print_dump_info (REPORT_UNVECTORIZED_LOCATIONS))
+ {
+ fprintf (vect_dump, "not vectorized: statement can throw an "
+ "exception ");
+ print_gimple_stmt (vect_dump, stmt, 0, TDF_SLIM);
+ }
+ return false;
+ }
+
/* Update DR field in stmt_vec_info struct. */
/* If the dataref is in an inner-loop of the loop that is considered for