https://gcc.gnu.org/bugzilla/show_bug.cgi?id=123276
Bug ID: 123276
Summary: [16 regression] ICE when building GNAT (RTL check:
expected code 'const_double' and not mode 'VOID', have
code 'const_int' and mode 'VOID' in
compress_float_constant, at expr.cc:4786)
Product: gcc
Version: 16.0
Status: UNCONFIRMED
Keywords: build, ice-checking, rtl-checking
Severity: normal
Priority: P3
Component: rtl-optimization
Assignee: unassigned at gcc dot gnu.org
Reporter: sjames at gcc dot gnu.org
Target Milestone: ---
```
make[7]: Entering directory
'/var/tmp/portage/sys-devel/gcc-16.0.9999/work/build/gcc/ada/rts'
/var/tmp/portage/sys-devel/gcc-16.0.9999/work/build/./gcc/xgcc
-B/var/tmp/portage/sys-devel/gcc-16.0.9999/work/build/./gcc/
-B/usr/x86_64-pc-linux-gnu/bin/ -B/usr/x86_64-pc-linux-gnu/lib/ -isystem
/usr/x86_64-pc-linux-gnu/include -isystem /usr/x86_64-pc-linux-gnu/sys-include
-fchecking=1 -c -g -O2 -fpic -fno-lto -W -Wall -gnatpg -nostdinc
s-rannum.adb -o s-rannum.o
during RTL pass: ce1
+===========================GNAT BUG DETECTED==============================+
| 16.0.0 20251223 (experimental) 4d02f20772f170b78491769a78086c92de127f95
(x86_64-pc-linux-gnu) GCC error:|
| RTL check: expected code 'const_double' and not mode 'VOID', have |
| code 'const_int' and mode 'VOID' in compress_float_constant, at
expr.cc:4786|
| Error detected around s-rannum.adb:378:8 |
| Compiling s-rannum.adb |
| Please submit a bug report; see https://gcc.gnu.org/bugs/ . |
| Use a subject line meaningful to you and us to track the bug. |
| Include the entire contents of this bug box in the report. |
| Include the exact command that you entered. |
| Also include sources listed below. |
+==========================================================================+
Please include these source files with error report
Note that list may not be accurate in some cases,
so please double check that the problem can still
be reproduced with the set of files listed.
Consider also -gnatd.n switch (see debug.adb).
system.ads
s-rannum.adb
s-rannum.ads
interfac.ads
ada.ads
a-string.ads
a-sttebu.ads
a-stuten.ads
a-unccon.ads
s-ransee.ads
s-stalib.ads
s-exctab.ads
a-tags.ads
s-stoele.ads
s-soflin.ads
a-except.ads
s-parame.ads
s-traent.ads
s-secsta.ads
s-stache.ads
s-unstyp.ads
s-imguns.ads
s-imageu.ads
s-valuns.ads
s-valueu.ads
raised TYPES.UNRECOVERABLE_ERROR : comperr.adb:422
make[7]: *** [../gcc-interface/Makefile:296: s-rannum.o] Error 1
make[7]: Leaving directory
'/var/tmp/portage/sys-devel/gcc-16.0.9999/work/build/gcc/ada/rts'
```
```
/var/tmp/portage/sys-devel/gcc-16.0.9999/work/build/gcc/ada/rts $ ../../xgcc -v
Using built-in specs.
COLLECT_GCC=../../xgcc
OFFLOAD_TARGET_NAMES=nvptx-none
OFFLOAD_TARGET_DEFAULT=1
Target: x86_64-pc-linux-gnu
Configured with:
/var/tmp/portage/sys-devel/gcc-16.0.9999/work/gcc-16.0.9999/configure
--host=x86_64-pc-linux-gnu --build=x86_64-pc-linux-gnu --prefix=/usr
--bindir=/usr/x86_64-pc-linux-gnu/gcc-bin/16
--includedir=/usr/lib/gcc/x86_64-pc-linux-gnu/16/include
--datadir=/usr/share/gcc-data/x86_64-pc-linux-gnu/16
--mandir=/usr/share/gcc-data/x86_64-pc-linux-gnu/16/man
--infodir=/usr/share/gcc-data/x86_64-pc-linux-gnu/16/info
--with-gxx-include-dir=/usr/lib/gcc/x86_64-pc-linux-gnu/16/include/g++-v16
--disable-silent-rules --disable-dependency-tracking
--with-python-dir=/share/gcc-data/x86_64-pc-linux-gnu/16/python
--enable-libphobos --enable-languages=c,c++,d,fortran,ada,jit --enable-obsolete
--enable-secureplt --disable-werror --with-system-zlib --enable-nls
--without-included-gettext --disable-libunwind-exceptions
--enable-checking=yes,extra,rtl --with-bugurl=https://bugs.gentoo.org/
--with-pkgversion='Gentoo Hardened 16.0.9999 p, commit
329fe436906e90cbe1d2f787ad5a282160589518' --with-gcc-major-version-only
--enable-libstdcxx-time --enable-lto --disable-libstdcxx-pch --enable-shared
--enable-threads=posix --enable-__cxa_atexit --enable-clocale=gnu
--with-tls=gnu2 --enable-multilib --with-multilib-list=m32,m64
--disable-fixed-point --enable-targets=all --enable-offload-defaulted
--enable-offload-targets=nvptx-none --enable-libgomp --disable-libssp
--enable-libada --enable-cet --enable-systemtap --disable-valgrind-annotations
--disable-valgrind-interop --disable-vtable-verify --disable-libvtv --with-zstd
--without-isl --enable-default-pie --enable-host-pie --enable-host-bind-now
--enable-default-ssp --disable-fixincludes
--with-gxx-libcxx-include-dir=/usr/include/c++/v1 --enable-host-shared
--enable-libgdiagnostics --enable-linker-build-id
--with-build-config='bootstrap-O3 bootstrap-cet'
Thread model: posix
Supported LTO compression algorithms: zlib zstd
gcc version 16.0.0 20251223 (experimental)
4d02f20772f170b78491769a78086c92de127f95 (Gentoo Hardened 16.0.9999 p, commit
329fe436906e90cbe1d2f787ad5a282160589518)
```