public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc(refs/users/rguenth/heads/vect-force-slp)] Allow single-lane SLP in-order reductions
@ 2024-03-05 14:47 Richard Biener
  0 siblings, 0 replies; 2+ messages in thread
From: Richard Biener @ 2024-03-05 14:47 UTC (permalink / raw)
  To: gcc-cvs

https://gcc.gnu.org/g:27d303e79de67aeaa58f44e1261c7e4748701037

commit 27d303e79de67aeaa58f44e1261c7e4748701037
Author: Richard Biener <rguenther@suse.de>
Date:   Tue Mar 5 15:46:24 2024 +0100

    Allow single-lane SLP in-order reductions
    
    The single-lane case isn't different from non-SLP, no re-association
    implied.
    
            * tree-vect-loop.cc (vectorizable_reduction): Allow
            single-lane SLP in-order reductions.

Diff:
---
 gcc/tree-vect-loop.cc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gcc/tree-vect-loop.cc b/gcc/tree-vect-loop.cc
index 42c8a366e68..1da195f9f02 100644
--- a/gcc/tree-vect-loop.cc
+++ b/gcc/tree-vect-loop.cc
@@ -8177,7 +8177,7 @@ vectorizable_reduction (loop_vec_info loop_vinfo,
     }
 
   if (reduction_type == FOLD_LEFT_REDUCTION
-      && slp_node
+      && (slp_node && SLP_TREE_LANES (slp_node) > 1)
       && !REDUC_GROUP_FIRST_ELEMENT (stmt_info))
     {
       /* We cannot use in-order reductions in this case because there is

^ permalink raw reply	[flat|nested] 2+ messages in thread

* [gcc(refs/users/rguenth/heads/vect-force-slp)] Allow single-lane SLP in-order reductions
@ 2024-05-13 14:28 Richard Biener
  0 siblings, 0 replies; 2+ messages in thread
From: Richard Biener @ 2024-05-13 14:28 UTC (permalink / raw)
  To: gcc-cvs

https://gcc.gnu.org/g:0faad9e4dfa5015c9535e4f2a40400914c5b4674

commit 0faad9e4dfa5015c9535e4f2a40400914c5b4674
Author: Richard Biener <rguenther@suse.de>
Date:   Tue Mar 5 15:46:24 2024 +0100

    Allow single-lane SLP in-order reductions
    
    The single-lane case isn't different from non-SLP, no re-association
    implied.
    
            * tree-vect-loop.cc (vectorizable_reduction): Allow
            single-lane SLP in-order reductions.

Diff:
---
 gcc/tree-vect-loop.cc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gcc/tree-vect-loop.cc b/gcc/tree-vect-loop.cc
index 8fb8800e6a7e..a5597ec1287b 100644
--- a/gcc/tree-vect-loop.cc
+++ b/gcc/tree-vect-loop.cc
@@ -8134,7 +8134,7 @@ vectorizable_reduction (loop_vec_info loop_vinfo,
     }
 
   if (reduction_type == FOLD_LEFT_REDUCTION
-      && slp_node
+      && (slp_node && SLP_TREE_LANES (slp_node) > 1)
       && !REDUC_GROUP_FIRST_ELEMENT (stmt_info))
     {
       /* We cannot use in-order reductions in this case because there is

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2024-05-13 14:28 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-03-05 14:47 [gcc(refs/users/rguenth/heads/vect-force-slp)] Allow single-lane SLP in-order reductions Richard Biener
2024-05-13 14:28 Richard Biener

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).