public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug target/104637] New: ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx
@ 2022-02-22 12:15 zsojka at seznam dot cz
  2022-02-24 15:17 ` [Bug target/104637] ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx since r9-5221-gd8fcab689435a29d marxin at gcc dot gnu.org
                   ` (18 more replies)
  0 siblings, 19 replies; 20+ messages in thread
From: zsojka at seznam dot cz @ 2022-02-22 12:15 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 104637
           Summary: ICE: maximum number of LRA assignment passes is
                    achieved (30) with -Og -fno-forward-propagate -mavx
           Product: gcc
           Version: 12.0
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code
          Severity: normal
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot gnu.org
          Reporter: zsojka at seznam dot cz
  Target Milestone: ---
              Host: x86_64-pc-linux-gnu
            Target: x86_64-pc-linux-gnu

Created attachment 52489
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=52489&action=edit
reduced testcase

Compiler output:
$ x86_64-pc-linux-gnu-gcc -Og -fno-forward-propagate -mavx testcase.c
testcase.c: In function 'foo':
testcase.c:12:5: warning: division by zero [-Wdiv-by-zero]
   12 |   u /= 0;
      |     ^~
during RTL pass: reload
testcase.c:16:1: internal compiler error: maximum number of LRA assignment
passes is achieved (30)
   16 | }
      | ^
0x11b4d4c lra_assign(bool&)
        /repo/gcc-trunk/gcc/lra-assigns.cc:1694
0x11af12f lra(_IO_FILE*)
        /repo/gcc-trunk/gcc/lra.cc:2395
0x115fbc9 do_reload
        /repo/gcc-trunk/gcc/ira.cc:5940
0x115fbc9 execute
        /repo/gcc-trunk/gcc/ira.cc:6126
Please submit a full bug report, with preprocessed source (by using
-freport-bug).
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.

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

* [Bug target/104637] ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx since r9-5221-gd8fcab689435a29d
  2022-02-22 12:15 [Bug target/104637] New: ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx zsojka at seznam dot cz
@ 2022-02-24 15:17 ` marxin at gcc dot gnu.org
  2022-02-25 13:14 ` [Bug target/104637] [9/10/11/12 Regression] " jakub at gcc dot gnu.org
                   ` (17 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: marxin at gcc dot gnu.org @ 2022-02-24 15:17 UTC (permalink / raw)
  To: gcc-bugs

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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Last reconfirmed|                            |2022-02-24
                 CC|                            |jakub at gcc dot gnu.org,
                   |                            |marxin at gcc dot gnu.org
            Summary|ICE: maximum number of LRA  |ICE: maximum number of LRA
                   |assignment passes is        |assignment passes is
                   |achieved (30) with -Og      |achieved (30) with -Og
                   |-fno-forward-propagate      |-fno-forward-propagate
                   |-mavx                       |-mavx since
                   |                            |r9-5221-gd8fcab689435a29d
             Status|UNCONFIRMED                 |NEW
     Ever confirmed|0                           |1

--- Comment #1 from Martin Liška <marxin at gcc dot gnu.org> ---
Started with r9-5221-gd8fcab689435a29d.

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

* [Bug target/104637] [9/10/11/12 Regression] ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx since r9-5221-gd8fcab689435a29d
  2022-02-22 12:15 [Bug target/104637] New: ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx zsojka at seznam dot cz
  2022-02-24 15:17 ` [Bug target/104637] ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx since r9-5221-gd8fcab689435a29d marxin at gcc dot gnu.org
@ 2022-02-25 13:14 ` jakub at gcc dot gnu.org
  2022-02-25 13:25 ` jakub at gcc dot gnu.org
                   ` (16 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: jakub at gcc dot gnu.org @ 2022-02-25 13:14 UTC (permalink / raw)
  To: gcc-bugs

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

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|---                         |9.5
                 CC|                            |vmakarov at gcc dot gnu.org
           Priority|P3                          |P2
            Summary|ICE: maximum number of LRA  |[9/10/11/12 Regression]
                   |assignment passes is        |ICE: maximum number of LRA
                   |achieved (30) with -Og      |assignment passes is
                   |-fno-forward-propagate      |achieved (30) with -Og
                   |-mavx since                 |-fno-forward-propagate
                   |r9-5221-gd8fcab689435a29d   |-mavx since
                   |                            |r9-5221-gd8fcab689435a29d

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

* [Bug target/104637] [9/10/11/12 Regression] ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx since r9-5221-gd8fcab689435a29d
  2022-02-22 12:15 [Bug target/104637] New: ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx zsojka at seznam dot cz
  2022-02-24 15:17 ` [Bug target/104637] ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx since r9-5221-gd8fcab689435a29d marxin at gcc dot gnu.org
  2022-02-25 13:14 ` [Bug target/104637] [9/10/11/12 Regression] " jakub at gcc dot gnu.org
@ 2022-02-25 13:25 ` jakub at gcc dot gnu.org
  2022-02-25 16:57 ` vmakarov at gcc dot gnu.org
                   ` (15 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: jakub at gcc dot gnu.org @ 2022-02-25 13:25 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
If I change the testcase to following (so that it doesn't rely on
__builtin_convertvector), it started ICEing with
r0-122162-gb7aa4e9afcd3da4f09d6f982a663ea2094b1f2cf
typedef short __attribute__((__vector_size__ (64))) U;
typedef unsigned long long __attribute__((__vector_size__ (32))) V;
typedef long double __attribute__((__vector_size__ (64))) F;

int i;
U u;
F f;

void
foo (char a, char b, _Complex char c, V v)
{
  u = (U) { u[0] / 0, u[1] / 0, u[2] / 0, u[3] / 0, u[4] / 0, u[5] / 0, u[6] /
0, u[7] / 0,
            u[8] / 0, u[0] / 0, u[9] / 0, u[10] / 0, u[11] / 0, u[12] / 0,
u[13] / 0, u[14] / 0, u[15] / 0,
            u[16] / 0, u[17] / 0, u[18] / 0, u[19] / 0, u[20] / 0, u[21] / 0,
u[22] / 0, u[23] / 0,
            u[24] / 0, u[25] / 0, u[26] / 0, u[27] / 0, u[28] / 0, u[29] / 0,
u[30] / 0, u[31] / 0 };
  c += i;
  f = (F) { v[0], v[1], v[2], v[3] };
  i = (char) (__imag__ c + i);
}

In any case, I don't see anything wrong on the GIMPLE side and it isn't clear
on reloading which insn it is ICEing.

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

* [Bug target/104637] [9/10/11/12 Regression] ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx since r9-5221-gd8fcab689435a29d
  2022-02-22 12:15 [Bug target/104637] New: ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx zsojka at seznam dot cz
                   ` (2 preceding siblings ...)
  2022-02-25 13:25 ` jakub at gcc dot gnu.org
@ 2022-02-25 16:57 ` vmakarov at gcc dot gnu.org
  2022-02-28 21:45 ` cvs-commit at gcc dot gnu.org
                   ` (14 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: vmakarov at gcc dot gnu.org @ 2022-02-25 16:57 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #3 from Vladimir Makarov <vmakarov at gcc dot gnu.org> ---
(In reply to Jakub Jelinek from comment #2)
> If I change the testcase to following (so that it doesn't rely on
> __builtin_convertvector), it started ICEing with
> r0-122162-gb7aa4e9afcd3da4f09d6f982a663ea2094b1f2cf
> typedef short __attribute__((__vector_size__ (64))) U;
> typedef unsigned long long __attribute__((__vector_size__ (32))) V;
> typedef long double __attribute__((__vector_size__ (64))) F;
> 
> int i;
> U u;
> F f;
> 
> void
> foo (char a, char b, _Complex char c, V v)
> {
>   u = (U) { u[0] / 0, u[1] / 0, u[2] / 0, u[3] / 0, u[4] / 0, u[5] / 0, u[6]
> / 0, u[7] / 0,
> 	    u[8] / 0, u[0] / 0, u[9] / 0, u[10] / 0, u[11] / 0, u[12] / 0, u[13] /
> 0, u[14] / 0, u[15] / 0,
> 	    u[16] / 0, u[17] / 0, u[18] / 0, u[19] / 0, u[20] / 0, u[21] / 0, u[22]
> / 0, u[23] / 0,
> 	    u[24] / 0, u[25] / 0, u[26] / 0, u[27] / 0, u[28] / 0, u[29] / 0, u[30]
> / 0, u[31] / 0 };
>   c += i;
>   f = (F) { v[0], v[1], v[2], v[3] };
>   i = (char) (__imag__ c + i);
> }
> 
> In any case, I don't see anything wrong on the GIMPLE side and it isn't
> clear on reloading which insn it is ICEing.

It is a pitfall of LRA hard reg split subpass.  It is a small subpass used as
the last resort for LRA when it can not assign a hard reg to a reload pseudo by
other ways (e.g. by spilling non-reload pseudos).  For simplicity the subpass
works on one split base (as each split changes pseudo live range info).  To
solve the problem the subpass should make as many splits as possible.  This
requires to check overlapping hard reg splits.

In other words, the subpass should be considerably modified.  I hope to commit
the patch on the next week.

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

* [Bug target/104637] [9/10/11/12 Regression] ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx since r9-5221-gd8fcab689435a29d
  2022-02-22 12:15 [Bug target/104637] New: ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx zsojka at seznam dot cz
                   ` (3 preceding siblings ...)
  2022-02-25 16:57 ` vmakarov at gcc dot gnu.org
@ 2022-02-28 21:45 ` cvs-commit at gcc dot gnu.org
  2022-03-02 10:08 ` [Bug rtl-optimization/104637] " cvs-commit at gcc dot gnu.org
                   ` (13 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-02-28 21:45 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #4 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Vladimir Makarov <vmakarov@gcc.gnu.org>:

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

commit r12-7415-gec1b9ba2d7913fe5e9deacc8e55e7539262f5124
Author: Vladimir N. Makarov <vmakarov@redhat.com>
Date:   Mon Feb 28 16:43:50 2022 -0500

    [PR104637] LRA: Split hard regs as many as possible on one subpass

    LRA hard reg split subpass is a small subpass used as the last
    resort for LRA when it can not assign a hard reg to a reload
    pseudo by other ways (e.g. by spilling non-reload pseudos).  For
    simplicity the subpass works on one split base (as each split
    changes pseudo live range info).  In this case it results in
    reaching maximal possible number of subpasses.  The patch
    implements as many non-overlapping hard reg splits
    splits as possible on each subpass.

    gcc/ChangeLog:

            PR rtl-optimization/104637
            * lra-assigns.cc (lra_split_hard_reg_for): Split hard regs as many
            as possible on one subpass.

    gcc/testsuite/ChangeLog:

            PR rtl-optimization/104637
            * gcc.target/i386/pr104637.c: New.

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

* [Bug rtl-optimization/104637] [9/10/11/12 Regression] ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx since r9-5221-gd8fcab689435a29d
  2022-02-22 12:15 [Bug target/104637] New: ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx zsojka at seznam dot cz
                   ` (4 preceding siblings ...)
  2022-02-28 21:45 ` cvs-commit at gcc dot gnu.org
@ 2022-03-02 10:08 ` cvs-commit at gcc dot gnu.org
  2022-03-02 14:00 ` vmakarov at gcc dot gnu.org
                   ` (12 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-03-02 10:08 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #5 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Jakub Jelinek <jakub@gcc.gnu.org>:

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

commit r12-7449-gd7b4c8feee11ea04b83f9996654c96b130588570
Author: Jakub Jelinek <jakub@redhat.com>
Date:   Wed Mar 2 11:04:35 2022 +0100

    testsuite: Fix up pr104637 testcase [PR104637]

    This testcase FAILs everywhere for 3 reasons:
    1) the testcase can't work on ia32, where sizeof (long double) == 12
       and as it is not a power of 2, we disallow creating vectors with such
       elements, -mx32 and -m64 are fine
    2) the testcase emits a lot of -Wdiv-by-zero warnings, I've just added
       -Wno-div-by-zero to dg-options
    3) my fault, when tweaking the testcase I've missed 33 initializers of
       a 32 element vector which didn't change anything on the ICE, but is
       still reported

    This patch fixes all of it, tested with
    RUNTESTFLAGS='--target_board=unix\{-m32,-m64\} i386.exp=pr104637.c'
    both without the LRA fix where it ICEs and with it where it passes
    everywhere.

    2022-03-02  Jakub Jelinek  <jakub@redhat.com>

            PR rtl-optimization/104637
            * gcc.target/i386/pr104637.c: Don't run on ia32.  Add
-Wno-div-by-zero
            to dg-options.
            (foo): Remove extraneous initializer.

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

* [Bug rtl-optimization/104637] [9/10/11/12 Regression] ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx since r9-5221-gd8fcab689435a29d
  2022-02-22 12:15 [Bug target/104637] New: ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx zsojka at seznam dot cz
                   ` (5 preceding siblings ...)
  2022-03-02 10:08 ` [Bug rtl-optimization/104637] " cvs-commit at gcc dot gnu.org
@ 2022-03-02 14:00 ` vmakarov at gcc dot gnu.org
  2022-03-15  8:29 ` [Bug rtl-optimization/104637] [9/10/11 " jakub at gcc dot gnu.org
                   ` (11 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: vmakarov at gcc dot gnu.org @ 2022-03-02 14:00 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #6 from Vladimir Makarov <vmakarov at gcc dot gnu.org> ---
(In reply to CVS Commits from comment #5)
> The master branch has been updated by Jakub Jelinek <jakub@gcc.gnu.org>:
> 
> https://gcc.gnu.org/g:d7b4c8feee11ea04b83f9996654c96b130588570
> 
> commit r12-7449-gd7b4c8feee11ea04b83f9996654c96b130588570
> Author: Jakub Jelinek <jakub@redhat.com>
> Date:   Wed Mar 2 11:04:35 2022 +0100
> 
>     testsuite: Fix up pr104637 testcase [PR104637]
>     
>     This testcase FAILs everywhere for 3 reasons:
>     1) the testcase can't work on ia32, where sizeof (long double) == 12
>        and as it is not a power of 2, we disallow creating vectors with such
>        elements, -mx32 and -m64 are fine
>     2) the testcase emits a lot of -Wdiv-by-zero warnings, I've just added
>        -Wno-div-by-zero to dg-options
>     3) my fault, when tweaking the testcase I've missed 33 initializers of
>        a 32 element vector which didn't change anything on the ICE, but is
>        still reported
>     
>     This patch fixes all of it, tested with
>     RUNTESTFLAGS='--target_board=unix\{-m32,-m64\} i386.exp=pr104637.c'
>     both without the LRA fix where it ICEs and with it where it passes
>     everywhere.
>     
>     2022-03-02  Jakub Jelinek  <jakub@redhat.com>
>     
>             PR rtl-optimization/104637
>             * gcc.target/i386/pr104637.c: Don't run on ia32.  Add
> -Wno-div-by-zero
>             to dg-options.
>             (foo): Remove extraneous initializer.

Sorry, I should have been more careful with using the original test.

And thank you for fixing this, Jakub.

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

* [Bug rtl-optimization/104637] [9/10/11 Regression] ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx since r9-5221-gd8fcab689435a29d
  2022-02-22 12:15 [Bug target/104637] New: ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx zsojka at seznam dot cz
                   ` (6 preceding siblings ...)
  2022-03-02 14:00 ` vmakarov at gcc dot gnu.org
@ 2022-03-15  8:29 ` jakub at gcc dot gnu.org
  2022-05-27  9:47 ` [Bug rtl-optimization/104637] [10/11 " rguenth at gcc dot gnu.org
                   ` (10 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: jakub at gcc dot gnu.org @ 2022-03-15  8:29 UTC (permalink / raw)
  To: gcc-bugs

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

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|[9/10/11/12 Regression]     |[9/10/11 Regression] ICE:
                   |ICE: maximum number of LRA  |maximum number of LRA
                   |assignment passes is        |assignment passes is
                   |achieved (30) with -Og      |achieved (30) with -Og
                   |-fno-forward-propagate      |-fno-forward-propagate
                   |-mavx since                 |-mavx since
                   |r9-5221-gd8fcab689435a29d   |r9-5221-gd8fcab689435a29d

--- Comment #7 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Fixed on the trunk.

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

* [Bug rtl-optimization/104637] [10/11 Regression] ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx since r9-5221-gd8fcab689435a29d
  2022-02-22 12:15 [Bug target/104637] New: ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx zsojka at seznam dot cz
                   ` (7 preceding siblings ...)
  2022-03-15  8:29 ` [Bug rtl-optimization/104637] [9/10/11 " jakub at gcc dot gnu.org
@ 2022-05-27  9:47 ` rguenth at gcc dot gnu.org
  2022-06-07  2:20 ` sam at gentoo dot org
                   ` (9 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: rguenth at gcc dot gnu.org @ 2022-05-27  9:47 UTC (permalink / raw)
  To: gcc-bugs

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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|9.5                         |10.4

--- Comment #8 from Richard Biener <rguenth at gcc dot gnu.org> ---
GCC 9 branch is being closed

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

* [Bug rtl-optimization/104637] [10/11 Regression] ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx since r9-5221-gd8fcab689435a29d
  2022-02-22 12:15 [Bug target/104637] New: ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx zsojka at seznam dot cz
                   ` (8 preceding siblings ...)
  2022-05-27  9:47 ` [Bug rtl-optimization/104637] [10/11 " rguenth at gcc dot gnu.org
@ 2022-06-07  2:20 ` sam at gentoo dot org
  2022-06-14 15:48 ` cvs-commit at gcc dot gnu.org
                   ` (8 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: sam at gentoo dot org @ 2022-06-07  2:20 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #9 from Sam James <sam at gentoo dot org> ---
Could this be backported to 10 + 11 please?

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

* [Bug rtl-optimization/104637] [10/11 Regression] ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx since r9-5221-gd8fcab689435a29d
  2022-02-22 12:15 [Bug target/104637] New: ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx zsojka at seznam dot cz
                   ` (9 preceding siblings ...)
  2022-06-07  2:20 ` sam at gentoo dot org
@ 2022-06-14 15:48 ` cvs-commit at gcc dot gnu.org
  2022-06-14 15:48 ` cvs-commit at gcc dot gnu.org
                   ` (7 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-06-14 15:48 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #10 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-11 branch has been updated by Vladimir Makarov
<vmakarov@gcc.gnu.org>:

https://gcc.gnu.org/g:776283dd1946f1563a59d8f527697e0206f5390e

commit r11-10064-g776283dd1946f1563a59d8f527697e0206f5390e
Author: Vladimir N. Makarov <vmakarov@redhat.com>
Date:   Mon Feb 28 16:43:50 2022 -0500

    [PR104637] LRA: Split hard regs as many as possible on one subpass

    LRA hard reg split subpass is a small subpass used as the last
    resort for LRA when it can not assign a hard reg to a reload
    pseudo by other ways (e.g. by spilling non-reload pseudos).  For
    simplicity the subpass works on one split base (as each split
    changes pseudo live range info).  In this case it results in
    reaching maximal possible number of subpasses.  The patch
    implements as many non-overlapping hard reg splits
    splits as possible on each subpass.

    gcc/ChangeLog:

            PR rtl-optimization/104637
            * lra-assigns.c (lra_split_hard_reg_for): Split hard regs as many
            as possible on one subpass.

    gcc/testsuite/ChangeLog:

            PR rtl-optimization/104637
            * gcc.target/i386/pr104637.c: New.

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

* [Bug rtl-optimization/104637] [10/11 Regression] ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx since r9-5221-gd8fcab689435a29d
  2022-02-22 12:15 [Bug target/104637] New: ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx zsojka at seznam dot cz
                   ` (10 preceding siblings ...)
  2022-06-14 15:48 ` cvs-commit at gcc dot gnu.org
@ 2022-06-14 15:48 ` cvs-commit at gcc dot gnu.org
  2022-06-14 15:50 ` cvs-commit at gcc dot gnu.org
                   ` (6 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-06-14 15:48 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #11 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-11 branch has been updated by Vladimir Makarov
<vmakarov@gcc.gnu.org>:

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

commit r11-10065-g0b518d844a49b2ee48d07e17cce855a4eec59490
Author: Jakub Jelinek <jakub@redhat.com>
Date:   Wed Mar 2 11:04:35 2022 +0100

    testsuite: Fix up pr104637 testcase [PR104637]

    This testcase FAILs everywhere for 3 reasons:
    1) the testcase can't work on ia32, where sizeof (long double) == 12
       and as it is not a power of 2, we disallow creating vectors with such
       elements, -mx32 and -m64 are fine
    2) the testcase emits a lot of -Wdiv-by-zero warnings, I've just added
       -Wno-div-by-zero to dg-options
    3) my fault, when tweaking the testcase I've missed 33 initializers of
       a 32 element vector which didn't change anything on the ICE, but is
       still reported

    This patch fixes all of it, tested with
    RUNTESTFLAGS='--target_board=unix\{-m32,-m64\} i386.exp=pr104637.c'
    both without the LRA fix where it ICEs and with it where it passes
    everywhere.

    2022-03-02  Jakub Jelinek  <jakub@redhat.com>

            PR rtl-optimization/104637
            * gcc.target/i386/pr104637.c: Don't run on ia32.  Add
-Wno-div-by-zero
            to dg-options.
            (foo): Remove extraneous initializer.

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

* [Bug rtl-optimization/104637] [10/11 Regression] ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx since r9-5221-gd8fcab689435a29d
  2022-02-22 12:15 [Bug target/104637] New: ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx zsojka at seznam dot cz
                   ` (11 preceding siblings ...)
  2022-06-14 15:48 ` cvs-commit at gcc dot gnu.org
@ 2022-06-14 15:50 ` cvs-commit at gcc dot gnu.org
  2022-06-14 15:50 ` cvs-commit at gcc dot gnu.org
                   ` (5 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-06-14 15:50 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #12 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-10 branch has been updated by Vladimir Makarov
<vmakarov@gcc.gnu.org>:

https://gcc.gnu.org/g:688703569091edfd0400523d85cbb44d15aa61ea

commit r10-10830-g688703569091edfd0400523d85cbb44d15aa61ea
Author: Vladimir N. Makarov <vmakarov@redhat.com>
Date:   Mon Feb 28 16:43:50 2022 -0500

    [PR104637] LRA: Split hard regs as many as possible on one subpass

    LRA hard reg split subpass is a small subpass used as the last
    resort for LRA when it can not assign a hard reg to a reload
    pseudo by other ways (e.g. by spilling non-reload pseudos).  For
    simplicity the subpass works on one split base (as each split
    changes pseudo live range info).  In this case it results in
    reaching maximal possible number of subpasses.  The patch
    implements as many non-overlapping hard reg splits
    splits as possible on each subpass.

    gcc/ChangeLog:

            PR rtl-optimization/104637
            * lra-assigns.c (lra_split_hard_reg_for): Split hard regs as many
            as possible on one subpass.

    gcc/testsuite/ChangeLog:

            PR rtl-optimization/104637
            * gcc.target/i386/pr104637.c: New.

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

* [Bug rtl-optimization/104637] [10/11 Regression] ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx since r9-5221-gd8fcab689435a29d
  2022-02-22 12:15 [Bug target/104637] New: ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx zsojka at seznam dot cz
                   ` (12 preceding siblings ...)
  2022-06-14 15:50 ` cvs-commit at gcc dot gnu.org
@ 2022-06-14 15:50 ` cvs-commit at gcc dot gnu.org
  2022-06-14 15:53 ` vmakarov at gcc dot gnu.org
                   ` (4 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-06-14 15:50 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #13 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-10 branch has been updated by Vladimir Makarov
<vmakarov@gcc.gnu.org>:

https://gcc.gnu.org/g:4c6e66a4dba5bbbcf343c1f6a58f355e270e79b9

commit r10-10831-g4c6e66a4dba5bbbcf343c1f6a58f355e270e79b9
Author: Jakub Jelinek <jakub@redhat.com>
Date:   Wed Mar 2 11:04:35 2022 +0100

    testsuite: Fix up pr104637 testcase [PR104637]

    This testcase FAILs everywhere for 3 reasons:
    1) the testcase can't work on ia32, where sizeof (long double) == 12
       and as it is not a power of 2, we disallow creating vectors with such
       elements, -mx32 and -m64 are fine
    2) the testcase emits a lot of -Wdiv-by-zero warnings, I've just added
       -Wno-div-by-zero to dg-options
    3) my fault, when tweaking the testcase I've missed 33 initializers of
       a 32 element vector which didn't change anything on the ICE, but is
       still reported

    This patch fixes all of it, tested with
    RUNTESTFLAGS='--target_board=unix\{-m32,-m64\} i386.exp=pr104637.c'
    both without the LRA fix where it ICEs and with it where it passes
    everywhere.

    2022-03-02  Jakub Jelinek  <jakub@redhat.com>

            PR rtl-optimization/104637
            * gcc.target/i386/pr104637.c: Don't run on ia32.  Add
-Wno-div-by-zero
            to dg-options.
            (foo): Remove extraneous initializer.

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

* [Bug rtl-optimization/104637] [10/11 Regression] ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx since r9-5221-gd8fcab689435a29d
  2022-02-22 12:15 [Bug target/104637] New: ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx zsojka at seznam dot cz
                   ` (13 preceding siblings ...)
  2022-06-14 15:50 ` cvs-commit at gcc dot gnu.org
@ 2022-06-14 15:53 ` vmakarov at gcc dot gnu.org
  2022-06-28 10:48 ` jakub at gcc dot gnu.org
                   ` (3 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: vmakarov at gcc dot gnu.org @ 2022-06-14 15:53 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #14 from Vladimir Makarov <vmakarov at gcc dot gnu.org> ---
I've just ported the two patches to gcc-10 and gcc-11 release branches.

gcc-10 required additional work besides just cherry-picking.

The patches were successfully bootstrapped and tested on x86-64.

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

* [Bug rtl-optimization/104637] [10/11 Regression] ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx since r9-5221-gd8fcab689435a29d
  2022-02-22 12:15 [Bug target/104637] New: ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx zsojka at seznam dot cz
                   ` (14 preceding siblings ...)
  2022-06-14 15:53 ` vmakarov at gcc dot gnu.org
@ 2022-06-28 10:48 ` jakub at gcc dot gnu.org
  2022-06-29 18:02 ` herrtimson at yahoo dot de
                   ` (2 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: jakub at gcc dot gnu.org @ 2022-06-28 10:48 UTC (permalink / raw)
  To: gcc-bugs

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

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|10.4                        |10.5

--- Comment #15 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
GCC 10.4 is being released, retargeting bugs to GCC 10.5.

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

* [Bug rtl-optimization/104637] [10/11 Regression] ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx since r9-5221-gd8fcab689435a29d
  2022-02-22 12:15 [Bug target/104637] New: ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx zsojka at seznam dot cz
                   ` (15 preceding siblings ...)
  2022-06-28 10:48 ` jakub at gcc dot gnu.org
@ 2022-06-29 18:02 ` herrtimson at yahoo dot de
  2022-06-29 19:01 ` ubizjak at gmail dot com
  2022-06-29 19:37 ` jakub at gcc dot gnu.org
  18 siblings, 0 replies; 20+ messages in thread
From: herrtimson at yahoo dot de @ 2022-06-29 18:02 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #16 from tt_1 <herrtimson at yahoo dot de> ---
May I kindly ask why this was retargeted to gcc-10.5.0? It seems to me that all
the patches were merged into gcc-10.4.0, is there more to come?

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

* [Bug rtl-optimization/104637] [10/11 Regression] ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx since r9-5221-gd8fcab689435a29d
  2022-02-22 12:15 [Bug target/104637] New: ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx zsojka at seznam dot cz
                   ` (16 preceding siblings ...)
  2022-06-29 18:02 ` herrtimson at yahoo dot de
@ 2022-06-29 19:01 ` ubizjak at gmail dot com
  2022-06-29 19:37 ` jakub at gcc dot gnu.org
  18 siblings, 0 replies; 20+ messages in thread
From: ubizjak at gmail dot com @ 2022-06-29 19:01 UTC (permalink / raw)
  To: gcc-bugs

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

Uroš Bizjak <ubizjak at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED

--- Comment #17 from Uroš Bizjak <ubizjak at gmail dot com> ---
(In reply to tt_1 from comment #16)
> May I kindly ask why this was retargeted to gcc-10.5.0? It seems to me that
> all the patches were merged into gcc-10.4.0, is there more to come?

No, just the PR was not closed in time.

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

* [Bug rtl-optimization/104637] [10/11 Regression] ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx since r9-5221-gd8fcab689435a29d
  2022-02-22 12:15 [Bug target/104637] New: ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx zsojka at seznam dot cz
                   ` (17 preceding siblings ...)
  2022-06-29 19:01 ` ubizjak at gmail dot com
@ 2022-06-29 19:37 ` jakub at gcc dot gnu.org
  18 siblings, 0 replies; 20+ messages in thread
From: jakub at gcc dot gnu.org @ 2022-06-29 19:37 UTC (permalink / raw)
  To: gcc-bugs

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

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|10.5                        |10.4

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

end of thread, other threads:[~2022-06-29 19:37 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-02-22 12:15 [Bug target/104637] New: ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx zsojka at seznam dot cz
2022-02-24 15:17 ` [Bug target/104637] ICE: maximum number of LRA assignment passes is achieved (30) with -Og -fno-forward-propagate -mavx since r9-5221-gd8fcab689435a29d marxin at gcc dot gnu.org
2022-02-25 13:14 ` [Bug target/104637] [9/10/11/12 Regression] " jakub at gcc dot gnu.org
2022-02-25 13:25 ` jakub at gcc dot gnu.org
2022-02-25 16:57 ` vmakarov at gcc dot gnu.org
2022-02-28 21:45 ` cvs-commit at gcc dot gnu.org
2022-03-02 10:08 ` [Bug rtl-optimization/104637] " cvs-commit at gcc dot gnu.org
2022-03-02 14:00 ` vmakarov at gcc dot gnu.org
2022-03-15  8:29 ` [Bug rtl-optimization/104637] [9/10/11 " jakub at gcc dot gnu.org
2022-05-27  9:47 ` [Bug rtl-optimization/104637] [10/11 " rguenth at gcc dot gnu.org
2022-06-07  2:20 ` sam at gentoo dot org
2022-06-14 15:48 ` cvs-commit at gcc dot gnu.org
2022-06-14 15:48 ` cvs-commit at gcc dot gnu.org
2022-06-14 15:50 ` cvs-commit at gcc dot gnu.org
2022-06-14 15:50 ` cvs-commit at gcc dot gnu.org
2022-06-14 15:53 ` vmakarov at gcc dot gnu.org
2022-06-28 10:48 ` jakub at gcc dot gnu.org
2022-06-29 18:02 ` herrtimson at yahoo dot de
2022-06-29 19:01 ` ubizjak at gmail dot com
2022-06-29 19:37 ` jakub 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).