+2019-03-11 Richard Biener <rguenther@suse.de>
+
+ PR tree-optimization/89649
+ * tree-vectorizer.h (vect_loop_versioning): Adjust prototype.
+ * tree-vect-loop-manip.c (vect_do_peeling): Unset force_vectorize
+ on the prolog and epilog loops.
+ (vect_loop_versioning): Return copy of loop.
+ * tree-vect-loop.c (vect_transform_loop): Unset force_vectorize
+ on the non-vectorized version of the loop.
+
2019-03-10 Uroš Bizjak <ubizjak@gmail.com>
PR target/68924
"slpeel_tree_duplicate_loop_to_edge_cfg failed.\n");
gcc_unreachable ();
}
+ prolog->force_vectorize = false;
slpeel_update_phi_nodes_for_loops (loop_vinfo, prolog, loop, true);
first_loop = prolog;
reset_original_copy_tables ();
"slpeel_tree_duplicate_loop_to_edge_cfg failed.\n");
gcc_unreachable ();
}
+ epilog->force_vectorize = false;
slpeel_update_phi_nodes_for_loops (loop_vinfo, loop, epilog, false);
/* Scalar version loop may be preferred. In this case, add guard
The versioning precondition(s) are placed in *COND_EXPR and
*COND_EXPR_STMT_LIST. */
-void
+struct loop *
vect_loop_versioning (loop_vec_info loop_vinfo,
unsigned int th, bool check_profitability,
poly_uint64 versioning_threshold)
GSI_SAME_STMT);
}
update_ssa (TODO_update_ssa);
+
+ return nloop;
}
versioning_threshold);
check_profitability = false;
}
- vect_loop_versioning (loop_vinfo, th, check_profitability,
- versioning_threshold);
+ struct loop *sloop
+ = vect_loop_versioning (loop_vinfo, th, check_profitability,
+ versioning_threshold);
+ sloop->force_vectorize = false;
check_profitability = false;
}
extern bool slpeel_can_duplicate_loop_p (const struct loop *, const_edge);
struct loop *slpeel_tree_duplicate_loop_to_edge_cfg (struct loop *,
struct loop *, edge);
-extern void vect_loop_versioning (loop_vec_info, unsigned int, bool,
- poly_uint64);
+struct loop *vect_loop_versioning (loop_vec_info, unsigned int, bool,
+ poly_uint64);
extern struct loop *vect_do_peeling (loop_vec_info, tree, tree,
tree *, tree *, tree *, int, bool, bool);
extern void vect_prepare_for_masked_peels (loop_vec_info);