Designs for better debug info in GCC
David Daney
ddaney@avtrex.com
Thu Nov 8 19:13:00 GMT 2007
Mark Mitchell wrote:
> Alexandre Oliva wrote:
>> On Nov 7, 2007, Mark Mitchell <mark@codesourcery.com> wrote:
>>
>>> Until we all know what we're trying to do
>> Here's what I am trying to do:
>
> I think these are laudable goals, but you didn't really provide the
> information I wanted. In particular, what I'd like to drill down from
> goals (like "ensure that, for every user variable for which we emit
> debug information, the information is correct") to concrete problems.
>
> I think that most of the goals boil down to making sure that, at any
> point in the program, the debug information for a variable meets the
> following criteria:
>
> (a) if the variable has not been optimized away, gives the location
> where that variable's current value can be found, or
> (b) if the variable has been optimized away, and the value is not a
> constant, says that the value is not available, or
Perhaps if the variable has been optimized away *but* it is possible to
calculate its value by examining the state of the program, then we can
emit the expression needed to calculate its value in the debugging
information as well.
I may be missing something, but it seems that may be part of Alexandre's
plan as well.
> (c) if the variable has been optimized away, but is a constant, says
> what the constant value is
More information about the Gcc-patches
mailing list