[Bug middle-end/125621] ICE in build_poly_int_cst with SVE svcntd () and -fsanitize=undefined
cvs-commit at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Wed Jun 17 15:00:09 GMT 2026
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=125621
--- Comment #7 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-15 branch has been updated by Alex Coplan
<acoplan@gcc.gnu.org>:
https://gcc.gnu.org/g:4a1db6ebe186ecb7a5def509c0a4a5741b5eefbd
commit r15-11297-g4a1db6ebe186ecb7a5def509c0a4a5741b5eefbd
Author: Alex Coplan <alex.coplan@arm.com>
Date: Fri Jun 5 16:51:47 2026 +0100
expmed: Fix up CONST_POLY_INT case of make_tree [PR125621]
The PR showed us ICEing in build_poly_int_cst because we have type set
to a non-type tree node (a var_decl). A closer look shows this is
because we pass the wrong variable to wide_int_to_tree in
expmed.cc:make_tree: we pass t instead of type, where t is
uninitialized at the point of the call. Fixed thusly.
I also took the opportunity to move the CONST_POLY_INT case out of the
default: section into its own case of the switch.
gcc/ChangeLog:
PR middle-end/125621
* expmed.cc (make_tree): Fix CONST_POLY_INT case to pass type
instead of t, move it to its own switch case.
gcc/testsuite/ChangeLog:
PR middle-end/125621
* gcc.target/aarch64/torture/pr125621.c: New test.
(cherry picked from commit 06193eabd2b787bd3815d99b08b1c8b18ca800ea)
More information about the Gcc-bugs
mailing list