https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112887
Bug ID: 112887
Summary: during GIMPLE pass: phiopt ICE: Floating point
exception (SIGFPE) at tree-ssa-phiopt.c:2224 with
--param=l1-cache-line-size=0x20000000
Product: gcc
Version: 14.0
Status: UNCONFIRMED
Keywords: ice-on-valid-code
Severity: normal
Priority: P3
Component: tree-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 56819
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=56819&action=edit
reduced testcase
Compiler output:
$ x86_64-pc-linux-gnu-gcc -O2 --param=l1-cache-line-size=0x20000000 testcase.c
testcase.c: In function 'foo':
testcase.c:11:1: internal compiler error: Floating point exception
foo (void)
^~~
0xb8d28f crash_signal
/repo/gcc-6-branch/gcc/toplev.c:333
0xd0df7b hoist_adjacent_loads
/repo/gcc-6-branch/gcc/tree-ssa-phiopt.c:2224
0xd0ec46 tree_ssa_phiopt_worker
/repo/gcc-6-branch/gcc/tree-ssa-phiopt.c:251
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <http://gcc.gnu.org/bugs.html> for instructions.
There is a division by zero, since param_align_bits == 0:
...
int param_align = param_l1_cache_line_size;
unsigned param_align_bits = (unsigned) (param_align * BITS_PER_UNIT);
...