https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85034
Bug ID: 85034
Summary: -O1 internal compiler error: in
elimination_costs_in_insn, at reload1.c:3633
Product: gcc
Version: 8.0.1
Status: UNCONFIRMED
Keywords: ice-on-invalid-code
Severity: normal
Priority: P3
Component: inline-asm
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at oracle dot com
CC: webrown.cpp at gmail dot com
Target Milestone: ---
Input:
void b() {
volatile float a;
asm("" : "=d"(a) : "0Ir"([] {}));
}
Output:
$ cc1plus -O1
void b() b()::<lambda()> static void b()::<lambda()>::_FUN()
b()::<lambda()>::operator void (*)()() const
Analyzing compilation unit
Performing interprocedural optimizations
<*free_lang_data> <visibility> <build_ssa_passes> <opt_local_passes>
<targetclone> <free-fnsummary> <whole-program> <profile_estimate> <fnsummary>
<inline> <pure-const> <free-fnsummary> <static-var> <single-use>
<comdats>Assembling functions:
<materialize-all-clones> <simdclone> void b()during RTL pass: ira
<stdin>: In function 'void b()':
<stdin>:4:1: internal compiler error: in elimination_costs_in_insn, at
reload1.c:3633
0x2e67ee7 elimination_costs_in_insn
/home/vegard/git/gcc/gcc/reload1.c:3630
0x2ea41cf calculate_elim_costs_all_insns()
/home/vegard/git/gcc/gcc/reload1.c:1607
0x26cd174 ira_costs()
/home/vegard/git/gcc/gcc/ira-costs.c:2249
0x2687568 ira_build()
/home/vegard/git/gcc/gcc/ira-build.c:3427
0x2640c54 ira
/home/vegard/git/gcc/gcc/ira.c:5295
0x2640c54 execute
/home/vegard/git/gcc/gcc/ira.c:5606
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.
Version:
GNU C++14 (GCC) version 8.0.1 20180306 (experimental) (x86_64-pc-linux-gnu)
Error message looks similar to #50092 and #83926 and a few others, but they are
all supposed to be fixed. Could also be the same as (and fixed by) #84164 but
that's aarch64 and the test case looks quite different (no inline asm). Trunk
on godbolt.org (20180321) also crashes.