https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83494
Bug ID: 83494 Summary: [8 Regression] ICE: in assign_by_spills, at lra-assigns.c:1468: unable to find a register to spill with -flive-range-shrinkage Product: gcc Version: 8.0 Status: UNCONFIRMED Keywords: ice-on-valid-code Severity: normal Priority: P3 Component: rtl-optimization Assignee: unassigned at gcc dot gnu.org Reporter: zsojka at seznam dot cz Target Milestone: --- Host: x86_64-pc-linux-gnu Target: x86_64-pc-linux-gnu Created attachment 42922 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=42922&action=edit reduced testcase Might be related or duplicate PR83467, but this one does not need any target-specific flags. Compiler output: $ x86_64-pc-linux-gnu-gcc -O2 -flive-range-shrinkage testcase.c testcase.c: In function 'a': testcase.c:8:1: error: unable to find a register to spill } ^ testcase.c:8:1: error: this is the insn: (insn 46 49 6 2 (parallel [ (set (reg:SI 115 [ d ]) (ashift:SI (reg/v:SI 106 [ d ]) (reg:QI 125 [ f ]))) (clobber (reg:CC 17 flags)) ]) "testcase.c":3 540 {*ashlsi3_1} (expr_list:REG_DEAD (reg:QI 125 [ f ]) (expr_list:REG_DEAD (reg/v:SI 106 [ d ]) (expr_list:REG_UNUSED (reg:CC 17 flags) (nil))))) during RTL pass: reload testcase.c:8:1: internal compiler error: in assign_by_spills, at lra-assigns.c:1468 0x696c9a _fatal_insn(char const*, rtx_def const*, char const*, int, char const*) /repo/gcc-trunk/gcc/rtl-error.c:108 0xcf7fba assign_by_spills /repo/gcc-trunk/gcc/lra-assigns.c:1468 0xcf8b1c lra_assign() /repo/gcc-trunk/gcc/lra-assigns.c:1662 0xcf3404 lra(_IO_FILE*) /repo/gcc-trunk/gcc/lra.c:2469 0xca0d99 do_reload /repo/gcc-trunk/gcc/ira.c:5443 0xca0d99 execute /repo/gcc-trunk/gcc/ira.c:5627 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. $ x86_64-pc-linux-gnu-gcc -v Using built-in specs. COLLECT_GCC=/repo/gcc-trunk/binary-latest-amd64/bin/x86_64-pc-linux-gnu-gcc COLLECT_LTO_WRAPPER=/repo/gcc-trunk/binary-trunk-255786-checking-yes-rtl-df-extra-nographite-amd64/bin/../libexec/gcc/x86_64-pc-linux-gnu/8.0.0/lto-wrapper Target: x86_64-pc-linux-gnu Configured with: /repo/gcc-trunk//configure --enable-languages=c,c++ --enable-valgrind-annotations --disable-nls --enable-checking=yes,rtl,df,extra --without-cloog --without-ppl --without-isl --build=x86_64-pc-linux-gnu --host=x86_64-pc-linux-gnu --target=x86_64-pc-linux-gnu --with-ld=/usr/bin/x86_64-pc-linux-gnu-ld --with-as=/usr/bin/x86_64-pc-linux-gnu-as --disable-libstdcxx-pch --prefix=/repo/gcc-trunk//binary-trunk-255786-checking-yes-rtl-df-extra-nographite-amd64 Thread model: posix gcc version 8.0.0 20171218 (experimental) (GCC)