public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/116610] New: wrong-code with SLP induction vectorization when using partial vectors and alignment peeling via masking
@ 2024-09-05  9:13 rguenth at gcc dot gnu.org
  2024-09-05  9:14 ` [Bug tree-optimization/116610] " rguenth at gcc dot gnu.org
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: rguenth at gcc dot gnu.org @ 2024-09-05  9:13 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116610

            Bug ID: 116610
           Summary: wrong-code with SLP induction vectorization when using
                    partial vectors and alignment peeling via masking
           Product: gcc
           Version: 15.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: tree-optimization
          Assignee: unassigned at gcc dot gnu.org
          Reporter: rguenth at gcc dot gnu.org
  Target Milestone: ---

gcc.target/aarch64/sve/peel_ind_1.c when forcing single-lane SLP vectorizes
using VNx4SI and

peel_ind_1.c:16:34: note:  misalignment for fully-masked loop: 1

but the initial value for the induction isn't adjusted:

  # vect_vec_iv_.5_2 = PHI <_11(5), { 5, 10, 15, 20, 25, 30, 35, 40 }(2)>

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

* [Bug tree-optimization/116610] wrong-code with SLP induction vectorization when using partial vectors and alignment peeling via masking
  2024-09-05  9:13 [Bug tree-optimization/116610] New: wrong-code with SLP induction vectorization when using partial vectors and alignment peeling via masking rguenth at gcc dot gnu.org
@ 2024-09-05  9:14 ` rguenth at gcc dot gnu.org
  2024-09-05  9:22 ` rguenth at gcc dot gnu.org
                   ` (4 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: rguenth at gcc dot gnu.org @ 2024-09-05  9:14 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116610

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
     Ever confirmed|0                           |1
             Status|UNCONFIRMED                 |ASSIGNED
           Assignee|unassigned at gcc dot gnu.org      |rguenth at gcc dot gnu.org
   Last reconfirmed|                            |2024-09-05

--- Comment #1 from Richard Biener <rguenth at gcc dot gnu.org> ---
Mine.

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

* [Bug tree-optimization/116610] wrong-code with SLP induction vectorization when using partial vectors and alignment peeling via masking
  2024-09-05  9:13 [Bug tree-optimization/116610] New: wrong-code with SLP induction vectorization when using partial vectors and alignment peeling via masking rguenth at gcc dot gnu.org
  2024-09-05  9:14 ` [Bug tree-optimization/116610] " rguenth at gcc dot gnu.org
@ 2024-09-05  9:22 ` rguenth at gcc dot gnu.org
  2024-09-06  7:16 ` cvs-commit at gcc dot gnu.org
                   ` (3 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: rguenth at gcc dot gnu.org @ 2024-09-05  9:22 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116610

--- Comment #2 from Richard Biener <rguenth at gcc dot gnu.org> ---
The issue is quite old btw.

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

* [Bug tree-optimization/116610] wrong-code with SLP induction vectorization when using partial vectors and alignment peeling via masking
  2024-09-05  9:13 [Bug tree-optimization/116610] New: wrong-code with SLP induction vectorization when using partial vectors and alignment peeling via masking rguenth at gcc dot gnu.org
  2024-09-05  9:14 ` [Bug tree-optimization/116610] " rguenth at gcc dot gnu.org
  2024-09-05  9:22 ` rguenth at gcc dot gnu.org
@ 2024-09-06  7:16 ` cvs-commit at gcc dot gnu.org
  2024-09-06  7:17 ` rguenth at gcc dot gnu.org
                   ` (2 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2024-09-06  7:16 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116610

--- Comment #3 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Richard Biener <rguenth@gcc.gnu.org>:

https://gcc.gnu.org/g:6a1a856ba78589f7f5285b00ecd40ba2bbeef8b0

commit r15-3507-g6a1a856ba78589f7f5285b00ecd40ba2bbeef8b0
Author: Richard Biener <rguenther@suse.de>
Date:   Thu Sep 5 11:18:57 2024 +0200

    tree-optimization/116610 - wrong SLP induction bias for mask peeling

    The following fixes a mistake when applying the bias for peeling via
    masking to the inital value of SLP inductions.

    This resolves gcc.target/aarch64/sve/peel_ind_1.c (a scan-assembler
    only unfortunately) when forcing single-lane SLP for it.

            PR tree-optimization/116610
            * tree-vect-loop.cc (vectorizable_induction): Use MINUS_EXPR
            to apply a mask peeling adjustment.

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

* [Bug tree-optimization/116610] wrong-code with SLP induction vectorization when using partial vectors and alignment peeling via masking
  2024-09-05  9:13 [Bug tree-optimization/116610] New: wrong-code with SLP induction vectorization when using partial vectors and alignment peeling via masking rguenth at gcc dot gnu.org
                   ` (2 preceding siblings ...)
  2024-09-06  7:16 ` cvs-commit at gcc dot gnu.org
@ 2024-09-06  7:17 ` rguenth at gcc dot gnu.org
  2024-09-18  9:31 ` cvs-commit at gcc dot gnu.org
  2024-09-18  9:37 ` rguenth at gcc dot gnu.org
  5 siblings, 0 replies; 7+ messages in thread
From: rguenth at gcc dot gnu.org @ 2024-09-06  7:17 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116610

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
      Known to work|                            |15.0

--- Comment #4 from Richard Biener <rguenth at gcc dot gnu.org> ---
Fixed on trunk sofar, latent on branches - queued for backporting.

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

* [Bug tree-optimization/116610] wrong-code with SLP induction vectorization when using partial vectors and alignment peeling via masking
  2024-09-05  9:13 [Bug tree-optimization/116610] New: wrong-code with SLP induction vectorization when using partial vectors and alignment peeling via masking rguenth at gcc dot gnu.org
                   ` (3 preceding siblings ...)
  2024-09-06  7:17 ` rguenth at gcc dot gnu.org
@ 2024-09-18  9:31 ` cvs-commit at gcc dot gnu.org
  2024-09-18  9:37 ` rguenth at gcc dot gnu.org
  5 siblings, 0 replies; 7+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2024-09-18  9:31 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116610

--- Comment #5 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-14 branch has been updated by Richard Biener
<rguenth@gcc.gnu.org>:

https://gcc.gnu.org/g:cacc976a71027e7da8e3438b60da76ecdf990d38

commit r14-10684-gcacc976a71027e7da8e3438b60da76ecdf990d38
Author: Richard Biener <rguenther@suse.de>
Date:   Thu Sep 5 11:18:57 2024 +0200

    tree-optimization/116610 - wrong SLP induction bias for mask peeling

    The following fixes a mistake when applying the bias for peeling via
    masking to the inital value of SLP inductions.

    This resolves gcc.target/aarch64/sve/peel_ind_1.c (a scan-assembler
    only unfortunately) when forcing single-lane SLP for it.

            PR tree-optimization/116610
            * tree-vect-loop.cc (vectorizable_induction): Use MINUS_EXPR
            to apply a mask peeling adjustment.

    (cherry picked from commit 6a1a856ba78589f7f5285b00ecd40ba2bbeef8b0)

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

* [Bug tree-optimization/116610] wrong-code with SLP induction vectorization when using partial vectors and alignment peeling via masking
  2024-09-05  9:13 [Bug tree-optimization/116610] New: wrong-code with SLP induction vectorization when using partial vectors and alignment peeling via masking rguenth at gcc dot gnu.org
                   ` (4 preceding siblings ...)
  2024-09-18  9:31 ` cvs-commit at gcc dot gnu.org
@ 2024-09-18  9:37 ` rguenth at gcc dot gnu.org
  5 siblings, 0 replies; 7+ messages in thread
From: rguenth at gcc dot gnu.org @ 2024-09-18  9:37 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116610

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
      Known to work|                            |14.2.1
         Resolution|---                         |FIXED
             Status|ASSIGNED                    |RESOLVED

--- Comment #6 from Richard Biener <rguenth at gcc dot gnu.org> ---
Fixed, not backporting further - I think the code is basically unreachable w/o
single-lane SLP.

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

end of thread, other threads:[~2024-09-18  9:37 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-09-05  9:13 [Bug tree-optimization/116610] New: wrong-code with SLP induction vectorization when using partial vectors and alignment peeling via masking rguenth at gcc dot gnu.org
2024-09-05  9:14 ` [Bug tree-optimization/116610] " rguenth at gcc dot gnu.org
2024-09-05  9:22 ` rguenth at gcc dot gnu.org
2024-09-06  7:16 ` cvs-commit at gcc dot gnu.org
2024-09-06  7:17 ` rguenth at gcc dot gnu.org
2024-09-18  9:31 ` cvs-commit at gcc dot gnu.org
2024-09-18  9:37 ` rguenth at gcc dot gnu.org

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).