[Bug tree-optimization/125776] [15 Regression] compare debug fail building gettext/intl on x86_64 / aarch64 since r17-1507 (and since r15-4503)
cvs-commit at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Wed Jun 17 03:48:28 GMT 2026
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=125776
--- Comment #12 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-15 branch has been updated by Andrew Pinski
<pinskia@gcc.gnu.org>:
https://gcc.gnu.org/g:01c1d6287100f08b68164e1dff715d078c848609
commit r15-11291-g01c1d6287100f08b68164e1dff715d078c848609
Author: Andrew Pinski <andrew.pinski@oss.qualcomm.com>
Date: Sat Jun 13 09:38:08 2026 -0700
phiopt: Fix is_factor_profitable for debug stmts [PR125776]
This is a latent bug in is_factor_profitable where we would
consider a debug statement as an use for lifetime usage
afterwards. So you would get a compare debug failure in some
cases. pr125776-2.c fails since r15-4503-g8d6d6d537fdc75.
Pushed as obvious after a bootstrap/test.
Note this is slightly modifed from the trunk version since
the loop is slightly different.
PR tree-optimization/125776
gcc/ChangeLog:
* tree-ssa-phiopt.cc (is_factor_profitable): An
usage in a debug stmt should be ignored.
gcc/testsuite/ChangeLog:
* gcc.dg/torture/pr125776-1.c: New test.
* gcc.dg/torture/pr125776-2.c: New test.
Signed-off-by: Andrew Pinski <andrew.pinski@oss.qualcomm.com>
(cherry picked from commit a4afea80fce5f1aafdd1174e48e9ebfc9ec8155d)
More information about the Gcc-bugs
mailing list