https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96734
Bug ID: 96734 Summary: gcc 10.2.0 fails to compile on mips64 due to crash in IPA SRA pass Product: gcc Version: 10.2.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: ipa Assignee: unassigned at gcc dot gnu.org Reporter: ariadne at dereferenced dot org CC: marxin at gcc dot gnu.org Target Milestone: --- When building gcc 10.2.0 using previous gcc 9.3.0 on a mips64 host, gcc 10.2.0 crashes while building stage3: during IPA pass: sra In file included from /home/buildozer/aports/main/gcc/src/gcc-10.2.0/gcc/cp/method.c:3199: ./gt-cp-method.h:36:2: internal compiler error: Segmentation fault 36 | }; | ^ 0x1208017a3 crash_signal /home/buildozer/aports/main/gcc/src/gcc-10.2.0/gcc/toplev.c:328 0x12041ef55 cgraph_edge::redirect_callee(cgraph_node*) /home/buildozer/aports/main/gcc/src/gcc-10.2.0/gcc/cgraph.c:1374 0x120431cd3 cgraph_edge::redirect_callee_duplicating_thunks(cgraph_node*) /home/buildozer/aports/main/gcc/src/gcc-10.2.0/gcc/cgraphclones.c:262 0x120432167 cgraph_node::create_clone(tree_node*, profile_count, bool, vec<cgraph_edge*, va_heap, vl_ptr>, bool, cgraph_node*, ipa_param_adjustments*, char const*) /home/buildozer/aports/main/gcc/src/gcc-10.2.0/gcc/cgraphclones.c:427 0x12043258b cgraph_node::create_virtual_clone(vec<cgraph_edge*, va_heap, vl_ptr>, vec<ipa_replace_map*, va_gc, vl_embed>*, ipa_param_adjustments*, char const*, unsigned int) /home/buildozer/aports/main/gcc/src/gcc-10.2.0/gcc/cgraphclones.c:613 0x1205eba27 process_isra_node_results /home/buildozer/aports/main/gcc/src/gcc-10.2.0/gcc/ipa-sra.c:3811 0x1205eba27 ipa_sra_analysis /home/buildozer/aports/main/gcc/src/gcc-10.2.0/gcc/ipa-sra.c:4047 0x1205eba27 execute /home/buildozer/aports/main/gcc/src/gcc-10.2.0/gcc/ipa-sra.c:4099 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. Full log of building cp/method.o: https://distfiles.dereferenced.org/method.log method.ii: https://distfiles.dereferenced.org/method.ii Unfortunately I wouldn't know where to begin creating a reduced test case for this. Sorry. I suspect the issue is because `caller` is null, which means to->check_calls_comdat_local_p() does a null dereference when trying to fetch the vtable. But I could be wrong entirely. :)