diff options
author | Richard Biener <rguenther@suse.de> | 2022-12-05 16:03:21 +0100 |
---|---|---|
committer | Richard Biener <rguenther@suse.de> | 2022-12-05 16:50:49 +0100 |
commit | 0d14720f93a8139a7f234b2762c361e8e5da99cc (patch) | |
tree | 63623322b3af2ad46092c9fe0c5397cae23d751e /gcc/c | |
parent | d492d50f644811327c5976e2c918ab6d906ed40c (diff) | |
download | gcc-0d14720f93a8139a7f234b2762c361e8e5da99cc.zip gcc-0d14720f93a8139a7f234b2762c361e8e5da99cc.tar.gz gcc-0d14720f93a8139a7f234b2762c361e8e5da99cc.tar.bz2 |
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.
Diffstat (limited to 'gcc/c')
0 files changed, 0 insertions, 0 deletions