public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug target/109733] New: ICE in extract_insn, at recog.cc:2791 since r14-475-g508f082829af68
@ 2023-05-04 12:59 marxin at gcc dot gnu.org
2023-05-04 13:01 ` [Bug target/109733] [14 Regression] " marxin at gcc dot gnu.org
` (5 more replies)
0 siblings, 6 replies; 7+ messages in thread
From: marxin at gcc dot gnu.org @ 2023-05-04 12:59 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109733
Bug ID: 109733
Summary: ICE in extract_insn, at recog.cc:2791 since
r14-475-g508f082829af68
Product: gcc
Version: 14.0
Status: UNCONFIRMED
Keywords: ice-on-valid-code
Severity: normal
Priority: P3
Component: target
Assignee: unassigned at gcc dot gnu.org
Reporter: marxin at gcc dot gnu.org
CC: ubizjak at gmail dot com
Target Milestone: ---
Host: x86_64-linux-gnu
I noticed the following crash:
$ cat x.f90
use iso_c_binding
interface
subroutine ctest_cont (a, is_cont) bind (c, name="ctest")
end subroutine
subroutine ctest_ar_cont (a, is_cont) bind (c, name="ctest")
use iso_c_binding
integer(C_INT), contiguous :: a(..)
logical(C_Bool), value :: is_cont
end subroutine
end interface
integer(C_INT), target :: aa(10,5)
integer(C_INT), target :: bb(10,10)
do j = 1, 5
do i = 1, 10
end do
end do
call ftest (transpose (aa), is_cont=.true._c_bool) ! Implementation choice:
copy in; hence, contiguous
call ftest (bb(2:10:2, :), is_cont=.false._c_bool)
contains
subroutine ftest (a, is_cont)
integer(C_INT) :: a(:,:)
logical(c_bool), value, intent(in) :: is_cont
call ctest_ar_cont (a, is_cont=.true._c_bool)
end subroutine
subroutine ftest_ar (a, is_cont)
end subroutine
end program
$ gfortran x.f90 -ftree-vrp -O1 -mavx512vbmi2 -m32 -march=i686 -c
x.f90:24:16:
24 | end subroutine
| ^
Error: unrecognizable insn:
(insn 429 416 379 18 (set (reg:SI 72 k4 [orig:121 _114 ] [121])
(mult:SI (reg:SI 70 k2 [orig:112 ubound.0 ] [112])
(const_int 4 [0x4]))) -1
(nil))
during RTL pass: split2
x.f90:24:16: internal compiler error: in extract_insn, at recog.cc:2791
0x1f4c694 diagnostic_impl(rich_location*, diagnostic_metadata const*, int, char
const*, __va_list_tag (*) [1], diagnostic_t)
???:0
0x1f4d2e6 internal_error(char const*, ...)
???:0
0x899ba5 fancy_abort(char const*, int, char const*)
???:0
0x76b68a _fatal_insn(char const*, rtx_def const*, char const*, int, char
const*)
???:0
0x76b6a6 _fatal_insn_not_found(rtx_def const*, char const*, int, char const*)
???:0
0x769bc3 extract_insn(rtx_insn*) [clone .cold]
???:0
0xef4694 extract_insn_cached(rtx_insn*)
???:0
0xbd7d24 cleanup_subreg_operands(rtx_insn*)
???:0
0xef2676 split_insn(rtx_insn*)
???:0
0xef7aa9 split_all_insns()
???:0
0xef7bb8 (anonymous namespace)::pass_split_all_insns::execute(function*)
???:0
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] 7+ messages in thread
* [Bug target/109733] [14 Regression] ICE in extract_insn, at recog.cc:2791 since r14-475-g508f082829af68
2023-05-04 12:59 [Bug target/109733] New: ICE in extract_insn, at recog.cc:2791 since r14-475-g508f082829af68 marxin at gcc dot gnu.org
@ 2023-05-04 13:01 ` marxin at gcc dot gnu.org
2023-05-04 15:53 ` ubizjak at gmail dot com
` (4 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: marxin at gcc dot gnu.org @ 2023-05-04 13:01 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109733
Martin Liška <marxin at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Last reconfirmed| |2023-05-04
Summary|ICE in extract_insn, at |[14 Regression] ICE in
|recog.cc:2791 since |extract_insn, at
|r14-475-g508f082829af68 |recog.cc:2791 since
| |r14-475-g508f082829af68
Ever confirmed|0 |1
Status|UNCONFIRMED |NEW
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug target/109733] [14 Regression] ICE in extract_insn, at recog.cc:2791 since r14-475-g508f082829af68
2023-05-04 12:59 [Bug target/109733] New: ICE in extract_insn, at recog.cc:2791 since r14-475-g508f082829af68 marxin at gcc dot gnu.org
2023-05-04 13:01 ` [Bug target/109733] [14 Regression] " marxin at gcc dot gnu.org
@ 2023-05-04 15:53 ` ubizjak at gmail dot com
2023-05-04 16:32 ` ubizjak at gmail dot com
` (3 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: ubizjak at gmail dot com @ 2023-05-04 15:53 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109733
--- Comment #1 from Uroš Bizjak <ubizjak at gmail dot com> ---
The patched compiler just happens to trigger the existing problem where:
(insn 188 416 379 18 (parallel [
(set (reg:SI 72 k4 [orig:121 _114 ] [121])
(ashift:SI (reg:SI 70 k2 [orig:112 ubound.0 ] [112])
(const_int 2 [0x2])))
(clobber (reg:CC 17 flags))
]) 811 {*ashlsi3_1}
(nil))
gets split with a post-reload splitter a to non-existent:
(insn 429 416 379 18 (set (reg:SI 72 k4 [orig:121 _114 ] [121])
(mult:SI (reg:SI 70 k2 [orig:112 ubound.0 ] [112])
(const_int 4 [0x4]))) -1
(nil))
Please note mask registers, which points to a post-reload splitter with too
broad predicates.
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug target/109733] [14 Regression] ICE in extract_insn, at recog.cc:2791 since r14-475-g508f082829af68
2023-05-04 12:59 [Bug target/109733] New: ICE in extract_insn, at recog.cc:2791 since r14-475-g508f082829af68 marxin at gcc dot gnu.org
2023-05-04 13:01 ` [Bug target/109733] [14 Regression] " marxin at gcc dot gnu.org
2023-05-04 15:53 ` ubizjak at gmail dot com
@ 2023-05-04 16:32 ` ubizjak at gmail dot com
2023-05-04 16:33 ` ubizjak at gmail dot com
` (2 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: ubizjak at gmail dot com @ 2023-05-04 16:32 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109733
Uroš Bizjak <ubizjak at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Assignee|unassigned at gcc dot gnu.org |ubizjak at gmail dot com
Status|NEW |ASSIGNED
--- Comment #2 from Uroš Bizjak <ubizjak at gmail dot com> ---
Created attachment 54996
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=54996&action=edit
Patch in testing.
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug target/109733] [14 Regression] ICE in extract_insn, at recog.cc:2791 since r14-475-g508f082829af68
2023-05-04 12:59 [Bug target/109733] New: ICE in extract_insn, at recog.cc:2791 since r14-475-g508f082829af68 marxin at gcc dot gnu.org
` (2 preceding siblings ...)
2023-05-04 16:32 ` ubizjak at gmail dot com
@ 2023-05-04 16:33 ` ubizjak at gmail dot com
2023-05-04 18:27 ` cvs-commit at gcc dot gnu.org
2023-05-04 18:27 ` ubizjak at gmail dot com
5 siblings, 0 replies; 7+ messages in thread
From: ubizjak at gmail dot com @ 2023-05-04 16:33 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109733
Uroš Bizjak <ubizjak at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #54996|0 |1
is obsolete| |
--- Comment #3 from Uroš Bizjak <ubizjak at gmail dot com> ---
Created attachment 54997
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=54997&action=edit
The correct patch.
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug target/109733] [14 Regression] ICE in extract_insn, at recog.cc:2791 since r14-475-g508f082829af68
2023-05-04 12:59 [Bug target/109733] New: ICE in extract_insn, at recog.cc:2791 since r14-475-g508f082829af68 marxin at gcc dot gnu.org
` (3 preceding siblings ...)
2023-05-04 16:33 ` ubizjak at gmail dot com
@ 2023-05-04 18:27 ` cvs-commit at gcc dot gnu.org
2023-05-04 18:27 ` ubizjak at gmail dot com
5 siblings, 0 replies; 7+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2023-05-04 18:27 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109733
--- Comment #4 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Uros Bizjak <uros@gcc.gnu.org>:
https://gcc.gnu.org/g:8cac23781753bd8a016507dc9b21ec563e1d9b49
commit r14-485-g8cac23781753bd8a016507dc9b21ec563e1d9b49
Author: Uros Bizjak <ubizjak@gmail.com>
Date: Thu May 4 20:26:12 2023 +0200
i386: Tighten ashift to lea splitter operand predicates [PR109733]
The predicates of ashift to lea post-reload splitter were too broad
so the splitter tried to convert the mask shift instruction. Tighten
operand predicates to match only general registers.
gcc/ChangeLog:
PR target/109733
* config/i386/predicates.md (index_reg_operand): New predicate.
* config/i386/i386.md (ashift to lea spliter): Use
general_reg_operand and index_reg_operand predicates.
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug target/109733] [14 Regression] ICE in extract_insn, at recog.cc:2791 since r14-475-g508f082829af68
2023-05-04 12:59 [Bug target/109733] New: ICE in extract_insn, at recog.cc:2791 since r14-475-g508f082829af68 marxin at gcc dot gnu.org
` (4 preceding siblings ...)
2023-05-04 18:27 ` cvs-commit at gcc dot gnu.org
@ 2023-05-04 18:27 ` ubizjak at gmail dot com
5 siblings, 0 replies; 7+ messages in thread
From: ubizjak at gmail dot com @ 2023-05-04 18:27 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109733
Uroš Bizjak <ubizjak at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|--- |14.0
Status|ASSIGNED |RESOLVED
Resolution|--- |FIXED
--- Comment #5 from Uroš Bizjak <ubizjak at gmail dot com> ---
Fixed.
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2023-05-04 18:27 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-05-04 12:59 [Bug target/109733] New: ICE in extract_insn, at recog.cc:2791 since r14-475-g508f082829af68 marxin at gcc dot gnu.org
2023-05-04 13:01 ` [Bug target/109733] [14 Regression] " marxin at gcc dot gnu.org
2023-05-04 15:53 ` ubizjak at gmail dot com
2023-05-04 16:32 ` ubizjak at gmail dot com
2023-05-04 16:33 ` ubizjak at gmail dot com
2023-05-04 18:27 ` cvs-commit at gcc dot gnu.org
2023-05-04 18:27 ` ubizjak at gmail dot com
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).