[Bug tree-optimization/123820] [16 Regression] ICE during GIMPLE pass: slsr since r16-7003-gc01ad7a27af
cvs-commit at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Mon Jan 26 19:11:42 GMT 2026
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=123820
--- Comment #3 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The trunk branch has been updated by Andrew Pinski <pinskia@gcc.gnu.org>:
https://gcc.gnu.org/g:d1b30abe52228923ba389173c02c0186d25be1ab
commit r16-7051-gd1b30abe52228923ba389173c02c0186d25be1ab
Author: Andrew Pinski <andrew.pinski@oss.qualcomm.com>
Date: Sun Jan 25 22:23:51 2026 -0800
slsr: Use the correct type to try to convert to for inserting on edge case
[PR123820]
I had noticed there was code that will convert the stride
to the correct type
What I didn't realize was the type which it was trying to
use was stride_type but for this case it should have been using
the type of the lhs. This fixes that oversight. Note for pointers
we still want to use stride_type like what is done right above.
I don't have a testcase that does not use LTO though. I didn't figure
out why this testcase needed LTO though.
Bootstrapped and tested on x86_64-linux-gnu.
PR tree-optimization/123820
gcc/ChangeLog:
* gimple-ssa-strength-reduction.cc (create_add_on_incoming_edge):
Use
the correct type for the stride (lhs if non-pointer).
gcc/testsuite/ChangeLog:
* g++.dg/torture/pr123820-1.C: New test.
Signed-off-by: Andrew Pinski <andrew.pinski@oss.qualcomm.com>
More information about the Gcc-bugs
mailing list