https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103171
Bug ID: 103171
Summary: [12 Regression] ICE Segmentation fault since
r12-2523-g13586172d0b70c9d
Product: gcc
Version: 12.0
Status: UNCONFIRMED
Keywords: ice-on-valid-code
Severity: normal
Priority: P3
Component: ipa
Assignee: unassigned at gcc dot gnu.org
Reporter: marxin at gcc dot gnu.org
CC: jamborm at gcc dot gnu.org, marxin at gcc dot gnu.org
Target Milestone: ---
Created attachment 51756
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=51756&action=edit
test-case
The following (reduced from Löve game engine:
$ g++ *.ii -O2 -flto=auto -flto-partition=1to1 -w
during GIMPLE pass: fre
1.ii: In function ‘w_isDown’:
1.ii:18:5: internal compiler error: Segmentation fault
18 | int w_isDown(int *) {
| ^
0xdd2f6a crash_signal
/home/marxin/Programming/gcc/gcc/toplev.c:322
0x7ffff789979f ???
/usr/src/debug/glibc-2.34-2.1.x86_64/signal/../sysdeps/unix/sysv/linux/x86_64/libc_sigaction.c:0
0x1b3f8a8 symtab_node::ultimate_alias_target(availability*, symtab_node*)
/home/marxin/Programming/gcc/gcc/cgraph.h:3204
0x1b3f8a8 ipa_reference_var_uid(tree_node*)
/home/marxin/Programming/gcc/gcc/ipa-reference.c:152
0xee588e call_may_clobber_ref_p_1(gcall*, ao_ref*, bool)
/home/marxin/Programming/gcc/gcc/tree-ssa-alias.c:3088
0xee588e call_may_clobber_ref_p_1(gcall*, ao_ref*, bool)
/home/marxin/Programming/gcc/gcc/tree-ssa-alias.c:2968
0xee6170 walk_non_aliased_vuses(ao_ref*, tree_node*, bool, void* (*)(ao_ref*,
tree_node*, void*), void* (*)(ao_ref*, tree_node*, void*, translate_flags*),
tree_node* (*)(tree_node*), unsigned int&, void*)
/home/marxin/Programming/gcc/gcc/tree-ssa-alias.c:3720
0xfba1e7 vn_reference_lookup(tree_node*, tree_node*, vn_lookup_kind,
vn_reference_s**, bool, tree_node**, tree_node*)
/home/marxin/Programming/gcc/gcc/tree-ssa-sccvn.c:3700
0xfbe6ce visit_reference_op_load
/home/marxin/Programming/gcc/gcc/tree-ssa-sccvn.c:5166
0xfbe6ce visit_stmt
/home/marxin/Programming/gcc/gcc/tree-ssa-sccvn.c:5615
0xfbee96 process_bb
/home/marxin/Programming/gcc/gcc/tree-ssa-sccvn.c:7344
0xfc10ce do_rpo_vn
/home/marxin/Programming/gcc/gcc/tree-ssa-sccvn.c:7828
0xfc1f1b execute
/home/marxin/Programming/gcc/gcc/tree-ssa-sccvn.c:8096
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.
make: *** [/tmp/ccO8uvv9.mk:11: /tmp/cc4akvXo.ltrans3.ltrans.o] Error 1
lto-wrapper: fatal error: make returned 2 exit status
compilation terminated.
/usr/bin/ld: fatal error: lto-wrapper failed
collect2: error: ld returned 1 exit status