summaryrefslogtreecommitdiff
path: root/gcc/tree-vectorizer.c
diff options
context:
space:
mode:
authordorit <dorit@138bc75d-0d04-0410-961f-82ee72b054a4>2007-01-14 12:42:40 +0000
committerdorit <dorit@138bc75d-0d04-0410-961f-82ee72b054a4>2007-01-14 12:42:40 +0000
commit8964b5be03c9f48198829e79ace6a84122004bcf (patch)
treec1d065e5ba09e4c5a85904acf9038d65101037cd /gcc/tree-vectorizer.c
parent67ed5d34a0744ef637049974b3508165e62d1a69 (diff)
downloadgcc-8964b5be03c9f48198829e79ace6a84122004bcf.tar.gz
* param.h (MIN_VECT_LOOP_BOUND): New.
* params.def (MIN_VECT_LOOP_BOUND): New. * tree-vectorizer.c (slpeel_tree_peel_loop_to_edge): Takes another argument - minimum threshold for number of iterations. * tree-vectorizer.h (slpeel_tree_peel_loop_to_edge): Add another argument to declaration. * tree-vect-analyze.c (vect_analyze_operations): Check value of MIN_VECT_LOOP_BOUND. * tree-vect-transform.c (vect_do_peeling_for_loop_bound): Call slpeel_tree_peel_loop_to_edge with additional argument. (vect_do_peeling_for_alignment): Likewise. * doc/invoke.texi (min-vect-loop-bound): Document new param option. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@120770 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/tree-vectorizer.c')
-rw-r--r--gcc/tree-vectorizer.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/gcc/tree-vectorizer.c b/gcc/tree-vectorizer.c
index c3b64e2ed6e..7fb98577951 100644
--- a/gcc/tree-vectorizer.c
+++ b/gcc/tree-vectorizer.c
@@ -1064,7 +1064,8 @@ slpeel_verify_cfg_after_peeling (struct loop *first_loop,
struct loop*
slpeel_tree_peel_loop_to_edge (struct loop *loop,
edge e, tree first_niters,
- tree niters, bool update_first_loop_count)
+ tree niters, bool update_first_loop_count,
+ unsigned int th)
{
struct loop *new_loop = NULL, *first_loop, *second_loop;
edge skip_e;
@@ -1157,7 +1158,8 @@ slpeel_tree_peel_loop_to_edge (struct loop *loop,
pre_condition =
fold_build2 (LE_EXPR, boolean_type_node, first_niters,
- build_int_cst (TREE_TYPE (first_niters), 0));
+ build_int_cst (TREE_TYPE (first_niters), th));
+
skip_e = slpeel_add_loop_guard (bb_before_first_loop, pre_condition,
bb_before_second_loop, bb_before_first_loop);
slpeel_update_phi_nodes_for_guard1 (skip_e, first_loop,