Re: Watchpoint resource accounting broken (Re: [5/6] breakpoints_ops for all kinds of breakpoints: new watchpoints instance type

Pedro Alves
2011-09-13T16:49:31Z

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