diff options
author | Dorit Naishlos <dorit@il.ibm.com> | 2005-03-15 18:33:09 +0000 |
---|---|---|
committer | Dorit Nuzman <dorit@gcc.gnu.org> | 2005-03-15 18:33:09 +0000 |
commit | 5f55a1ba12917c33d8339180f6d432076ac931da (patch) | |
tree | aa609c29139804fa11435795fdbdacaccff79d8f /gcc/tree-vectorizer.c | |
parent | 119bb233e2d4a695ec26cff09be08f6c2b6f7a44 (diff) | |
download | gcc-5f55a1ba12917c33d8339180f6d432076ac931da.zip gcc-5f55a1ba12917c33d8339180f6d432076ac931da.tar.gz gcc-5f55a1ba12917c33d8339180f6d432076ac931da.tar.bz2 |
tree-vectorizer.h (unknown_alignment_for_access_p): Replaced by known_alignment_for_access_p.
* tree-vectorizer.h (unknown_alignment_for_access_p): Replaced by
known_alignment_for_access_p.
(known_alignment_for_access_p): New.
(do_peeling_for_alignment): Field made int instead of bool and renamed
to peeling_for_alignment.
(LOOP_DO_PEELING_FOR_ALIGNMENT): Renamed to LOOP_PEELING_FOR_ALIGNMENT.
* tree-vect-analyze.c (vect_determine_vectorization_factor): New. This
functionality used to be in vect_analyze_operations.
(vect_analyze_operations): Code to determine vectorization factor was
moved to vect_determine_vectorization_factor.
(vect_enhance_data_refs_alignment): Update to correct alignment when it
is known instead of -1. Set LOOP_PEELING_FOR_ALIGNMENT to peeling
factor.
(vect_analyze_loop): Call vect_determine_vectorization_factor (used to
be part of vect_analyze_operations).
* tree-vectorizer.c (slpeel_tree_peel_loop_to_edge): Use fold when
creating the guard condition, as the number of iterations may be
constant.
(slpeel_tree_peel_loop_to_edge): Use new name of
LOOP_DO_PEELING_FOR_ALIGNMENT. Set it to 0 instead of false.
* tree-vect-transform.c (vect_gen_niters_for_prolog_loop): Handle known
alignment case more efficiently. Use LOOP_PEELING_FOR_ALIGNMENT.
(vect_do_peeling_for_alignment): Use fold.
(vect_transform_loop): Use new name of LOOP_DO_PEELING_FOR_ALIGNMENT.
(vect_update_inits_of_dr): Renamed to
vect_update_init_of_dr.
(vect_update_inits_of_drs): Use new name of vect_update_inits_of_dr.
(vectorizable_store): Fix assertion to use == instead of =.
From-SVN: r96526
Diffstat (limited to 'gcc/tree-vectorizer.c')
-rw-r--r-- | gcc/tree-vectorizer.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/gcc/tree-vectorizer.c b/gcc/tree-vectorizer.c index 08a923e..82c1088 100644 --- a/gcc/tree-vectorizer.c +++ b/gcc/tree-vectorizer.c @@ -963,7 +963,7 @@ slpeel_tree_peel_loop_to_edge (struct loop *loop, struct loops *loops, add_bb_to_loop (bb_before_second_loop, first_loop->outer); pre_condition = - build2 (LE_EXPR, boolean_type_node, first_niters, integer_zero_node); + fold (build2 (LE_EXPR, boolean_type_node, first_niters, integer_zero_node)); 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_guard (skip_e, first_loop, true /* entry-phis */, @@ -1001,7 +1001,8 @@ slpeel_tree_peel_loop_to_edge (struct loop *loop, struct loops *loops, bb_after_second_loop = split_edge (second_loop->single_exit); add_bb_to_loop (bb_after_second_loop, second_loop->outer); - pre_condition = build2 (EQ_EXPR, boolean_type_node, first_niters, niters); + pre_condition = + fold (build2 (EQ_EXPR, boolean_type_node, first_niters, niters)); skip_e = slpeel_add_loop_guard (bb_between_loops, pre_condition, bb_after_second_loop, bb_before_first_loop); slpeel_update_phi_nodes_for_guard (skip_e, second_loop, false /* exit-phis */, @@ -1213,7 +1214,7 @@ new_loop_vec_info (struct loop *loop) LOOP_VINFO_EXIT_COND (res) = NULL; LOOP_VINFO_NITERS (res) = NULL; LOOP_VINFO_VECTORIZABLE_P (res) = 0; - LOOP_DO_PEELING_FOR_ALIGNMENT (res) = false; + LOOP_PEELING_FOR_ALIGNMENT (res) = 0; LOOP_VINFO_VECT_FACTOR (res) = 0; VARRAY_GENERIC_PTR_INIT (LOOP_VINFO_DATAREF_WRITES (res), 20, "loop_write_datarefs"); |