This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Remove same-pc breakpoint notification for internal BPs


On Wednesday 31 August 2011 14:18:00, Kevin Pouget wrote:
> On Wed, Apr 27, 2011 at 3:02 PM, Kevin Pouget <kevin.pouget@gmail.com> wrote:
> > Hello,
> >
> > here is an updated version of the patch, which uses `user_breakpoint_p'
> >
> >
> > thanks,
> >
> > Kevin (still waiting for copyright papers)
> 
> 
> Hello,
> 
> this patch was not explicitly approved when I first submitted it,  but
> all the concerns were addressed; please let me not if it looks good to
> you

This is okay, thanks.  

On Wednesday 31 August 2011 14:18:00, Kevin Pouget wrote:
>    ALL_BREAKPOINTS (b)
> -    others += breakpoint_has_pc (b, pspace, pc, section);
> +    others += (breakpoint_has_pc (b, pspace, pc, section)
> +               && user_breakpoint_p (b));
>    if (others > 0)
>      {
>        if (others == 1)
> @@ -5418,7 +5419,7 @@ describe_other_breakpoints (struct gdbarch *gdbarch,
>        else /* if (others == ???) */
>         printf_filtered (_("Note: breakpoints "));
>        ALL_BREAKPOINTS (b)
> -       if (breakpoint_has_pc (b, pspace, pc, section))
> +       if (breakpoint_has_pc (b, pspace, pc, section) && user_breakpoint_p (b))


I'd suggest flipping the tests order so the cheaper test is done
first, like:

> +    others += (user_breakpoint_p (b)
> +               && breakpoint_has_pc (b, pspace, pc, section));

and 

> +       if (user_breakpoint_p (b) && breakpoint_has_pc (b, pspace, pc, section))

Okay with or without that change.

-- 
Pedro Alves


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]