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


On Fri, Mar 03, 2006 at 11:39:30PM +0200, Eli Zaretskii wrote:
> > Date: Fri, 3 Mar 2006 12:54:07 -0500
> > From: Daniel Jacobowitz <drow@false.org>
> > Cc: gdb-patches@sourceware.org
> > 
> > If every target cached the size of inserted breakpoints and made sure
> > to remove them at the same size, that would work too, but right now
> > most targets don't need to remember anything about the breakpoints
> > they've inserted; the common layer of GDB handles it.
> 
> That sounds like an unfortunate design.  If we are to make significant
> changes to handle the complications that led you to this patch,
> perhaps we should consider changing the design instead.

Well, as I said, I was trying to not redesign more of GDB than
necessary...

Do you believe it _should_ be the target vector's responsibility to
remember inserted breakpoint details?  I find this a little bit
strange, since every target will have to do just about the
same thing.

Another possible interface change to solve the problem would be to
pass a "struct breakpoint" to the remove function.  However, today
there are many places where breakpoints are used without a
corresponding "struct breakpoint" e.g. for software single step.
I've tried cleaning up that in the past, and it's defeated me
every single time.

-- 
Daniel Jacobowitz
CodeSourcery


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