This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [RFA] dwarf debug format: Support DW_AT_variable_parameter attribute
- From: Tom Tromey <tromey at redhat dot com>
- To: "Pierre Muller" <pierre dot muller at ics-cnrs dot unistra dot fr>
- Cc: "'Joel Brobecker'" <brobecker at adacore dot com>, <gdb-patches at sourceware dot org>, "'FPC Core Developer List'" <core at freepascal dot org>
- Date: Wed, 19 May 2010 12:56:50 -0600
- Subject: Re: [RFA] dwarf debug format: Support DW_AT_variable_parameter attribute
- References: <8830.7035308846$1273670829@news.gmane.org> <m34oibvhgh.fsf@fleche.redhat.com> <20100517172758.GJ2805@adacore.com> <000301caf5e7$222ac800$66805800$@muller@ics-cnrs.unistra.fr> <20100517174726.GK2805@adacore.com> <44296.7587885962$1274132782@news.gmane.org>
- Reply-to: tromey at redhat dot com
>>>>> "Pierre" == Pierre Muller <pierre.muller@ics-cnrs.unistra.fr> writes:
Pierre> I looked a little more into the sources
Pierre> and now understand that my patch is indeed
Pierre> wrong :(
[...]
Pierre> See note line 8459 from dwarf2read.c source.
Pierre> /* NOTE drow/2002-01-30: It might be worthwhile to have a static
Pierre> expression evaluator, and use LOC_COMPUTED only when necessary
Pierre> (i.e. when the value of a register or memory location is
Pierre> referenced, or a thread-local block, etc.). Then again, it might
Pierre> not be worthwhile. I'm assuming that it isn't unless performance
Pierre> or memory numbers show me otherwise. */
Pierre> I fear that my patch will have to wait until
Pierre> this static expression evaluator is implemented...
I'm not totally convinced that we would want such an evaluator.
Could you change the type of a parameter marked with
DW_AT_variable_parameter to be a reference type instead? It seems to me
that this would give the same result, or nearly so.
Tom