From: Richard Biener Date: Tue, 7 May 2019 13:07:48 +0000 (+0000) Subject: tree-vect-stmts.c (vect_is_simple_cond): When vectype is not specified still compute... X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=fcd0566b03e8e22190590bda888b48349639f1a0;p=gcc.git tree-vect-stmts.c (vect_is_simple_cond): When vectype is not specified still compute a comp_vectype for invariant compares. 2019-05-07 Richard Biener * tree-vect-stmts.c (vect_is_simple_cond): When vectype is not specified still compute a comp_vectype for invariant compares. From-SVN: r270945 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index cd4eb091d2a..8770f865335 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2019-05-07 Richard Biener + + * tree-vect-stmts.c (vect_is_simple_cond): When vectype is + not specified still compute a comp_vectype for invariant + compares. + 2019-05-07 Richard Biener PR tree-optimization/90316 diff --git a/gcc/tree-vect-stmts.c b/gcc/tree-vect-stmts.c index 98e6df747e9..ced4264722c 100644 --- a/gcc/tree-vect-stmts.c +++ b/gcc/tree-vect-stmts.c @@ -8864,11 +8864,12 @@ vect_is_simple_cond (tree cond, vec_info *vinfo, *comp_vectype = vectype1 ? vectype1 : vectype2; /* Invariant comparison. */ - if (! *comp_vectype && vectype) + if (! *comp_vectype) { tree scalar_type = TREE_TYPE (lhs); /* If we can widen the comparison to match vectype do so. */ if (INTEGRAL_TYPE_P (scalar_type) + && vectype && tree_int_cst_lt (TYPE_SIZE (scalar_type), TYPE_SIZE (TREE_TYPE (vectype)))) scalar_type = build_nonstandard_integer_type