public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/103517] New: ICE in as_a, at is-a.h:242 with -O2 -march=skylake-avx512
@ 2021-12-01 9:32 vsevolod.livinskij at frtk dot ru
2021-12-01 9:36 ` [Bug tree-optimization/103517] [12 Regression] ICE in as_a, at is-a.h:242 with -O2 -march=skylake-avx512 since r12-5612-g10833849b55401a5 marxin at gcc dot gnu.org
` (3 more replies)
0 siblings, 4 replies; 5+ messages in thread
From: vsevolod.livinskij at frtk dot ru @ 2021-12-01 9:32 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103517
Bug ID: 103517
Summary: ICE in as_a, at is-a.h:242 with -O2
-march=skylake-avx512
Product: gcc
Version: 12.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: tree-optimization
Assignee: unassigned at gcc dot gnu.org
Reporter: vsevolod.livinskij at frtk dot ru
Target Milestone: ---
The same error exists for Sapphire Rapids
Reproducer:
int a;
short b, c;
extern short d[];
void e() {
for (short f = 1; f < (short)a; f += 2)
if (d[f + 1]) {
b = d[f];
c = d[f + 1];
}
}
Error:
>$ g++ -O2 -march=skylake-avx512 -c func.cpp
during GIMPLE pass: vect
func.cpp: In function 'void e()':
func.cpp:4:6: internal compiler error: in as_a, at is-a.h:242
4 | void e() {
| ^
0x8bc06a gphi const* as_a<gphi const*, gimple const>(gimple const*)
/testing/gcc/gcc_src_master/gcc/is-a.h:242
0x8bc684 gcall* as_a<gcall*, gimple>(gimple*)
/testing/gcc/gcc_src_master/gcc/tree-vect-slp.c:991
0x8bc684 vect_build_slp_tree_1
/testing/gcc/gcc_src_master/gcc/tree-vect-slp.c:1155
0x14880cc vect_build_slp_tree_2
/testing/gcc/gcc_src_master/gcc/tree-vect-slp.c:1711
0x1487a0c vect_build_slp_tree
/testing/gcc/gcc_src_master/gcc/tree-vect-slp.c:1544
0x1488884 vect_build_slp_tree_2
/testing/gcc/gcc_src_master/gcc/tree-vect-slp.c:2206
0x1487a0c vect_build_slp_tree
/testing/gcc/gcc_src_master/gcc/tree-vect-slp.c:1544
0x148c230 vect_build_slp_instance
/testing/gcc/gcc_src_master/gcc/tree-vect-slp.c:3019
0x148d6b5 vect_analyze_slp_instance
/testing/gcc/gcc_src_master/gcc/tree-vect-slp.c:3339
0x14920d4 vect_analyze_slp(vec_info*, unsigned int)
/testing/gcc/gcc_src_master/gcc/tree-vect-slp.c:3422
0x146d24a vect_analyze_loop_2
/testing/gcc/gcc_src_master/gcc/tree-vect-loop.c:2331
0x146eef9 vect_analyze_loop_1
/testing/gcc/gcc_src_master/gcc/tree-vect-loop.c:2830
0x146f40a vect_analyze_loop(loop*, vec_info_shared*)
/testing/gcc/gcc_src_master/gcc/tree-vect-loop.c:2952
0x14a3359 try_vectorize_loop_1
/testing/gcc/gcc_src_master/gcc/tree-vectorizer.c:1047
0x14a3359 try_vectorize_loop
/testing/gcc/gcc_src_master/gcc/tree-vectorizer.c:1162
0x14a3fb4 execute
/testing/gcc/gcc_src_master/gcc/tree-vectorizer.c:1278
gcc version 12.0.0 20211130 (6b8ecbc6d6652d061d7c72c64352d51eca2df6ca) (GCC)
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug tree-optimization/103517] [12 Regression] ICE in as_a, at is-a.h:242 with -O2 -march=skylake-avx512 since r12-5612-g10833849b55401a5
2021-12-01 9:32 [Bug tree-optimization/103517] New: ICE in as_a, at is-a.h:242 with -O2 -march=skylake-avx512 vsevolod.livinskij at frtk dot ru
@ 2021-12-01 9:36 ` marxin at gcc dot gnu.org
2021-12-01 10:31 ` rsandifo at gcc dot gnu.org
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: marxin at gcc dot gnu.org @ 2021-12-01 9:36 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103517
Martin Liška <marxin at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Summary|ICE in as_a, at is-a.h:242 |[12 Regression] ICE in
|with -O2 |as_a, at is-a.h:242 with
|-march=skylake-avx512 |-O2 -march=skylake-avx512
| |since
| |r12-5612-g10833849b55401a5
Target Milestone|--- |12.0
CC| |marxin at gcc dot gnu.org,
| |rsandifo at gcc dot gnu.org
Status|UNCONFIRMED |NEW
Priority|P3 |P1
Last reconfirmed| |2021-12-01
Ever confirmed|0 |1
--- Comment #1 from Martin Liška <marxin at gcc dot gnu.org> ---
Thanks for the report, started with 12-5612-g10833849b55401a5.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug tree-optimization/103517] [12 Regression] ICE in as_a, at is-a.h:242 with -O2 -march=skylake-avx512 since r12-5612-g10833849b55401a5
2021-12-01 9:32 [Bug tree-optimization/103517] New: ICE in as_a, at is-a.h:242 with -O2 -march=skylake-avx512 vsevolod.livinskij at frtk dot ru
2021-12-01 9:36 ` [Bug tree-optimization/103517] [12 Regression] ICE in as_a, at is-a.h:242 with -O2 -march=skylake-avx512 since r12-5612-g10833849b55401a5 marxin at gcc dot gnu.org
@ 2021-12-01 10:31 ` rsandifo at gcc dot gnu.org
2021-12-01 14:36 ` cvs-commit at gcc dot gnu.org
2021-12-01 14:39 ` rsandifo at gcc dot gnu.org
3 siblings, 0 replies; 5+ messages in thread
From: rsandifo at gcc dot gnu.org @ 2021-12-01 10:31 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103517
rsandifo at gcc dot gnu.org <rsandifo at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Assignee|unassigned at gcc dot gnu.org |rsandifo at gcc dot gnu.org
Status|NEW |ASSIGNED
--- Comment #2 from rsandifo at gcc dot gnu.org <rsandifo at gcc dot gnu.org> ---
Mine.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug tree-optimization/103517] [12 Regression] ICE in as_a, at is-a.h:242 with -O2 -march=skylake-avx512 since r12-5612-g10833849b55401a5
2021-12-01 9:32 [Bug tree-optimization/103517] New: ICE in as_a, at is-a.h:242 with -O2 -march=skylake-avx512 vsevolod.livinskij at frtk dot ru
2021-12-01 9:36 ` [Bug tree-optimization/103517] [12 Regression] ICE in as_a, at is-a.h:242 with -O2 -march=skylake-avx512 since r12-5612-g10833849b55401a5 marxin at gcc dot gnu.org
2021-12-01 10:31 ` rsandifo at gcc dot gnu.org
@ 2021-12-01 14:36 ` cvs-commit at gcc dot gnu.org
2021-12-01 14:39 ` rsandifo at gcc dot gnu.org
3 siblings, 0 replies; 5+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2021-12-01 14:36 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103517
--- Comment #3 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Richard Sandiford <rsandifo@gcc.gnu.org>:
https://gcc.gnu.org/g:1e625a44f6f3001cea31e0f7c563943ecba92b68
commit r12-5689-g1e625a44f6f3001cea31e0f7c563943ecba92b68
Author: Richard Sandiford <richard.sandiford@arm.com>
Date: Wed Dec 1 14:36:24 2021 +0000
vect: Tighten check for SLP memory groups [PR103517]
When checking for compatible stmts, vect_build_slp_tree_1 did:
&& !(STMT_VINFO_GROUPED_ACCESS (stmt_info)
&& (first_stmt_code == ARRAY_REF
|| first_stmt_code == BIT_FIELD_REF
|| first_stmt_code == INDIRECT_REF
|| first_stmt_code == COMPONENT_REF
|| first_stmt_code == MEM_REF)))
That is, it allowed any rhs_code as long as the first_stmt_code
looked valid. This had the effect of allowing IFN_MASK_LOAD
to be paired with an earlier non-call code (but didn't allow
the reverse).
This patch makes the check symmetrical.
gcc/
PR tree-optimization/103517
* tree-vect-slp.c (vect_build_slp_tree_1): When allowing two
different component references, check the codes of both them,
rather than just the first.
gcc/testsuite/
PR tree-optimization/103517
* gcc.dg/vect/pr103517.c: New test.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug tree-optimization/103517] [12 Regression] ICE in as_a, at is-a.h:242 with -O2 -march=skylake-avx512 since r12-5612-g10833849b55401a5
2021-12-01 9:32 [Bug tree-optimization/103517] New: ICE in as_a, at is-a.h:242 with -O2 -march=skylake-avx512 vsevolod.livinskij at frtk dot ru
` (2 preceding siblings ...)
2021-12-01 14:36 ` cvs-commit at gcc dot gnu.org
@ 2021-12-01 14:39 ` rsandifo at gcc dot gnu.org
3 siblings, 0 replies; 5+ messages in thread
From: rsandifo at gcc dot gnu.org @ 2021-12-01 14:39 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103517
rsandifo at gcc dot gnu.org <rsandifo at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Resolution|--- |FIXED
Status|ASSIGNED |RESOLVED
--- Comment #4 from rsandifo at gcc dot gnu.org <rsandifo at gcc dot gnu.org> ---
Fixed.
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2021-12-01 14:39 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-12-01 9:32 [Bug tree-optimization/103517] New: ICE in as_a, at is-a.h:242 with -O2 -march=skylake-avx512 vsevolod.livinskij at frtk dot ru
2021-12-01 9:36 ` [Bug tree-optimization/103517] [12 Regression] ICE in as_a, at is-a.h:242 with -O2 -march=skylake-avx512 since r12-5612-g10833849b55401a5 marxin at gcc dot gnu.org
2021-12-01 10:31 ` rsandifo at gcc dot gnu.org
2021-12-01 14:36 ` cvs-commit at gcc dot gnu.org
2021-12-01 14:39 ` rsandifo 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).