https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116350
Bug ID: 116350 Summary: [15 regression] ICE in expand_fix, at optabs.cc:5948 etc. Product: gcc Version: 15.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: rtl-optimization Assignee: unassigned at gcc dot gnu.org Reporter: ro at gcc dot gnu.org CC: tsamismanolis at gmail dot com Target Milestone: --- Target: i386-pc-solaris2.11, sparc-sun-solaris2.11 Between d0bc1cbf6a8938220f42d8102031fd6f6644e171 and e9738e77674e23f600315ca1efed7d1c7944d0cc, Solaris bootstrap got broken libgo on both sparc and x86: * sparc, building both 32 and 64-bit math.lo: during RTL pass: ce1 /vol/gcc/src/hg/master/local/libgo/go/math/exp.go: In function ‘math.exp2’: /vol/gcc/src/hg/master/local/libgo/go/math/exp.go:147:1: internal compiler error: in expand_fix, at optabs.cc:5948 147 | func exp2(x float64) float64 { | ^ 0x1f113c3 internal_error(char const*, ...) /vol/gcc/src/hg/master/local/gcc/diagnostic-global-context.cc:491 0x1f0317b fancy_abort(char const*, int, char const*) /vol/gcc/src/hg/master/local/gcc/diagnostic.cc:1772 0xe5a153 expand_fix(rtx_def*, rtx_def*, int) /vol/gcc/src/hg/master/local/gcc/optabs.cc:5948 0xaed94b force_operand(rtx_def*, rtx_def*) /vol/gcc/src/hg/master/local/gcc/expr.cc:8708 0xaed763 force_operand(rtx_def*, rtx_def*) /vol/gcc/src/hg/master/local/gcc/expr.cc:8695 0xab576b copy_to_mode_reg(machine_mode, rtx_def*) /vol/gcc/src/hg/master/local/gcc/explow.cc:655 0xe4e2d3 maybe_legitimize_operand /vol/gcc/src/hg/master/local/gcc/optabs.cc:8041 0xe4e2d3 maybe_legitimize_operands(insn_code, unsigned int, unsigned int, expand_operand*) /vol/gcc/src/hg/master/local/gcc/optabs.cc:8184 0xe4ada7 maybe_gen_insn(insn_code, unsigned int, expand_operand*) /vol/gcc/src/hg/master/local/gcc/optabs.cc:8203 0xe4cab7 maybe_expand_insn(insn_code, unsigned int, expand_operand*) /vol/gcc/src/hg/master/local/gcc/optabs.cc:8258 0xe4cab7 emit_conditional_move_1 /vol/gcc/src/hg/master/local/gcc/optabs.cc:5229 0xe4cdff emit_conditional_move(rtx_def*, rtx_comparison, rtx_def*, rtx_def*, machine_mode, int) /vol/gcc/src/hg/master/local/gcc/optabs.cc:5142 0x1d10f0b noce_emit_cmove /vol/gcc/src/hg/master/local/gcc/ifcvt.cc:1773 0x1d17df3 try_emit_cmove_seq /vol/gcc/src/hg/master/local/gcc/ifcvt.cc:3406 0x1d17df3 noce_convert_multiple_sets_1 /vol/gcc/src/hg/master/local/gcc/ifcvt.cc:3687 0x1d1870f noce_convert_multiple_sets /vol/gcc/src/hg/master/local/gcc/ifcvt.cc:3492 0x1d1d4ab noce_process_if_block /vol/gcc/src/hg/master/local/gcc/ifcvt.cc:4025 0x1d1d4ab noce_find_if_block /vol/gcc/src/hg/master/local/gcc/ifcvt.cc:4706 0x1d1d4ab find_if_header /vol/gcc/src/hg/master/local/gcc/ifcvt.cc:4911 0x1d1d4ab if_convert /vol/gcc/src/hg/master/local/gcc/ifcvt.cc:6058 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. make: *** [Makefile:3055: math.lo] Error 1 * x86, building 64-bit time.lo: during RTL pass: ce1 /vol/gcc/src/hg/master/local/libgo/go/time/zoneinfo_read.go: In function ‘time.loadLocation.isra’: /vol/gcc/src/hg/master/local/libgo/go/time/zoneinfo_read.go:531:1: internal compiler error: in expand_simple_binop, at optabs.cc:1264 531 | func loadLocation(name string, sources []string) (z *Location, firstErr error) { | ^ 0xaa758f4 internal_error(char const*, ...) /vol/gcc/src/hg/master/local/gcc/diagnostic-global-context.cc:491 0xaa66d71 fancy_abort(char const*, int, char const*) /vol/gcc/src/hg/master/local/gcc/diagnostic.cc:1772 0x9355e21 expand_simple_binop(machine_mode, rtx_code, rtx_def*, rtx_def*, rtx_def*, int, optab_methods) /vol/gcc/src/hg/master/local/gcc/optabs.cc:1264 0x9355e21 expand_simple_binop(machine_mode, rtx_code, rtx_def*, rtx_def*, rtx_def*, int, optab_methods) /vol/gcc/src/hg/master/local/gcc/optabs.cc:1259 0x9010465 force_operand(rtx_def*, rtx_def*) /vol/gcc/src/hg/master/local/gcc/expr.cc:8687 0x8fe6ae1 copy_to_mode_reg(machine_mode, rtx_def*) /vol/gcc/src/hg/master/local/gcc/explow.cc:655 0x9347dfa maybe_legitimize_operand /vol/gcc/src/hg/master/local/gcc/optabs.cc:8041 0x9347dfa maybe_legitimize_operands(insn_code, unsigned int, unsigned int, expand_operand*) /vol/gcc/src/hg/master/local/gcc/optabs.cc:8184 0x9344932 maybe_gen_insn(insn_code, unsigned int, expand_operand*) /vol/gcc/src/hg/master/local/gcc/optabs.cc:8203 0x934649f maybe_expand_insn(insn_code, unsigned int, expand_operand*) /vol/gcc/src/hg/master/local/gcc/optabs.cc:8258 0x934649f emit_conditional_move_1 /vol/gcc/src/hg/master/local/gcc/optabs.cc:5229 0x934689c emit_conditional_move(rtx_def*, rtx_comparison, rtx_def*, rtx_def*, machine_mode, int) /vol/gcc/src/hg/master/local/gcc/optabs.cc:5142 0xa888e0e noce_emit_cmove /vol/gcc/src/hg/master/local/gcc/ifcvt.cc:1773 0xa88f017 try_emit_cmove_seq /vol/gcc/src/hg/master/local/gcc/ifcvt.cc:3406 0xa88f017 noce_convert_multiple_sets_1 /vol/gcc/src/hg/master/local/gcc/ifcvt.cc:3687 0xa88f613 noce_convert_multiple_sets /vol/gcc/src/hg/master/local/gcc/ifcvt.cc:3492 0xa89461a noce_process_if_block /vol/gcc/src/hg/master/local/gcc/ifcvt.cc:4025 0xa89461a noce_find_if_block /vol/gcc/src/hg/master/local/gcc/ifcvt.cc:4706 0xa89461a find_if_header /vol/gcc/src/hg/master/local/gcc/ifcvt.cc:4911 0xa89461a if_convert /vol/gcc/src/hg/master/local/gcc/ifcvt.cc:6058 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. make: *** [Makefile:3055: time.lo] Error 1 It turned out that this patch commit 72c9b5f438f22cca493b4e2a8a2a31ff61bf1477 Author: Manolis Tsamis <manolis.tsa...@vrull.eu> Date: Fri Jun 30 14:05:15 2023 +0200 ifcvt: Allow more operations in multiple set if conversion is the culprit.