https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97144
Bug ID: 97144 Summary: [10/11 Regression] SVE: ICE (could not split insn) in final_scan_insn_1 since r10-2553-g0fdc30bcf56 Product: gcc Version: 11.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: target Assignee: unassigned at gcc dot gnu.org Reporter: acoplan at gcc dot gnu.org Target Milestone: --- For the following testcase: int a, b = 5, c = 3; char d; char e[1]; int f[] = {0, 0, 1}; short g; char *h = e; void i(void) { b = a; } static void j(void) { h = e; if (f[2]) k: for (;;) { for (c = 0; c <= 4; c++) { for (g = 0; g <= 4; g++) f[g + 4] &= 2; } if (d) goto k; } } void l(void) { j(); c = 0; } AArch64 GCC ICEs at -O2 -ftree-vectorize -march=armv8.2-a+sve since r10-2553-g0fdc30bcf56d7b46122d7e67d61b56c0a198f3b3: commit 0fdc30bcf56d7b46122d7e67d61b56c0a198f3b3 Author: Richard Sandiford <richard.sandif...@arm.com> Date: Thu Aug 15 09:47:25 2019 [AArch64] Rework SVE INC/DEC handling To reproduce: $ aarch64-none-elf-gcc -c -S -O2 -ftree-vectorize -march=armv8.2-a+sve test.c test.c: In function 'l': test.c:24:1: error: could not split insn 24 | } | ^ (insn:TI 29 28 36 (set (reg/f:DI 0 x0 [orig:96 _17 ] [96]) (plus:DI (reg/f:DI 0 x0 [139]) (const_poly_int:DI [48, 16]))) 124 {*adddi3_poly_1} (expr_list:REG_EQUIV (const:DI (plus:DI (symbol_ref:DI ("*.LANCHOR0") [flags 0x182]) (const_poly_int:DI [48, 16]))) (nil))) during RTL pass: final test.c:24:1: internal compiler error: in final_scan_insn_1, at final.c:3073 0xcf91a3 _fatal_insn(char const*, rtx_def const*, char const*, int, char const*) /home/alecop01/toolchain/src/gcc/gcc/rtl-error.c:108 0x9b4026 final_scan_insn_1 /home/alecop01/toolchain/src/gcc/gcc/final.c:3073 0x9b414d final_scan_insn(rtx_insn*, _IO_FILE*, int, int, int*) /home/alecop01/toolchain/src/gcc/gcc/final.c:3152 0x9b4d66 final_1 /home/alecop01/toolchain/src/gcc/gcc/final.c:2020 0x9b50c4 rest_of_handle_final /home/alecop01/toolchain/src/gcc/gcc/final.c:4658 0x9b50c4 execute /home/alecop01/toolchain/src/gcc/gcc/final.c:4736 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.