[Bug tree-optimization/40635] [12/13 Regression] bogus name and location in 'may be used uninitialized' warning
cvs-commit at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Mon Dec 5 15:51:10 GMT 2022
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=40635
--- Comment #27 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Richard Biener <rguenth@gcc.gnu.org>:
https://gcc.gnu.org/g:0d14720f93a8139a7f234b2762c361e8e5da99cc
commit r13-4495-g0d14720f93a8139a7f234b2762c361e8e5da99cc
Author: Richard Biener <rguenther@suse.de>
Date: Mon Dec 5 16:03:21 2022 +0100
middle-end/40635 - SSA update losing PHI arg loations
The following fixes an issue where SSA update loses PHI argument
locations when updating PHI nodes it didn't create as part of the
SSA update. For the case where the reaching def is the same as
the current argument opt to do nothing and for the case where the
PHI argument already has a location keep that (that's an indication
the PHI node wasn't created as part of the update SSA process).
PR middle-end/40635
* tree-into-ssa.cc (rewrite_update_phi_arguments): Only
update the argument when the reaching definition is different
from the current argument. Keep an existing argument
location.
* gcc.dg/uninit-pr40635.c: New testcase.
More information about the Gcc-bugs
mailing list