https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97706
Bug ID: 97706 Summary: [11 Regression] ICE with LTO at -O3: verify_gimple failed (incompatible types in 'PHI' argument 0) Product: gcc Version: 11.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: tree-optimization Assignee: unassigned at gcc dot gnu.org Reporter: acoplan at gcc dot gnu.org Target Milestone: --- Since r11-4428-g4a369d199bf2f34e037030b18d0da923e8a24997 I'm seeing an ICE when compiling the following two (dubious) source files with LTO at -O3 on AArch64: $ cat f1.c void a(_Bool x); void test(char**); int var_19; char **d; _Bool arr_8; int main() { test(d); a(arr_8); return var_19; } $ cat f2.c extern int var_19; extern _Bool arr_8[][6][11]; void test(char **p) { for (int c; c < 9; c++) for (int d = 0; d < 3; d -= 4LL) for (int e = 0; e < 10; e++) { var_19 = 0; arr_8[5][d][e] = p[d][e]; } } $ aarch64-elf-gcc -O3 -flto f1.c f2.c f1.c: In function 'main': f1.c:6:5: error: incompatible types in 'PHI' argument 0 6 | int main() | ^ vector(8) unsigned char vector(8) <signed-boolean:8> vect__29.9_48 = PHI <mask__40.8_55(5)> during GIMPLE pass: slp f1.c:6:5: internal compiler error: verify_gimple failed 0xcd1728 verify_gimple_in_cfg(function*, bool) /home/alecop01/toolchain/src/gcc/gcc/tree-cfg.c:5461 0xb7ea24 execute_function_todo /home/alecop01/toolchain/src/gcc/gcc/passes.c:2039 0xb7ec1e do_per_function /home/alecop01/toolchain/src/gcc/gcc/passes.c:1687 0xb7edb9 execute_todo /home/alecop01/toolchain/src/gcc/gcc/passes.c:2093 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. lto-wrapper: fatal error: aarch64-elf-gcc returned 1 exit status compilation terminated. /home/alecop01/toolchain/build-aarch64-elf/install/lib/gcc/aarch64-elf/11.0.0/../../../../aarch64-elf/bin/ld: error: lto-wrapper failed collect2: error: ld returned 1 exit status