https://gcc.gnu.org/g:86708a88fb53518f1a54105c1fd006b57f14e7ce

commit r15-5235-g86708a88fb53518f1a54105c1fd006b57f14e7ce
Author: Richard Biener <rguent...@suse.de>
Date:   Tue Nov 12 13:55:14 2024 +0100

    Remove last comparison-code expand_vec_cond_expr_p call from vectorizer
    
    The following refactors the check with the last remaininig
    expand_vec_cond_expr_p call with a comparison code to make it
    obvious we are not relying on those anymore.
    
            * tree-vect-stmts.cc (vectorizable_condition): Refactor
            target support check.

Diff:
---
 gcc/tree-vect-stmts.cc | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/gcc/tree-vect-stmts.cc b/gcc/tree-vect-stmts.cc
index 5d731205675e..a83a46ea0dd9 100644
--- a/gcc/tree-vect-stmts.cc
+++ b/gcc/tree-vect-stmts.cc
@@ -12460,9 +12460,9 @@ vectorizable_condition (vec_info *vinfo,
       if (reduction_type == EXTRACT_LAST_REDUCTION)
        /* Count one reduction-like operation per vector.  */
        kind = vec_to_scalar;
-      else if (!expand_vec_cond_expr_p (vectype, comp_vectype, cond_code)
-              && (masked
-                  || (!expand_vec_cmp_expr_p (comp_vectype, vec_cmp_type,
+      else if ((masked && !expand_vec_cond_expr_p (vectype, comp_vectype))
+              || (!masked
+                  && (!expand_vec_cmp_expr_p (comp_vectype, vec_cmp_type,
                                               cond_code)
                       || !expand_vec_cond_expr_p (vectype, vec_cmp_type))))
        return false;

Reply via email to