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: Save the length of inserted breakpoints


> Date: Fri, 3 Mar 2006 00:01:52 +0100 (CET)
> From: Mark Kettenis <mark.kettenis@xs4all.nl>
> CC: gdb-patches@sourceware.org
> 
> > Date: Thu, 2 Mar 2006 17:17:11 -0500
> > From: Daniel Jacobowitz <drow@false.org>
> > 
> > This nasty, mechanical patch adds "len" arguments to
> > target_remove_breakpoint and target_remove_hw_breakpoint.  The goal is
> > to allow BREAKPOINT_FROM_PC to include heuristics, which may possibly
> > change between when a breakpoint is inserted and when it is removed;
> > in order to stay in sync, we need to always remove breakpoints in the
> > same way that we inserted them.
> > 
> > There's not much more to say about this patch.  It's big, obvious, and
> > pretty ugly.  Any comments on this?  Does it look OK?
> 
> Yuck!  It really is ugly.  For one thing, I think it is a bit
> pointless, to add a the BREAKPOINT_FROM_PC() to targets where we know
> the length of a breakpoint instruction is fixed.

Was the reason for this discussed at some point?  What I miss from
Daniel's patch is some kind of explanation as to the reason(s) for it.
I have my guesses, but I don't think I should do guesswork here.
Perhaps I missed the explanation in the patch, but I did look at the
comments and the gdbint.texinfo text, and didn't find anything that
explains why we need this.


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