https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118878
Bug ID: 118878 Summary: [ice][avr] internal compiler error: in avr_out_plus_1, at config/avr/avr.cc:8801 Product: gcc Version: 15.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: other Assignee: unassigned at gcc dot gnu.org Reporter: gjl at gcc dot gnu.org Target Milestone: --- Created attachment 60499 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=60499&action=edit C test case The attached test case ICEs with $ avr-gcc read-dw.c -S -mmcu=atmega8 -Os during RTL pass: shorten dump file: read-dw.c.361r.shorten read-dw.c: In function 'test': read-dw.c:59:1: internal compiler error: in avr_out_plus_1, at config/avr/avr.cc:8801 Reason is the following insn: (insn 84 25 122 (parallel [ (set (reg:SI 20 r20 [orig:63 pf_14 ] [63]) (plus:SI (reg:SI 20 r20 [orig:61 _3 ] [61]) (reg:SI 22 r22 [orig:56 __tmp ] [56]))) (clobber (scratch:QI)) (clobber (reg:CC 36 cc)) ]) "read-dw.c":56:17 219 {*addsi3} for which avr.cc::avr_out_plus_1() decides that such an overlap makes no sense: if (reg_overlap_mentioned_p (xop[0], xop[2])) { gcc_assert (REGNO (xop[0]) == REGNO (xop[2])); Target: avr Configured with: ../../source/gcc-master/configure --target=avr --disable-nls --with-dwarf2 --with-gnu-as --with-gnu-ld --with-long-double=64 --disable-libcc1 --disable-shared --enable-languages=c,c++ Thread model: single Supported LTO compression algorithms: zlib gcc version 15.0.1 20250212 (experimental) (GCC)