This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[lno] [patch] vectorization of loops with constant loop bound


This patch extends vectorization support on loops with
constant loop bound non-divisible by vectorization factor.
(Vectorization of loops with constant loop bound divisible
by vectorization factor was always supported.)

We treat this case in the way similar to one used for
unknown loop bound support. The epilog loop is peeled
from original so that original loop iterates number of times divisible
by vectorization factor.

The test case below demonstrates new functionality.

olga


        * tree-vectorizer.c (get_phi_node_for_def): Removed.
        (update_phi_nodes_for_guard, tree_duplicate_loop_to_edge_cfg):
Updated.
        (tree_duplicate_loop_to_edge): Updated.
        (vect_generate_tmps_on_preheader): Treating also case of constant.
        (vect_transform_loop): Treating also case of constant
        non-divisibale by VF.
        (vect_analyze_operations): Remove redundant check.
        * vect-69.c : Additional test case passes.

(See attached file: vect-70.c)(See attached file: diff.known_loop_bound)

Attachment: vect-70.c
Description: Binary data

Attachment: diff.known_loop_bound
Description: Binary data


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]