https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112679
Bug ID: 112679 Summary: ICE in expand_float, at optabs.cc:5724 with bitint Product: gcc Version: 14.0 Status: UNCONFIRMED Keywords: ice-on-valid-code Severity: normal Priority: P3 Component: middle-end Assignee: unassigned at gcc dot gnu.org Reporter: mjires at suse dot cz CC: jakub at redhat dot com Target Milestone: --- Compiling testsuite/gcc.dg/bitint-35.c ICE since initial commits - r14-3751-g8c984a1c3693df. $ gcc bitint-35.c -frounding-math bitint-35.c: In function ‘foo’: bitint-35.c:12:19: warning: overflow in conversion from ‘_BitInt(30)’ to ‘_BitInt(27)’ changes value from ‘-390288573’ to ‘12364611’ [-Woverflow] 12 | _BitInt(27) d = -390288573wb; /* { dg-warning "overflow in conversion from '_BitInt\\\(30\\\)' to '_BitInt\\\(27\\\)' changes value from '-390288573' to '12364611'" } */ | ^ bitint-35.c:13:28: warning: conversion from ‘unsigned _BitInt(29)’ to ‘unsigned _BitInt(27)’ changes value from ‘309641337’ to ‘41205881’ [-Woverflow] 13 | unsigned _BitInt(27) e = 309641337uwb; /* { dg-warning "conversion from 'unsigned _BitInt\\\(29\\\)' to 'unsigned _BitInt\\\(27\\\)' changes value from '309641337' to '41205881'" } */ | ^~~~~~~~~~~~ bitint-35.c:16:19: warning: overflow in conversion from ‘int’ to ‘_BitInt(27)’ changes value from ‘-390288573’ to ‘12364611’ [-Woverflow] 16 | _BitInt(27) h = -390288573; /* { dg-warning "overflow in conversion from 'int' to '_BitInt\\\(27\\\)' changes value from '-390288573' to '12364611'" } */ | ^ bitint-35.c:17:28: warning: conversion from ‘unsigned int’ to ‘unsigned _BitInt(27)’ changes value from ‘309641337’ to ‘41205881’ [-Woverflow] 17 | unsigned _BitInt(27) i = 309641337U; /* { dg-warning "conversion from 'unsigned int' to 'unsigned _BitInt\\\(27\\\)' changes value from '309641337' to '41205881'" } */ | ^~~~~~~~~~ bitint-35.c:20:11: warning: overflow in conversion from ‘_BitInt(64)’ to ‘int’ changes value from ‘-8087431137529383656’ to ‘-1105152744’ [-Woverflow] 20 | int l = -8087431137529383656wb; /* { dg-warning "overflow in conversion from '_BitInt\\\(64\\\)' to 'int' changes value from '-8087431137529383656' to '-1105152744'" } */ | ^ bitint-35.c:21:20: warning: conversion from ‘unsigned _BitInt(61)’ to ‘unsigned int’ changes value from ‘1664073919553255778’ to ‘3338058082’ [-Woverflow] 21 | unsigned int m = 1664073919553255778uwb; /* { dg-warning "conversion from 'unsigned _BitInt\\\(61\\\)' to 'unsigned int' changes value from '1664073919553255778' to '3338058082'" } */ | ^~~~~~~~~~~~~~~~~~~~~~ during RTL pass: expand bitint-35.c:23:12: internal compiler error: in expand_float, at optabs.cc:5729 23 | _Float32 n = 51441631083309184313435496923626431699697406185384986811300218556561965470218425783308778801748592322915101142266821623326688106425864884688172114173397118407357447763009120wb; /* { dg-warning "conversion from '_BitInt\\\(575\\\)' to '_Float32' changes value from '0x353eab28b46b03ea99b84f9736cd8dbe5e986915a0383c3cb381c0da41e31b3621c75fd53262bfcb1b0e6251dbf00f3988784e29b08b65640c263e4d0959832a20e2ff5245be1e60' to '\\\+Inff32'" "" { target bitint575 } } */ | ^ 0x7e2b67 expand_float(rtx_def*, rtx_def*, int) /home/mjires/git/GCC/master/gcc/optabs.cc:5729 0xc06bc8 expand_expr_real_2(separate_ops*, rtx_def*, machine_mode, expand_modifier) /home/mjires/git/GCC/master/gcc/expr.cc:9945 0xae0440 expand_gimple_stmt_1 /home/mjires/git/GCC/master/gcc/cfgexpand.cc:3983 0xae0440 expand_gimple_stmt /home/mjires/git/GCC/master/gcc/cfgexpand.cc:4044 0xae65f6 expand_gimple_basic_block /home/mjires/git/GCC/master/gcc/cfgexpand.cc:6100 0xae7f36 execute /home/mjires/git/GCC/master/gcc/cfgexpand.cc:6835 Please submit a full bug report, with preprocessed source (by using -freport-bug). Please include the complete backtrace with any bug report. See <https://gcc.gnu.org/bugs/> for instructions. $ gcc -v Using built-in specs. COLLECT_GCC=gcc COLLECT_LTO_WRAPPER=/home/mjires/built/master/libexec/gcc/x86_64-pc-linux-gnu/14.0.0/lto-wrapper Target: x86_64-pc-linux-gnu Configured with: /home/mjires/git/GCC/master/configure --prefix=/home/mjires/built/master --disable-bootstrap --enable-checking --enable-languages=c,c++,fortran,lto Thread model: posix Supported LTO compression algorithms: zlib zstd gcc version 14.0.0 20231123 (experimental) (GCC)