This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
[tree-ssa] copy prop vs. debugging
- From: Jason Merrill <jason at redhat dot com>
- To: "Jeffrey A. Law" <law at redhat dot com>, Andrew MacLeod <amacleod at redhat dot com>, Diego Novillo <dnovillo at redhat dot com>
- Cc: gcc at gcc dot gnu dot org
- Date: Thu, 03 Jul 2003 11:16:35 -0400
- Subject: [tree-ssa] copy prop vs. debugging
When a temporary is copied into a variable, any dominated uses of that
variable are replaced with uses of the temporary. If all uses are
dominated by such a copy, the variable is removed. This obviously hurts
debugging.
This isn't a major problem in the current tree, but a patch I'm working
on to always evaluate non-trivial expressions into temps causes it to
happen much more frequently; now pretty much any modification of a user
variable is a copy.
I can think of two ways to address this:
1) When coalescing, try to replace temps with user variables which are
copied from them. This is an incomplete solution, but might be simpler
than:
2) Remember the dead copies, make a list of which temporary holds the value
of a variable at any given time, and feed this list to the debugging
backend.
Thoughts? Is there any live range splitting code in gcc these days?
Jason