public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/103864] New: [11/12 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389
@ 2021-12-30  6:12 asolokha at gmx dot com
  2021-12-30  6:29 ` [Bug tree-optimization/103864] " pinskia at gcc dot gnu.org
                   ` (10 more replies)
  0 siblings, 11 replies; 12+ messages in thread
From: asolokha at gmx dot com @ 2021-12-30  6:12 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 103864
           Summary: [11/12 Regression] ICE in vect_transform_reduction, at
                    tree-vect-loop.c:7389
           Product: gcc
           Version: 12.0
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code
          Severity: normal
          Priority: P3
         Component: tree-optimization
          Assignee: unassigned at gcc dot gnu.org
          Reporter: asolokha at gmx dot com
  Target Milestone: ---
            Target: aarch64-linux-gnu

gcc 12.0.0 20211226 (g:d87483015d476a95f521f0c9dcf6988ca889063b) ICEs when
compiling the following testcase, reduced from
gcc/testsuite/gcc.dg/vect/pr103544.c, w/ -O3 -fno-tree-reassoc:

void
crash_me (short int *crash_me_result, int i, char crash_me_ptr_0)
{
  while (i < 1)
    {
      int j;

      for (j = 0; j < 2; ++j)
        crash_me_result[j] += crash_me_ptr_0 + 1;

      i += 3;
    }
}

% aarch64-linux-gnu-gcc-12.0.0 -O3 -fno-tree-reassoc -c iyhuldkz.c
during GIMPLE pass: vect
iyhuldkz.c: In function 'crash_me':
iyhuldkz.c:2:1: internal compiler error: in vect_transform_reduction, at
tree-vect-loop.c:7389
    2 | crash_me (short int *crash_me_result, int i, char crash_me_ptr_0)
      | ^~~~~~~~
0x7b8353 vect_transform_reduction(_loop_vec_info*, _stmt_vec_info*,
gimple_stmt_iterator*, gimple**, _slp_tree*)
       
/var/tmp/portage/cross-aarch64-linux-gnu/gcc-12.0.0_p20211226/work/gcc-12-20211226/gcc/tree-vect-loop.c:7389
0x1bf70c0 vect_transform_stmt(vec_info*, _stmt_vec_info*,
gimple_stmt_iterator*, _slp_tree*, _slp_instance*)
       
/var/tmp/portage/cross-aarch64-linux-gnu/gcc-12.0.0_p20211226/work/gcc-12-20211226/gcc/tree-vect-stmts.c:11255
0x1193427 vect_schedule_slp_node
       
/var/tmp/portage/cross-aarch64-linux-gnu/gcc-12.0.0_p20211226/work/gcc-12-20211226/gcc/tree-vect-slp.c:7270
0x11a53ac vect_schedule_scc
       
/var/tmp/portage/cross-aarch64-linux-gnu/gcc-12.0.0_p20211226/work/gcc-12-20211226/gcc/tree-vect-slp.c:7514
0x11a6417 vect_schedule_slp(vec_info*, vec<_slp_instance*, va_heap, vl_ptr>
const&)
       
/var/tmp/portage/cross-aarch64-linux-gnu/gcc-12.0.0_p20211226/work/gcc-12-20211226/gcc/tree-vect-slp.c:7579
0x117fa10 vect_transform_loop(_loop_vec_info*, gimple*)
       
/var/tmp/portage/cross-aarch64-linux-gnu/gcc-12.0.0_p20211226/work/gcc-12-20211226/gcc/tree-vect-loop.c:9625
0x11b273f vect_transform_loops
       
/var/tmp/portage/cross-aarch64-linux-gnu/gcc-12.0.0_p20211226/work/gcc-12-20211226/gcc/tree-vectorizer.c:1003
0x11b273f try_vectorize_loop_1
       
/var/tmp/portage/cross-aarch64-linux-gnu/gcc-12.0.0_p20211226/work/gcc-12-20211226/gcc/tree-vectorizer.c:1133
0x11b273f try_vectorize_loop
       
/var/tmp/portage/cross-aarch64-linux-gnu/gcc-12.0.0_p20211226/work/gcc-12-20211226/gcc/tree-vectorizer.c:1162
0x11b2f84 execute
       
/var/tmp/portage/cross-aarch64-linux-gnu/gcc-12.0.0_p20211226/work/gcc-12-20211226/gcc/tree-vectorizer.c:1278

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

* [Bug tree-optimization/103864] [11/12 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389
  2021-12-30  6:12 [Bug tree-optimization/103864] New: [11/12 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389 asolokha at gmx dot com
@ 2021-12-30  6:29 ` pinskia at gcc dot gnu.org
  2021-12-30  6:31 ` pinskia at gcc dot gnu.org
                   ` (9 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: pinskia at gcc dot gnu.org @ 2021-12-30  6:29 UTC (permalink / raw)
  To: gcc-bugs

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

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|---                         |11.3

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

* [Bug tree-optimization/103864] [11/12 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389
  2021-12-30  6:12 [Bug tree-optimization/103864] New: [11/12 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389 asolokha at gmx dot com
  2021-12-30  6:29 ` [Bug tree-optimization/103864] " pinskia at gcc dot gnu.org
@ 2021-12-30  6:31 ` pinskia at gcc dot gnu.org
  2021-12-30  8:44 ` [Bug tree-optimization/103864] [11/12 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389 since r10-4675-g05101d1b575a57ca26e4275e971da85a0dd1d52a marxin at gcc dot gnu.org
                   ` (8 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: pinskia at gcc dot gnu.org @ 2021-12-30  6:31 UTC (permalink / raw)
  To: gcc-bugs

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

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
      Known to work|                            |10.3.0
      Known to fail|                            |11.1.0, 11.2.0, 12.0
     Ever confirmed|0                           |1
   Last reconfirmed|                            |2021-12-30
             Status|UNCONFIRMED                 |NEW

--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Confirmed.

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

* [Bug tree-optimization/103864] [11/12 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389 since r10-4675-g05101d1b575a57ca26e4275e971da85a0dd1d52a
  2021-12-30  6:12 [Bug tree-optimization/103864] New: [11/12 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389 asolokha at gmx dot com
  2021-12-30  6:29 ` [Bug tree-optimization/103864] " pinskia at gcc dot gnu.org
  2021-12-30  6:31 ` pinskia at gcc dot gnu.org
@ 2021-12-30  8:44 ` marxin at gcc dot gnu.org
  2021-12-30  8:48 ` pinskia at gcc dot gnu.org
                   ` (7 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: marxin at gcc dot gnu.org @ 2021-12-30  8:44 UTC (permalink / raw)
  To: gcc-bugs

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

Martin Liška <marxin at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|[11/12 Regression] ICE in   |[11/12 Regression] ICE in
                   |vect_transform_reduction,   |vect_transform_reduction,
                   |at tree-vect-loop.c:7389    |at tree-vect-loop.c:7389
                   |                            |since
                   |                            |r10-4675-g05101d1b575a57ca2
                   |                            |6e4275e971da85a0dd1d52a
                 CC|                            |marxin at gcc dot gnu.org,
                   |                            |rsandifo at gcc dot gnu.org

--- Comment #2 from Martin Liška <marxin at gcc dot gnu.org> ---
Started with r10-4675-g05101d1b575a57ca26e4275e971da85a0dd1d52a.

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

* [Bug tree-optimization/103864] [11/12 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389 since r10-4675-g05101d1b575a57ca26e4275e971da85a0dd1d52a
  2021-12-30  6:12 [Bug tree-optimization/103864] New: [11/12 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389 asolokha at gmx dot com
                   ` (2 preceding siblings ...)
  2021-12-30  8:44 ` [Bug tree-optimization/103864] [11/12 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389 since r10-4675-g05101d1b575a57ca26e4275e971da85a0dd1d52a marxin at gcc dot gnu.org
@ 2021-12-30  8:48 ` pinskia at gcc dot gnu.org
  2021-12-30  8:53 ` marxin at gcc dot gnu.org
                   ` (6 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: pinskia at gcc dot gnu.org @ 2021-12-30  8:48 UTC (permalink / raw)
  To: gcc-bugs

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

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
      Known to fail|                            |10.2.0

--- Comment #3 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
(In reply to Martin Liška from comment #2)
> Started with r10-4675-g05101d1b575a57ca26e4275e971da85a0dd1d52a.

This is interesting, GCC 10.3.0 works but GCC 10.2.0 ICEs. Now I wonder fixed
it on the branch. I even tried -fno-vect-cost-model to see if it failed in GCC
10.3.0.

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

* [Bug tree-optimization/103864] [11/12 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389 since r10-4675-g05101d1b575a57ca26e4275e971da85a0dd1d52a
  2021-12-30  6:12 [Bug tree-optimization/103864] New: [11/12 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389 asolokha at gmx dot com
                   ` (3 preceding siblings ...)
  2021-12-30  8:48 ` pinskia at gcc dot gnu.org
@ 2021-12-30  8:53 ` marxin at gcc dot gnu.org
  2021-12-30  9:19 ` marxin at gcc dot gnu.org
                   ` (5 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: marxin at gcc dot gnu.org @ 2021-12-30  8:53 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #4 from Martin Liška <marxin at gcc dot gnu.org> ---
> This is interesting, GCC 10.3.0 works but GCC 10.2.0 ICEs. Now I wonder
> fixed it on the branch. I even tried -fno-vect-cost-model to see if it
> failed in GCC 10.3.0.

Hmm, lemme bisect that as well.

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

* [Bug tree-optimization/103864] [11/12 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389 since r10-4675-g05101d1b575a57ca26e4275e971da85a0dd1d52a
  2021-12-30  6:12 [Bug tree-optimization/103864] New: [11/12 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389 asolokha at gmx dot com
                   ` (4 preceding siblings ...)
  2021-12-30  8:53 ` marxin at gcc dot gnu.org
@ 2021-12-30  9:19 ` marxin at gcc dot gnu.org
  2022-01-03 12:27 ` rguenth at gcc dot gnu.org
                   ` (4 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: marxin at gcc dot gnu.org @ 2021-12-30  9:19 UTC (permalink / raw)
  To: gcc-bugs

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

Martin Liška <marxin at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |rguenth at gcc dot gnu.org

--- Comment #5 from Martin Liška <marxin at gcc dot gnu.org> ---
Changed on gcc 10 branch as g:e563687cf9d3d1278f45aaebd03e0f66531076c9 and
g:66dd83c8840a9a28f6209922b8abd5783a255207 were applied.

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

* [Bug tree-optimization/103864] [11/12 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389 since r10-4675-g05101d1b575a57ca26e4275e971da85a0dd1d52a
  2021-12-30  6:12 [Bug tree-optimization/103864] New: [11/12 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389 asolokha at gmx dot com
                   ` (5 preceding siblings ...)
  2021-12-30  9:19 ` marxin at gcc dot gnu.org
@ 2022-01-03 12:27 ` rguenth at gcc dot gnu.org
  2022-01-04  9:16 ` cvs-commit at gcc dot gnu.org
                   ` (3 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: rguenth at gcc dot gnu.org @ 2022-01-03 12:27 UTC (permalink / raw)
  To: gcc-bugs

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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Assignee|unassigned at gcc dot gnu.org      |rguenth at gcc dot gnu.org
             Status|NEW                         |ASSIGNED

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

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

* [Bug tree-optimization/103864] [11/12 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389 since r10-4675-g05101d1b575a57ca26e4275e971da85a0dd1d52a
  2021-12-30  6:12 [Bug tree-optimization/103864] New: [11/12 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389 asolokha at gmx dot com
                   ` (6 preceding siblings ...)
  2022-01-03 12:27 ` rguenth at gcc dot gnu.org
@ 2022-01-04  9:16 ` cvs-commit at gcc dot gnu.org
  2022-01-04  9:17 ` [Bug tree-optimization/103864] [11 " rguenth at gcc dot gnu.org
                   ` (2 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-01-04  9:16 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #7 from CVS 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:1a15451da14410bf2bd6ec8f5baba1014638c67a

commit r12-6203-g1a15451da14410bf2bd6ec8f5baba1014638c67a
Author: Richard Biener <rguenther@suse.de>
Date:   Tue Jan 4 10:12:47 2022 +0100

    tree-optimization/103864 - SLP reduction of reductions with conversions

    This generalizes the fix for PR103544 to also cover reductions that
    are not reduction chains and does not consider reductions wrapped in
    sign conversions for SLP reduction handling.

    2022-01-04  Richard Biener  <rguenther@suse.de>

            PR tree-optimization/103864
            PR tree-optimization/103544
            * tree-vect-slp.c (vect_analyze_slp_instance): Exclude
            reductions wrapped in conversions from SLP handling.
            (vect_analyze_slp): Revert PR103544 change.

            * gcc.dg/vect/pr103864.c: New testcase.

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

* [Bug tree-optimization/103864] [11 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389 since r10-4675-g05101d1b575a57ca26e4275e971da85a0dd1d52a
  2021-12-30  6:12 [Bug tree-optimization/103864] New: [11/12 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389 asolokha at gmx dot com
                   ` (7 preceding siblings ...)
  2022-01-04  9:16 ` cvs-commit at gcc dot gnu.org
@ 2022-01-04  9:17 ` rguenth at gcc dot gnu.org
  2022-02-17 10:13 ` cvs-commit at gcc dot gnu.org
  2022-02-17 10:15 ` rguenth at gcc dot gnu.org
  10 siblings, 0 replies; 12+ messages in thread
From: rguenth at gcc dot gnu.org @ 2022-01-04  9:17 UTC (permalink / raw)
  To: gcc-bugs

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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Priority|P3                          |P2
            Summary|[11/12 Regression] ICE in   |[11 Regression] ICE in
                   |vect_transform_reduction,   |vect_transform_reduction,
                   |at tree-vect-loop.c:7389    |at tree-vect-loop.c:7389
                   |since                       |since
                   |r10-4675-g05101d1b575a57ca2 |r10-4675-g05101d1b575a57ca2
                   |6e4275e971da85a0dd1d52a     |6e4275e971da85a0dd1d52a
      Known to fail|12.0                        |
      Known to work|                            |12.0

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

* [Bug tree-optimization/103864] [11 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389 since r10-4675-g05101d1b575a57ca26e4275e971da85a0dd1d52a
  2021-12-30  6:12 [Bug tree-optimization/103864] New: [11/12 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389 asolokha at gmx dot com
                   ` (8 preceding siblings ...)
  2022-01-04  9:17 ` [Bug tree-optimization/103864] [11 " rguenth at gcc dot gnu.org
@ 2022-02-17 10:13 ` cvs-commit at gcc dot gnu.org
  2022-02-17 10:15 ` rguenth at gcc dot gnu.org
  10 siblings, 0 replies; 12+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-02-17 10:13 UTC (permalink / raw)
  To: gcc-bugs

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

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

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

commit r11-9585-gc08d4266e48d52b7f8d16c79d3471be40ff56acc
Author: Richard Biener <rguenther@suse.de>
Date:   Tue Jan 4 10:12:47 2022 +0100

    tree-optimization/103864 - SLP reduction of reductions with conversions

    This generalizes the fix for PR103544 to also cover reductions that
    are not reduction chains and does not consider reductions wrapped in
    sign conversions for SLP reduction handling.

    2022-01-04  Richard Biener  <rguenther@suse.de>

            PR tree-optimization/103864
            PR tree-optimization/103544
            * tree-vect-slp.c (vect_analyze_slp_instance): Exclude
            reductions wrapped in conversions from SLP handling.
            (vect_analyze_slp): Revert PR103544 change.

            * gcc.dg/vect/pr103864.c: New testcase.

    (cherry picked from commit 1a15451da14410bf2bd6ec8f5baba1014638c67a)

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

* [Bug tree-optimization/103864] [11 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389 since r10-4675-g05101d1b575a57ca26e4275e971da85a0dd1d52a
  2021-12-30  6:12 [Bug tree-optimization/103864] New: [11/12 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389 asolokha at gmx dot com
                   ` (9 preceding siblings ...)
  2022-02-17 10:13 ` cvs-commit at gcc dot gnu.org
@ 2022-02-17 10:15 ` rguenth at gcc dot gnu.org
  10 siblings, 0 replies; 12+ messages in thread
From: rguenth at gcc dot gnu.org @ 2022-02-17 10:15 UTC (permalink / raw)
  To: gcc-bugs

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

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

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

--- Comment #9 from Richard Biener <rguenth at gcc dot gnu.org> ---
Fixed.

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

end of thread, other threads:[~2022-02-17 10:15 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-12-30  6:12 [Bug tree-optimization/103864] New: [11/12 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389 asolokha at gmx dot com
2021-12-30  6:29 ` [Bug tree-optimization/103864] " pinskia at gcc dot gnu.org
2021-12-30  6:31 ` pinskia at gcc dot gnu.org
2021-12-30  8:44 ` [Bug tree-optimization/103864] [11/12 Regression] ICE in vect_transform_reduction, at tree-vect-loop.c:7389 since r10-4675-g05101d1b575a57ca26e4275e971da85a0dd1d52a marxin at gcc dot gnu.org
2021-12-30  8:48 ` pinskia at gcc dot gnu.org
2021-12-30  8:53 ` marxin at gcc dot gnu.org
2021-12-30  9:19 ` marxin at gcc dot gnu.org
2022-01-03 12:27 ` rguenth at gcc dot gnu.org
2022-01-04  9:16 ` cvs-commit at gcc dot gnu.org
2022-01-04  9:17 ` [Bug tree-optimization/103864] [11 " rguenth at gcc dot gnu.org
2022-02-17 10:13 ` cvs-commit at gcc dot gnu.org
2022-02-17 10:15 ` 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).