This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: Value reference counting
Em Segunda-feira 20 Julho 2009 10:26:50 Daniel Jacobowitz escreveu:
> On Mon, Jul 20, 2009 at 10:22:19AM -0300, Thiago Jung Bauermann wrote:
> > Watchpoints hold their own references to values. Other than that, IMHO if
> > watchpoint code causes values to be leaked, that is a bug, not a special
> > feature which should be respected... WDYT?
>
> Confused by your question :-)
>
> The way free_all_values works is that it's only run after a command.
> For instance, a breakpoint command, or a user-typed command. It's not
> run every time we stop the target and do some thinking if the thinking
> is not in the form of a command. So it's possible to get values
> created that don't get cleaned up for a while.
Right. And that's what I'm complaining about. You're talking about
intermediate values generated every time the inferior stops and the watchpoint
expression is evaluated, right? That's what I'm thinking about.
If you're just thinking about the values stored in struct breakpoint, then I
agree with you...
> Leaked was probably not the right word, just not GC'd promptly.
Yes, and I'm complaining about not GCing for a great, out-of-our-control,
while...
Am I having a delusion here? :-)
--
[]'s
Thiago Jung Bauermann