From: Ilya Enkovich Date: Tue, 19 Jul 2016 10:04:02 +0000 (+0000) Subject: tree-vect-loop-manip.c (vect_update_ivs_after_vectorizer): Update comment. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=d9157f1514cb8f9e64e4b57c5461a9bb9b03427f;p=gcc.git tree-vect-loop-manip.c (vect_update_ivs_after_vectorizer): Update comment. gcc/ * tree-vect-loop-manip.c (vect_update_ivs_after_vectorizer): Update comment. (vect_update_inits_of_drs): Likewise. (vect_create_cond_for_alias_checks): Likewise. * tree-vect-loop.c (vect_get_known_peeling_cost): Likewise. From-SVN: r238466 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index bff71602ecf..43890647f3b 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,11 @@ +2016-07-19 Ilya Enkovich + + * tree-vect-loop-manip.c (vect_update_ivs_after_vectorizer): Update + comment. + (vect_update_inits_of_drs): Likewise. + (vect_create_cond_for_alias_checks): Likewise. + * tree-vect-loop.c (vect_get_known_peeling_cost): Likewise. + 2016-07-19 Richard Biener PR lto/71907 diff --git a/gcc/tree-vect-loop-manip.c b/gcc/tree-vect-loop-manip.c index 93b29b72fd5..819abcda81a 100644 --- a/gcc/tree-vect-loop-manip.c +++ b/gcc/tree-vect-loop-manip.c @@ -1735,6 +1735,10 @@ vect_update_ivs_after_vectorizer (loop_vec_info loop_vinfo, tree niters, iterates NITERS times, the new epilog loop iterates NITERS % VECTORIZATION_FACTOR times. + If CHECK_PROFITABILITY is 1 then profitability check is generated + using TH as a cost model profitability threshold of iterations for + vectorization. + The original loop will later be made to iterate NITERS / VECTORIZATION_FACTOR times (this value is placed into RATIO). @@ -1993,7 +1997,11 @@ vect_update_inits_of_drs (loop_vec_info loop_vinfo, tree niters) 'niters' is set to the misalignment of one of the data references in the loop, thereby forcing it to refer to an aligned location at the beginning of the execution of this loop. The data reference for which we are - peeling is recorded in LOOP_VINFO_UNALIGNED_DR. */ + peeling is recorded in LOOP_VINFO_UNALIGNED_DR. + + If CHECK_PROFITABILITY is 1 then profitability check is generated + using TH as a cost model profitability threshold of iterations for + vectorization. */ void vect_do_peeling_for_alignment (loop_vec_info loop_vinfo, tree ni_name, @@ -2313,7 +2321,7 @@ vect_create_cond_for_alias_checks (loop_vec_info loop_vinfo, tree * cond_expr) The test generated to check which version of loop is executed is modified to also check for profitability as indicated by the - cost model initially. + cost model threshold TH. The versioning precondition(s) are placed in *COND_EXPR and *COND_EXPR_STMT_LIST. */ diff --git a/gcc/tree-vect-loop.c b/gcc/tree-vect-loop.c index 11863af66fc..2a7e0c6661b 100644 --- a/gcc/tree-vect-loop.c +++ b/gcc/tree-vect-loop.c @@ -3065,7 +3065,15 @@ vect_get_known_peeling_cost (loop_vec_info loop_vinfo, int peel_iters_prologue, Return the number of iterations required for the vector version of the loop to be profitable relative to the cost of the scalar version of the - loop. */ + loop. + + *RET_MIN_PROFITABLE_NITERS is a cost model profitability threshold + of iterations for vectorization. -1 value means loop vectorization + is not profitable. This returned value may be used for dynamic + profitability check. + + *RET_MIN_PROFITABLE_ESTIMATE is a profitability threshold to be used + for static check against estimated number of iterations. */ static void vect_estimate_min_profitable_iters (loop_vec_info loop_vinfo,