public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/106491] New: ICE when compiling ArmSVE intrinsics in PCH
@ 2022-07-31 9:09 denis.yaroshevskij at gmail dot com
2022-07-31 9:15 ` [Bug target/106491] " pinskia at gcc dot gnu.org
` (12 more replies)
0 siblings, 13 replies; 14+ messages in thread
From: denis.yaroshevskij at gmail dot com @ 2022-07-31 9:09 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106491
Bug ID: 106491
Summary: ICE when compiling ArmSVE intrinsics in PCH
Product: gcc
Version: 11.2.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: denis.yaroshevskij at gmail dot com
Target Milestone: ---
Created attachment 53391
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=53391&action=edit
verbose outputs and .ii files
A stack trace:
```
0xd609b3 crash_signal
../../src/gcc/toplev.c:327
0x7faec4b3951f ???
./signal/../sysdeps/unix/sysv/linux/x86_64/libc_sigaction.c:0
0x10d8340 TYPE_VECTOR_SUBPARTS(tree_node const*)
../../src/gcc/tree.h:3911
0x10d8340 aarch64_sve::gimple_folder::convert_pred(gimple*&, tree_node*,
unsigned int)
../../src/gcc/config/aarch64/aarch64-sve-builtins.cc:2566
0x10e49df fold
../../src/gcc/config/aarch64/aarch64-sve-builtins-base.cc:1096
0x10dae1c aarch64_sve::gimple_folder::fold()
../../src/gcc/config/aarch64/aarch64-sve-builtins.cc:2680
0x10dae1c aarch64_sve::gimple_folder::fold()
../../src/gcc/config/aarch64/aarch64-sve-builtins.cc:2667
0x10dae1c aarch64_sve::gimple_fold_builtin(unsigned int, gimple_stmt_iterator*,
gcall*)
../../src/gcc/config/aarch64/aarch64-sve-builtins.cc:3610
0x104f8f2 aarch64_gimple_fold_builtin
../../src/gcc/config/aarch64/aarch64.c:14096
0xacd886 gimple_fold_call
../../src/gcc/gimple-fold.c:5400
0xacd886 fold_stmt_1
../../src/gcc/gimple-fold.c:6098
0x16d108f lower_stmt
../../src/gcc/gimple-low.c:388
0x16d1a2c lower_sequence
../../src/gcc/gimple-low.c:217
0x16d1a2c lower_gimple_bind
../../src/gcc/gimple-low.c:473
0x16d1f16 lower_function_body
../../src/gcc/gimple-low.c:110
0x16d1f16 execute
../../src/gcc/gimple-low.c:195
```
Reporting this one was tricky, please let me know if you need some more
information
With "-v" I successfully reproduce the crash
"-v -save-temps" causes "-Werror=invalid-pch" to fire
```
cc1plus: error:
/home/dyarosh/space/eve/build_sve512/CMakeFiles/test_pch.dir/cmake_pch.hxx.gch:
not used because `__AARCH64EL__' is defined [-Werror=invalid-pch]
```
If I remove "-Werror" - passes with no crash (maybe it dropped the pch?)
Attaching "-v" output, "-v -save-temps" output and all .*ii files I could find.
Let me know if you need some more information to help reproduce this.
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug target/106491] ICE when compiling ArmSVE intrinsics in PCH
2022-07-31 9:09 [Bug c++/106491] New: ICE when compiling ArmSVE intrinsics in PCH denis.yaroshevskij at gmail dot com
@ 2022-07-31 9:15 ` pinskia at gcc dot gnu.org
2022-07-31 19:26 ` pinskia at gcc dot gnu.org
` (11 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: pinskia at gcc dot gnu.org @ 2022-07-31 9:15 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106491
--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
I might have fixed this for gcc 12 already.
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug target/106491] ICE when compiling ArmSVE intrinsics in PCH
2022-07-31 9:09 [Bug c++/106491] New: ICE when compiling ArmSVE intrinsics in PCH denis.yaroshevskij at gmail dot com
2022-07-31 9:15 ` [Bug target/106491] " pinskia at gcc dot gnu.org
@ 2022-07-31 19:26 ` pinskia at gcc dot gnu.org
2022-07-31 19:33 ` pinskia at gcc dot gnu.org
` (10 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: pinskia at gcc dot gnu.org @ 2022-07-31 19:26 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106491
--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
(In reply to Andrew Pinski from comment #1)
> I might have fixed this for gcc 12 already.
Maybe fixed them with r12-3348-g98f1dd0212d576.
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug target/106491] ICE when compiling ArmSVE intrinsics in PCH
2022-07-31 9:09 [Bug c++/106491] New: ICE when compiling ArmSVE intrinsics in PCH denis.yaroshevskij at gmail dot com
2022-07-31 9:15 ` [Bug target/106491] " pinskia at gcc dot gnu.org
2022-07-31 19:26 ` pinskia at gcc dot gnu.org
@ 2022-07-31 19:33 ` pinskia at gcc dot gnu.org
2022-08-01 10:19 ` denis.yaroshevskij at gmail dot com
` (9 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: pinskia at gcc dot gnu.org @ 2022-07-31 19:33 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106491
--- Comment #3 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
0x104f8f2 aarch64_gimple_fold_builtin
../../src/gcc/config/aarch64/aarch64.c:14096
You should report this to ubuntu as the above line does not match up with the
code being invoked.
as mentioned in
> See <file:///usr/share/doc/gcc-11/README.Bugs> for instructions.
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug target/106491] ICE when compiling ArmSVE intrinsics in PCH
2022-07-31 9:09 [Bug c++/106491] New: ICE when compiling ArmSVE intrinsics in PCH denis.yaroshevskij at gmail dot com
` (2 preceding siblings ...)
2022-07-31 19:33 ` pinskia at gcc dot gnu.org
@ 2022-08-01 10:19 ` denis.yaroshevskij at gmail dot com
2022-08-01 22:29 ` denis.yaroshevskij at gmail dot com
` (8 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: denis.yaroshevskij at gmail dot com @ 2022-08-01 10:19 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106491
--- Comment #4 from Denis Yaroshevskiy <denis.yaroshevskij at gmail dot com> ---
Thanks for the response, after testing with an updated gcc.
As far as the Ubuntu comment - I didn't quite understand that, sorry.
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug target/106491] ICE when compiling ArmSVE intrinsics in PCH
2022-07-31 9:09 [Bug c++/106491] New: ICE when compiling ArmSVE intrinsics in PCH denis.yaroshevskij at gmail dot com
` (3 preceding siblings ...)
2022-08-01 10:19 ` denis.yaroshevskij at gmail dot com
@ 2022-08-01 22:29 ` denis.yaroshevskij at gmail dot com
2022-09-15 15:15 ` rsandifo at gcc dot gnu.org
` (7 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: denis.yaroshevskij at gmail dot com @ 2022-08-01 22:29 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106491
--- Comment #5 from Denis Yaroshevskiy <denis.yaroshevskij at gmail dot com> ---
Tried with gcc-12, still the same issue.
gcc version 12.0.1 20220222 (experimental) [master r12-7325-g2f59f067610]
(Ubuntu 12-20220222-1ubuntu1)
Does that include the fix you talked about?
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug target/106491] ICE when compiling ArmSVE intrinsics in PCH
2022-07-31 9:09 [Bug c++/106491] New: ICE when compiling ArmSVE intrinsics in PCH denis.yaroshevskij at gmail dot com
` (4 preceding siblings ...)
2022-08-01 22:29 ` denis.yaroshevskij at gmail dot com
@ 2022-09-15 15:15 ` rsandifo at gcc dot gnu.org
2022-09-20 14:28 ` cvs-commit at gcc dot gnu.org
` (6 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: rsandifo at gcc dot gnu.org @ 2022-09-15 15:15 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106491
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
Last reconfirmed| |2022-09-15
CC| |rsandifo at gcc dot gnu.org
Status|UNCONFIRMED |ASSIGNED
Ever confirmed|0 |1
--- Comment #6 from rsandifo at gcc dot gnu.org <rsandifo at gcc dot gnu.org> ---
Thanks for the testcase. It looks like some of the SVE
garbage-collection markers are being silently ignored.
Testing a patch...
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug target/106491] ICE when compiling ArmSVE intrinsics in PCH
2022-07-31 9:09 [Bug c++/106491] New: ICE when compiling ArmSVE intrinsics in PCH denis.yaroshevskij at gmail dot com
` (5 preceding siblings ...)
2022-09-15 15:15 ` rsandifo at gcc dot gnu.org
@ 2022-09-20 14:28 ` cvs-commit at gcc dot gnu.org
2022-09-20 14:30 ` rsandifo at gcc dot gnu.org
` (5 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-09-20 14:28 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106491
--- Comment #7 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The trunk branch has been updated by Richard Sandiford <rsandifo@gcc.gnu.org>:
https://gcc.gnu.org/g:6bf5a704d36243c4c04b17a9408ebe881beb0051
commit r13-2739-g6bf5a704d36243c4c04b17a9408ebe881beb0051
Author: Richard Sandiford <richard.sandiford@arm.com>
Date: Tue Sep 20 15:27:47 2022 +0100
aarch64: Fix GTY markup for arm_sve.h [PR106491]
It turns out that GTY(()) markers in definitions like:
GTY(()) tree scalar_types[NUM_VECTOR_TYPES];
are not effective and are silently ignored. The GTY(()) has
to come after an extern or static.
The externs associated with the SVE ACLE GTY variables are in
aarch64-sve-builtins.h. This file is not in tm_include_list because
we don't want every target-facing file to include it. It therefore
isn't in the list of GC header files either.
In this case that's a blessing in disguise, since the variables
belong to a namespace and gengtype doesn't understand namespaces.
I think the fix is instead to add an extra extern before each
variable declaration, similarly to varasm.cc and vtable-verify.cc.
(This works due to a "using namespace" at the end of the file.)
gcc/
PR target/106491
* config/aarch64/aarch64-sve-builtins.cc (scalar_types)
(acle_vector_types, acle_svpattern, acle_svprfop): Add GTY
markup to (new) extern declarations instead of to the main
definition.
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug target/106491] ICE when compiling ArmSVE intrinsics in PCH
2022-07-31 9:09 [Bug c++/106491] New: ICE when compiling ArmSVE intrinsics in PCH denis.yaroshevskij at gmail dot com
` (6 preceding siblings ...)
2022-09-20 14:28 ` cvs-commit at gcc dot gnu.org
@ 2022-09-20 14:30 ` rsandifo at gcc dot gnu.org
2022-09-21 8:30 ` cvs-commit at gcc dot gnu.org
` (4 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: rsandifo at gcc dot gnu.org @ 2022-09-20 14:30 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106491
--- Comment #8 from rsandifo at gcc dot gnu.org <rsandifo at gcc dot gnu.org> ---
Fixed on trunk so far. I'll backport to the release branches soon.
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug target/106491] ICE when compiling ArmSVE intrinsics in PCH
2022-07-31 9:09 [Bug c++/106491] New: ICE when compiling ArmSVE intrinsics in PCH denis.yaroshevskij at gmail dot com
` (7 preceding siblings ...)
2022-09-20 14:30 ` rsandifo at gcc dot gnu.org
@ 2022-09-21 8:30 ` cvs-commit at gcc dot gnu.org
2022-09-21 8:44 ` denis.yaroshevskij at gmail dot com
` (3 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-09-21 8:30 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106491
--- Comment #9 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-12 branch has been updated by Richard Sandiford
<rsandifo@gcc.gnu.org>:
https://gcc.gnu.org/g:a1465af240ee28fc7fcb83877c6aea94f11fb32f
commit r12-8779-ga1465af240ee28fc7fcb83877c6aea94f11fb32f
Author: Richard Sandiford <richard.sandiford@arm.com>
Date: Wed Sep 21 09:30:31 2022 +0100
aarch64: Fix GTY markup for arm_sve.h [PR106491]
It turns out that GTY(()) markers in definitions like:
GTY(()) tree scalar_types[NUM_VECTOR_TYPES];
are not effective and are silently ignored. The GTY(()) has
to come after an extern or static.
The externs associated with the SVE ACLE GTY variables are in
aarch64-sve-builtins.h. This file is not in tm_include_list because
we don't want every target-facing file to include it. It therefore
isn't in the list of GC header files either.
In this case that's a blessing in disguise, since the variables
belong to a namespace and gengtype doesn't understand namespaces.
I think the fix is instead to add an extra extern before each
variable declaration, similarly to varasm.cc and vtable-verify.cc.
(This works due to a "using namespace" at the end of the file.)
gcc/
PR target/106491
* config/aarch64/aarch64-sve-builtins.cc (scalar_types)
(acle_vector_types, acle_svpattern, acle_svprfop): Add GTY
markup to (new) extern declarations instead of to the main
definition.
(cherry picked from commit 6bf5a704d36243c4c04b17a9408ebe881beb0051)
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug target/106491] ICE when compiling ArmSVE intrinsics in PCH
2022-07-31 9:09 [Bug c++/106491] New: ICE when compiling ArmSVE intrinsics in PCH denis.yaroshevskij at gmail dot com
` (8 preceding siblings ...)
2022-09-21 8:30 ` cvs-commit at gcc dot gnu.org
@ 2022-09-21 8:44 ` denis.yaroshevskij at gmail dot com
2022-09-21 13:17 ` cvs-commit at gcc dot gnu.org
` (2 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: denis.yaroshevskij at gmail dot com @ 2022-09-21 8:44 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106491
--- Comment #10 from Denis Yaroshevskiy <denis.yaroshevskij at gmail dot com> ---
Thank you for fixing this
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug target/106491] ICE when compiling ArmSVE intrinsics in PCH
2022-07-31 9:09 [Bug c++/106491] New: ICE when compiling ArmSVE intrinsics in PCH denis.yaroshevskij at gmail dot com
` (9 preceding siblings ...)
2022-09-21 8:44 ` denis.yaroshevskij at gmail dot com
@ 2022-09-21 13:17 ` cvs-commit at gcc dot gnu.org
2022-09-21 13:17 ` cvs-commit at gcc dot gnu.org
2022-09-21 13:19 ` rsandifo at gcc dot gnu.org
12 siblings, 0 replies; 14+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-09-21 13:17 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106491
--- Comment #11 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-11 branch has been updated by Richard Sandiford
<rsandifo@gcc.gnu.org>:
https://gcc.gnu.org/g:c77cd8d782d65864fb7f13119a1e88cb79cfcd9f
commit r11-10266-gc77cd8d782d65864fb7f13119a1e88cb79cfcd9f
Author: Richard Sandiford <richard.sandiford@arm.com>
Date: Wed Sep 21 14:17:15 2022 +0100
aarch64: Fix GTY markup for arm_sve.h [PR106491]
It turns out that GTY(()) markers in definitions like:
GTY(()) tree scalar_types[NUM_VECTOR_TYPES];
are not effective and are silently ignored. The GTY(()) has
to come after an extern or static.
The externs associated with the SVE ACLE GTY variables are in
aarch64-sve-builtins.h. This file is not in tm_include_list because
we don't want every target-facing file to include it. It therefore
isn't in the list of GC header files either.
In this case that's a blessing in disguise, since the variables
belong to a namespace and gengtype doesn't understand namespaces.
I think the fix is instead to add an extra extern before each
variable declaration, similarly to varasm.cc and vtable-verify.cc.
(This works due to a "using namespace" at the end of the file.)
gcc/
PR target/106491
* config/aarch64/aarch64-sve-builtins.cc (scalar_types)
(acle_vector_types, acle_svpattern, acle_svprfop): Add GTY
markup to (new) extern declarations instead of to the main
definition.
(cherry picked from commit 6bf5a704d36243c4c04b17a9408ebe881beb0051)
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug target/106491] ICE when compiling ArmSVE intrinsics in PCH
2022-07-31 9:09 [Bug c++/106491] New: ICE when compiling ArmSVE intrinsics in PCH denis.yaroshevskij at gmail dot com
` (10 preceding siblings ...)
2022-09-21 13:17 ` cvs-commit at gcc dot gnu.org
@ 2022-09-21 13:17 ` cvs-commit at gcc dot gnu.org
2022-09-21 13:19 ` rsandifo at gcc dot gnu.org
12 siblings, 0 replies; 14+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-09-21 13:17 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106491
--- Comment #12 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-10 branch has been updated by Richard Sandiford
<rsandifo@gcc.gnu.org>:
https://gcc.gnu.org/g:c3fda946dedbb08df8eb46bb0120938c08f09742
commit r10-10996-gc3fda946dedbb08df8eb46bb0120938c08f09742
Author: Richard Sandiford <richard.sandiford@arm.com>
Date: Wed Sep 21 14:17:43 2022 +0100
aarch64: Fix GTY markup for arm_sve.h [PR106491]
It turns out that GTY(()) markers in definitions like:
GTY(()) tree scalar_types[NUM_VECTOR_TYPES];
are not effective and are silently ignored. The GTY(()) has
to come after an extern or static.
The externs associated with the SVE ACLE GTY variables are in
aarch64-sve-builtins.h. This file is not in tm_include_list because
we don't want every target-facing file to include it. It therefore
isn't in the list of GC header files either.
In this case that's a blessing in disguise, since the variables
belong to a namespace and gengtype doesn't understand namespaces.
I think the fix is instead to add an extra extern before each
variable declaration, similarly to varasm.cc and vtable-verify.cc.
(This works due to a "using namespace" at the end of the file.)
gcc/
PR target/106491
* config/aarch64/aarch64-sve-builtins.cc (scalar_types)
(acle_vector_types, acle_svpattern, acle_svprfop): Add GTY
markup to (new) extern declarations instead of to the main
definition.
(cherry picked from commit 6bf5a704d36243c4c04b17a9408ebe881beb0051)
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug target/106491] ICE when compiling ArmSVE intrinsics in PCH
2022-07-31 9:09 [Bug c++/106491] New: ICE when compiling ArmSVE intrinsics in PCH denis.yaroshevskij at gmail dot com
` (11 preceding siblings ...)
2022-09-21 13:17 ` cvs-commit at gcc dot gnu.org
@ 2022-09-21 13:19 ` rsandifo at gcc dot gnu.org
12 siblings, 0 replies; 14+ messages in thread
From: rsandifo at gcc dot gnu.org @ 2022-09-21 13:19 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106491
rsandifo at gcc dot gnu.org <rsandifo at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Resolution|--- |FIXED
Status|ASSIGNED |RESOLVED
--- Comment #13 from rsandifo at gcc dot gnu.org <rsandifo at gcc dot gnu.org> ---
Fix on trunk and release branches.
^ permalink raw reply [flat|nested] 14+ messages in thread
end of thread, other threads:[~2022-09-21 13:19 UTC | newest]
Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-31 9:09 [Bug c++/106491] New: ICE when compiling ArmSVE intrinsics in PCH denis.yaroshevskij at gmail dot com
2022-07-31 9:15 ` [Bug target/106491] " pinskia at gcc dot gnu.org
2022-07-31 19:26 ` pinskia at gcc dot gnu.org
2022-07-31 19:33 ` pinskia at gcc dot gnu.org
2022-08-01 10:19 ` denis.yaroshevskij at gmail dot com
2022-08-01 22:29 ` denis.yaroshevskij at gmail dot com
2022-09-15 15:15 ` rsandifo at gcc dot gnu.org
2022-09-20 14:28 ` cvs-commit at gcc dot gnu.org
2022-09-20 14:30 ` rsandifo at gcc dot gnu.org
2022-09-21 8:30 ` cvs-commit at gcc dot gnu.org
2022-09-21 8:44 ` denis.yaroshevskij at gmail dot com
2022-09-21 13:17 ` cvs-commit at gcc dot gnu.org
2022-09-21 13:17 ` cvs-commit at gcc dot gnu.org
2022-09-21 13:19 ` 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).