[Bug target/105257] [8/9/10/11/12 regression] ICE in final_scan_insn_1, at final.cc:2811
cvs-commit at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Tue Apr 19 17:03:50 GMT 2022
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.
More information about the Gcc-bugs
mailing list