This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: Watchpoint resource accounting broken (Re: [5/6] breakpoints_ops for all kinds of breakpoints: new watchpoints instance type
- From: Pedro Alves <pedro at codesourcery dot com>
- To: "Ulrich Weigand" <uweigand at de dot ibm dot com>
- Cc: Edjunior Barbosa Machado <emachado at linux dot vnet dot ibm dot com>, gdb-patches at sourceware dot org
- Date: Tue, 13 Sep 2011 17:49:03 +0100
- Subject: Re: Watchpoint resource accounting broken (Re: [5/6] breakpoints_ops for all kinds of breakpoints: new watchpoints instance type
- References: <201109131522.p8DFMg93032568@d06av02.portsmouth.uk.ibm.com>
On Tuesday 13 September 2011 16:22:42, Ulrich Weigand wrote:
> Pedro Alves wrote:
> > Does the patch below work? Never consider the current watchpoint when
> > going over the breakpoint list counting resources, and then
> > add the resources of the current watchpoint on top. This way we
> > don't have to care of the current watchpoint being on the list yet or
> > not. As bonus, we no longer have to frog the watchpoint's type before
> > knowing if it'll fit.
>
> Yes, this patch looks good to me, and does fix the problem I've
> been seeing. Thanks!
Thanks to both. I've checked it in now.
> It seems to me that it would be preferable to integrate these missing
> checks into the code in update_watchpoint, and then remove the
> can_use_hardware_watchpoint routine ...
Indeed.
> [ But that's clearly a follow-on cleanup, and shouldn't prevent your
> bug-fix patch from going in now. ]
Yep.
--
Pedro Alves