public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug target/105257] New: [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811
@ 2022-04-13  8:23 ro at gcc dot gnu.org
  2022-04-13  8:23 ` [Bug target/105257] " ro at gcc dot gnu.org
                   ` (17 more replies)
  0 siblings, 18 replies; 19+ messages in thread
From: ro at gcc dot gnu.org @ 2022-04-13  8:23 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 105257
           Summary: [8/9/10/11/12 regression] ICE in final_scan_insn_1, at
                    final.cc:2811
           Product: gcc
           Version: 12.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot gnu.org
          Reporter: ro at gcc dot gnu.org
                CC: ebotcazou at gcc dot gnu.org
  Target Milestone: ---
            Target: sparcv9-sun-solaris2.11

The following testcase (reduced from OpenSolaris $SRC/cmd/tip/acu.c) ICEs since
GCC 8:
$ cat acu.i
(*a)();
*b() {
  sigsetjmp();
  a();
  return "";
}
$ cc1 acu.i -mptr64 -mstack-bias -mno-v8plus -quiet -m64 -mcpu=v9 -O2 -w -fpic
acu.i: In function ‘b’:
acu.i:6:1: error: insn does not satisfy its constraints:
    6 | }
      | ^
(insn 20 34 35 (set (reg:DI 8 %o0)
        (mem/u/c:DI (plus:DI (reg:DI 8 %o0)
                (symbol_ref/f:DI ("*.LLC0") [flags 0x2] <var_decl fa827340
*.LLC0>)) [0  S8 A64])) 125 {*movdi_insn_sp64}
     (expr_list:REG_EQUAL (symbol_ref/f:DI ("*.LLC0") [flags 0x2] <var_decl
fa827340 *.LLC0>)
        (nil)))
during RTL pass: final
acu.i:6:1: internal compiler error: in final_scan_insn_1, at final.cc:2811
0xd828df _fatal_insn(char const*, rtx_def const*, char const*, int, char
const*)
        /vol/gcc/src/hg/master/local/gcc/rtl-error.cc:108
0xd8291b _fatal_insn_not_found(rtx_def const*, char const*, int, char const*)
        /vol/gcc/src/hg/master/local/gcc/rtl-error.cc:118
0x98acfb final_scan_insn_1
        /vol/gcc/src/hg/master/local/gcc/final.cc:2811
0x98aecb final_scan_insn(rtx_insn*, __FILE*, int, int, int*)
        /vol/gcc/src/hg/master/local/gcc/final.cc:2940
0x98a463 final_scan_insn_1
        /vol/gcc/src/hg/master/local/gcc/final.cc:2733
0x98aecb final_scan_insn(rtx_insn*, __FILE*, int, int, int*)
        /vol/gcc/src/hg/master/local/gcc/final.cc:2940
0x98b17f final_1
        /vol/gcc/src/hg/master/local/gcc/final.cc:1997
0x98c123 rest_of_handle_final
        /vol/gcc/src/hg/master/local/gcc/final.cc:4285
0x98c123 execute
        /vol/gcc/src/hg/master/local/gcc/final.cc:4363

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

* [Bug target/105257] [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811
  2022-04-13  8:23 [Bug target/105257] New: [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811 ro at gcc dot gnu.org
@ 2022-04-13  8:23 ` ro at gcc dot gnu.org
  2022-04-19  9:08 ` jakub at gcc dot gnu.org
                   ` (16 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: ro at gcc dot gnu.org @ 2022-04-13  8:23 UTC (permalink / raw)
  To: gcc-bugs

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

Rainer Orth <ro at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|---                         |12.0

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

* [Bug target/105257] [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811
  2022-04-13  8:23 [Bug target/105257] New: [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811 ro at gcc dot gnu.org
  2022-04-13  8:23 ` [Bug target/105257] " ro at gcc dot gnu.org
@ 2022-04-19  9:08 ` jakub at gcc dot gnu.org
  2022-04-19  9:18 ` jakub at gcc dot gnu.org
                   ` (15 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: jakub at gcc dot gnu.org @ 2022-04-19  9:08 UTC (permalink / raw)
  To: gcc-bugs

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

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

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

--- Comment #1 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Slightly cleaned up:
extern int sigsetjmp (void **);
void *buf[5];
void (*fn) (void);

const char *
bar (void)
{
  sigsetjmp (buf);
  fn ();
  return "";
}

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

* [Bug target/105257] [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811
  2022-04-13  8:23 [Bug target/105257] New: [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811 ro at gcc dot gnu.org
  2022-04-13  8:23 ` [Bug target/105257] " ro at gcc dot gnu.org
  2022-04-19  9:08 ` jakub at gcc dot gnu.org
@ 2022-04-19  9:18 ` jakub at gcc dot gnu.org
  2022-04-19 10:14 ` ebotcazou at gcc dot gnu.org
                   ` (14 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: jakub at gcc dot gnu.org @ 2022-04-19  9:18 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Created attachment 52830
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=52830&action=edit
gcc12-pr105257.patch

Untested fix.

The problem is that (reg:DI 24 %i0 [109]) in a delay slot of the return
satisfies sparc_pic_register_p but epilogue_renumber turns that into:
(reg:DI 8 %o0) which doesn't satisfy it.
The attached patch fixes that by always copying over ORIGINAL_REGNO.
A variant could be to do that only if ORIGINAL_REGNO is non-zero, if it is
zero,
keep using gen_reg_RTX (which can create a shared rtx and therefore shouldn't
have ORIGINAL_REGNO modified).

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

* [Bug target/105257] [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811
  2022-04-13  8:23 [Bug target/105257] New: [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811 ro at gcc dot gnu.org
                   ` (2 preceding siblings ...)
  2022-04-19  9:18 ` jakub at gcc dot gnu.org
@ 2022-04-19 10:14 ` ebotcazou at gcc dot gnu.org
  2022-04-19 10:20 ` ebotcazou at gcc dot gnu.org
                   ` (13 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: ebotcazou at gcc dot gnu.org @ 2022-04-19 10:14 UTC (permalink / raw)
  To: gcc-bugs

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

Eric Botcazou <ebotcazou at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
     Ever confirmed|0                           |1
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2022-04-19

--- Comment #3 from Eric Botcazou <ebotcazou at gcc dot gnu.org> ---
This comes from the new implementation of the PIC support.

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

* [Bug target/105257] [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811
  2022-04-13  8:23 [Bug target/105257] New: [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811 ro at gcc dot gnu.org
                   ` (3 preceding siblings ...)
  2022-04-19 10:14 ` ebotcazou at gcc dot gnu.org
@ 2022-04-19 10:20 ` ebotcazou at gcc dot gnu.org
  2022-04-19 10:29 ` jakub at gcc dot gnu.org
                   ` (12 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: ebotcazou at gcc dot gnu.org @ 2022-04-19 10:20 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #4 from Eric Botcazou <ebotcazou at gcc dot gnu.org> ---
> The problem is that (reg:DI 24 %i0 [109]) in a delay slot of the return
> satisfies sparc_pic_register_p but epilogue_renumber turns that into:
> (reg:DI 8 %o0) which doesn't satisfy it.
> The attached patch fixes that by always copying over ORIGINAL_REGNO.

This looks good to me.  You might as well want to remove the ugly fallthrough.

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

* [Bug target/105257] [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811
  2022-04-13  8:23 [Bug target/105257] New: [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811 ro at gcc dot gnu.org
                   ` (4 preceding siblings ...)
  2022-04-19 10:20 ` ebotcazou at gcc dot gnu.org
@ 2022-04-19 10:29 ` jakub at gcc dot gnu.org
  2022-04-19 10:40 ` ebotcazou at gcc dot gnu.org
                   ` (11 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: jakub at gcc dot gnu.org @ 2022-04-19 10:29 UTC (permalink / raw)
  To: gcc-bugs

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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #52830|0                           |1
        is obsolete|                            |

--- Comment #5 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Created attachment 52831
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=52831&action=edit
gcc12-pr105257.patch

Updated version of the patch with /* fallthrough */ -> return 0; and
which uses gen_rtx_REG if ORIGINAL_REGNO is 0 so that we can use a shared rtx
in that case.
Will take a while to test though, gcc102 on GCCFarm isn't exactly fast even
with make -j256.

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

* [Bug target/105257] [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811
  2022-04-13  8:23 [Bug target/105257] New: [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811 ro at gcc dot gnu.org
                   ` (5 preceding siblings ...)
  2022-04-19 10:29 ` jakub at gcc dot gnu.org
@ 2022-04-19 10:40 ` ebotcazou at gcc dot gnu.org
  2022-04-19 15:31 ` rguenth at gcc dot gnu.org
                   ` (10 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: ebotcazou at gcc dot gnu.org @ 2022-04-19 10:40 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #6 from Eric Botcazou <ebotcazou at gcc dot gnu.org> ---
> Updated version of the patch with /* fallthrough */ -> return 0; and
> which uses gen_rtx_REG if ORIGINAL_REGNO is 0 so that we can use a shared
> rtx in that case.

Thanks.

> Will take a while to test though, gcc102 on GCCFarm isn't exactly fast even
> with make -j256.

Niagara 3... ouch!   Let me test it on a fast SPARC machine.

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

* [Bug target/105257] [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811
  2022-04-13  8:23 [Bug target/105257] New: [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811 ro at gcc dot gnu.org
                   ` (6 preceding siblings ...)
  2022-04-19 10:40 ` ebotcazou at gcc dot gnu.org
@ 2022-04-19 15:31 ` rguenth at gcc dot gnu.org
  2022-04-19 16:52 ` ro at CeBiTec dot Uni-Bielefeld.DE
                   ` (9 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: rguenth at gcc dot gnu.org @ 2022-04-19 15:31 UTC (permalink / raw)
  To: gcc-bugs

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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Priority|P3                          |P2

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

* [Bug target/105257] [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811
  2022-04-13  8:23 [Bug target/105257] New: [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811 ro at gcc dot gnu.org
                   ` (7 preceding siblings ...)
  2022-04-19 15:31 ` rguenth at gcc dot gnu.org
@ 2022-04-19 16:52 ` ro at CeBiTec dot Uni-Bielefeld.DE
  2022-04-19 17:03 ` cvs-commit at gcc dot gnu.org
                   ` (8 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: ro at CeBiTec dot Uni-Bielefeld.DE @ 2022-04-19 16:52 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #7 from ro at CeBiTec dot Uni-Bielefeld.DE <ro at CeBiTec dot Uni-Bielefeld.DE> ---
> --- Comment #6 from Eric Botcazou <ebotcazou at gcc dot gnu.org> ---
>> Will take a while to test though, gcc102 on GCCFarm isn't exactly fast even
>> with make -j256.
>
> Niagara 3... ouch!   Let me test it on a fast SPARC machine.

Indeed ;-)  A regtest completed successfully on my S7-2 system (-j96).

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

* [Bug target/105257] [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811
  2022-04-13  8:23 [Bug target/105257] New: [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811 ro at gcc dot gnu.org
                   ` (8 preceding siblings ...)
  2022-04-19 16:52 ` ro at CeBiTec dot Uni-Bielefeld.DE
@ 2022-04-19 17:03 ` cvs-commit at gcc dot gnu.org
  2022-04-19 17:06 ` [Bug target/105257] [8/9/10/11 " jakub at gcc dot gnu.org
                   ` (7 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-04-19 17:03 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #8 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:eeca2b8bd03f57c59c6cf48bf6b9bd6dc86924f6

commit r12-8197-geeca2b8bd03f57c59c6cf48bf6b9bd6dc86924f6
Author: Jakub Jelinek <jakub@redhat.com>
Date:   Tue Apr 19 18:58:59 2022 +0200

    sparc: Preserve ORIGINAL_REGNO in epilogue_renumber [PR105257]

    The following testcase ICEs, because the pic register is
    (reg:DI 24 %i0 [109]) and is used in the delay slot of a return.
    We invoke epilogue_renumber and that changes it to
    (reg:DI 8 %o0) which no longer satisfies sparc_pic_register_p
    predicate, so we don't recognize the insn anymore.

    The following patch fixes that by preserving ORIGINAL_REGNO if
    specified, so we get (reg:DI 8 %o0 [109]) instead.

    2022-04-19  Jakub Jelinek  <jakub@redhat.com>

            PR target/105257
            * config/sparc/sparc.cc (epilogue_renumber): If ORIGINAL_REGNO,
            use gen_raw_REG instead of gen_rtx_REG and copy over also
            ORIGINAL_REGNO.  Use return 0; instead of /* fallthrough */.

            * gcc.dg/pr105257.c: New test.

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

* [Bug target/105257] [8/9/10/11 regression] ICE in final_scan_insn_1,  at final.cc:2811
  2022-04-13  8:23 [Bug target/105257] New: [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811 ro at gcc dot gnu.org
                   ` (9 preceding siblings ...)
  2022-04-19 17:03 ` cvs-commit at gcc dot gnu.org
@ 2022-04-19 17:06 ` jakub at gcc dot gnu.org
  2022-04-21  9:30 ` cvs-commit at gcc dot gnu.org
                   ` (6 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: jakub at gcc dot gnu.org @ 2022-04-19 17:06 UTC (permalink / raw)
  To: gcc-bugs

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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|[8/9/10/11/12 regression]   |[8/9/10/11 regression] ICE
                   |ICE in final_scan_insn_1,   |in final_scan_insn_1, at
                   |at final.cc:2811            |final.cc:2811

--- Comment #9 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Fixed on the trunk (so far).

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

* [Bug target/105257] [8/9/10/11 regression] ICE in final_scan_insn_1,  at final.cc:2811
  2022-04-13  8:23 [Bug target/105257] New: [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811 ro at gcc dot gnu.org
                   ` (10 preceding siblings ...)
  2022-04-19 17:06 ` [Bug target/105257] [8/9/10/11 " jakub at gcc dot gnu.org
@ 2022-04-21  9:30 ` cvs-commit at gcc dot gnu.org
  2022-04-21  9:31 ` [Bug target/105257] [8/9/10 " jakub at gcc dot gnu.org
                   ` (5 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-04-21  9:30 UTC (permalink / raw)
  To: gcc-bugs

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

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

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

commit r11-9898-gdfe099b4b5c0077a6bd699912fe9442431239e39
Author: Jakub Jelinek <jakub@redhat.com>
Date:   Tue Apr 19 18:58:59 2022 +0200

    sparc: Preserve ORIGINAL_REGNO in epilogue_renumber [PR105257]

    The following testcase ICEs, because the pic register is
    (reg:DI 24 %i0 [109]) and is used in the delay slot of a return.
    We invoke epilogue_renumber and that changes it to
    (reg:DI 8 %o0) which no longer satisfies sparc_pic_register_p
    predicate, so we don't recognize the insn anymore.

    The following patch fixes that by preserving ORIGINAL_REGNO if
    specified, so we get (reg:DI 8 %o0 [109]) instead.

    2022-04-19  Jakub Jelinek  <jakub@redhat.com>

            PR target/105257
            * config/sparc/sparc.c (epilogue_renumber): If ORIGINAL_REGNO,
            use gen_raw_REG instead of gen_rtx_REG and copy over also
            ORIGINAL_REGNO.  Use return 0; instead of /* fallthrough */.

            * gcc.dg/pr105257.c: New test.

    (cherry picked from commit eeca2b8bd03f57c59c6cf48bf6b9bd6dc86924f6)

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

* [Bug target/105257] [8/9/10 regression] ICE in final_scan_insn_1, at final.cc:2811
  2022-04-13  8:23 [Bug target/105257] New: [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811 ro at gcc dot gnu.org
                   ` (11 preceding siblings ...)
  2022-04-21  9:30 ` cvs-commit at gcc dot gnu.org
@ 2022-04-21  9:31 ` jakub at gcc dot gnu.org
  2022-05-06  8:33 ` jakub at gcc dot gnu.org
                   ` (4 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: jakub at gcc dot gnu.org @ 2022-04-21  9:31 UTC (permalink / raw)
  To: gcc-bugs

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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|[8/9/10/11 regression] ICE  |[8/9/10 regression] ICE in
                   |in final_scan_insn_1, at    |final_scan_insn_1, at
                   |final.cc:2811               |final.cc:2811

--- Comment #11 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Fixed for 11.4 as well.

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

* [Bug target/105257] [8/9/10 regression] ICE in final_scan_insn_1, at final.cc:2811
  2022-04-13  8:23 [Bug target/105257] New: [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811 ro at gcc dot gnu.org
                   ` (12 preceding siblings ...)
  2022-04-21  9:31 ` [Bug target/105257] [8/9/10 " jakub at gcc dot gnu.org
@ 2022-05-06  8:33 ` jakub at gcc dot gnu.org
  2022-05-06  8:56 ` [Bug target/105257] [9/10 " jakub at gcc dot gnu.org
                   ` (3 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: jakub at gcc dot gnu.org @ 2022-05-06  8:33 UTC (permalink / raw)
  To: gcc-bugs

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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|12.0                        |12.2

--- Comment #12 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
GCC 12.1 is being released, retargeting bugs to GCC 12.2.

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

* [Bug target/105257] [9/10 regression] ICE in final_scan_insn_1, at final.cc:2811
  2022-04-13  8:23 [Bug target/105257] New: [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811 ro at gcc dot gnu.org
                   ` (13 preceding siblings ...)
  2022-05-06  8:33 ` jakub at gcc dot gnu.org
@ 2022-05-06  8:56 ` jakub at gcc dot gnu.org
  2022-05-10  8:26 ` cvs-commit at gcc dot gnu.org
                   ` (2 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: jakub at gcc dot gnu.org @ 2022-05-06  8:56 UTC (permalink / raw)
  To: gcc-bugs

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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|12.2                        |9.5
            Summary|[8/9/10 regression] ICE in  |[9/10 regression] ICE in
                   |final_scan_insn_1, at       |final_scan_insn_1, at
                   |final.cc:2811               |final.cc:2811

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

* [Bug target/105257] [9/10 regression] ICE in final_scan_insn_1, at final.cc:2811
  2022-04-13  8:23 [Bug target/105257] New: [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811 ro at gcc dot gnu.org
                   ` (14 preceding siblings ...)
  2022-05-06  8:56 ` [Bug target/105257] [9/10 " jakub at gcc dot gnu.org
@ 2022-05-10  8:26 ` cvs-commit at gcc dot gnu.org
  2022-05-11  6:26 ` cvs-commit at gcc dot gnu.org
  2022-05-11  6:36 ` jakub at gcc dot gnu.org
  17 siblings, 0 replies; 19+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-05-10  8:26 UTC (permalink / raw)
  To: gcc-bugs

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

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

https://gcc.gnu.org/g:9978dc376c03a6c599b9cbd385baec9611f79ba3

commit r10-10710-g9978dc376c03a6c599b9cbd385baec9611f79ba3
Author: Jakub Jelinek <jakub@redhat.com>
Date:   Tue Apr 19 18:58:59 2022 +0200

    sparc: Preserve ORIGINAL_REGNO in epilogue_renumber [PR105257]

    The following testcase ICEs, because the pic register is
    (reg:DI 24 %i0 [109]) and is used in the delay slot of a return.
    We invoke epilogue_renumber and that changes it to
    (reg:DI 8 %o0) which no longer satisfies sparc_pic_register_p
    predicate, so we don't recognize the insn anymore.

    The following patch fixes that by preserving ORIGINAL_REGNO if
    specified, so we get (reg:DI 8 %o0 [109]) instead.

    2022-04-19  Jakub Jelinek  <jakub@redhat.com>

            PR target/105257
            * config/sparc/sparc.c (epilogue_renumber): If ORIGINAL_REGNO,
            use gen_raw_REG instead of gen_rtx_REG and copy over also
            ORIGINAL_REGNO.  Use return 0; instead of /* fallthrough */.

            * gcc.dg/pr105257.c: New test.

    (cherry picked from commit eeca2b8bd03f57c59c6cf48bf6b9bd6dc86924f6)

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

* [Bug target/105257] [9/10 regression] ICE in final_scan_insn_1, at final.cc:2811
  2022-04-13  8:23 [Bug target/105257] New: [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811 ro at gcc dot gnu.org
                   ` (15 preceding siblings ...)
  2022-05-10  8:26 ` cvs-commit at gcc dot gnu.org
@ 2022-05-11  6:26 ` cvs-commit at gcc dot gnu.org
  2022-05-11  6:36 ` jakub at gcc dot gnu.org
  17 siblings, 0 replies; 19+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-05-11  6:26 UTC (permalink / raw)
  To: gcc-bugs

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

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

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

commit r9-10151-g4f18893fbd53205588c952856184367671b2a880
Author: Jakub Jelinek <jakub@redhat.com>
Date:   Tue Apr 19 18:58:59 2022 +0200

    sparc: Preserve ORIGINAL_REGNO in epilogue_renumber [PR105257]

    The following testcase ICEs, because the pic register is
    (reg:DI 24 %i0 [109]) and is used in the delay slot of a return.
    We invoke epilogue_renumber and that changes it to
    (reg:DI 8 %o0) which no longer satisfies sparc_pic_register_p
    predicate, so we don't recognize the insn anymore.

    The following patch fixes that by preserving ORIGINAL_REGNO if
    specified, so we get (reg:DI 8 %o0 [109]) instead.

    2022-04-19  Jakub Jelinek  <jakub@redhat.com>

            PR target/105257
            * config/sparc/sparc.c (epilogue_renumber): If ORIGINAL_REGNO,
            use gen_raw_REG instead of gen_rtx_REG and copy over also
            ORIGINAL_REGNO.  Use return 0; instead of /* fallthrough */.

            * gcc.dg/pr105257.c: New test.

    (cherry picked from commit eeca2b8bd03f57c59c6cf48bf6b9bd6dc86924f6)

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

* [Bug target/105257] [9/10 regression] ICE in final_scan_insn_1, at final.cc:2811
  2022-04-13  8:23 [Bug target/105257] New: [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811 ro at gcc dot gnu.org
                   ` (16 preceding siblings ...)
  2022-05-11  6:26 ` cvs-commit at gcc dot gnu.org
@ 2022-05-11  6:36 ` jakub at gcc dot gnu.org
  17 siblings, 0 replies; 19+ messages in thread
From: jakub at gcc dot gnu.org @ 2022-05-11  6:36 UTC (permalink / raw)
  To: gcc-bugs

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

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

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

--- Comment #15 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Fixed.

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

end of thread, other threads:[~2022-05-11  6:36 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-04-13  8:23 [Bug target/105257] New: [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811 ro at gcc dot gnu.org
2022-04-13  8:23 ` [Bug target/105257] " ro at gcc dot gnu.org
2022-04-19  9:08 ` jakub at gcc dot gnu.org
2022-04-19  9:18 ` jakub at gcc dot gnu.org
2022-04-19 10:14 ` ebotcazou at gcc dot gnu.org
2022-04-19 10:20 ` ebotcazou at gcc dot gnu.org
2022-04-19 10:29 ` jakub at gcc dot gnu.org
2022-04-19 10:40 ` ebotcazou at gcc dot gnu.org
2022-04-19 15:31 ` rguenth at gcc dot gnu.org
2022-04-19 16:52 ` ro at CeBiTec dot Uni-Bielefeld.DE
2022-04-19 17:03 ` cvs-commit at gcc dot gnu.org
2022-04-19 17:06 ` [Bug target/105257] [8/9/10/11 " jakub at gcc dot gnu.org
2022-04-21  9:30 ` cvs-commit at gcc dot gnu.org
2022-04-21  9:31 ` [Bug target/105257] [8/9/10 " jakub at gcc dot gnu.org
2022-05-06  8:33 ` jakub at gcc dot gnu.org
2022-05-06  8:56 ` [Bug target/105257] [9/10 " jakub at gcc dot gnu.org
2022-05-10  8:26 ` cvs-commit at gcc dot gnu.org
2022-05-11  6:26 ` cvs-commit at gcc dot gnu.org
2022-05-11  6:36 ` 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).