aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-vectorizer.c
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2017-12-12 09:55:02 +0100
committerJakub Jelinek <jakub@gcc.gnu.org>2017-12-12 09:55:02 +0100
commit12c667b5b449a9c86c763438fb96e6e029533fb7 (patch)
tree8fc6551cd16156c3e02209066ef1b2eaf1da2365 /gcc/tree-vectorizer.c
parent5b0c69ae65b713ab68202af20dae9dca533d39cf (diff)
downloadgcc-12c667b5b449a9c86c763438fb96e6e029533fb7.zip
gcc-12c667b5b449a9c86c763438fb96e6e029533fb7.tar.gz
gcc-12c667b5b449a9c86c763438fb96e6e029533fb7.tar.bz2
re PR tree-optimization/80631 (Compiling with -O3 -mavx2 gives wrong code)
PR tree-optimization/80631 * tree-vect-loop.c (get_initial_def_for_reduction): Fix comment typo. (vect_create_epilog_for_reduction): Add INDUC_VAL and INDUC_CODE arguments, for INTEGER_INDUC_COND_REDUCTION use INDUC_VAL instead of hardcoding zero as the value if COND_EXPR is never true. For INTEGER_INDUC_COND_REDUCTION don't emit the final COND_EXPR if INDUC_VAL is equal to INITIAL_DEF, and use INDUC_CODE instead of hardcoding MAX_EXPR as the reduction operation. (is_nonwrapping_integer_induction): Allow negative step. (vectorizable_reduction): Compute INDUC_VAL and INDUC_CODE for vect_create_epilog_for_reduction, if no value is suitable, don't use INTEGER_INDUC_COND_REDUCTION for now. Formatting fixes. * gcc.dg/vect/pr80631-1.c: New test. * gcc.dg/vect/pr80631-2.c: New test. * gcc.dg/vect/pr65947-13.c: Expect integer induc cond reduction vectorization. From-SVN: r255574
Diffstat (limited to 'gcc/tree-vectorizer.c')
0 files changed, 0 insertions, 0 deletions