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: [RFC] problem fetching inferior memory due to breakpoint


On Wed, Apr 26, 2006 at 04:33:12PM -0700, Michael Snyder wrote:
> You know what might be a good optimization?
> 
> Take "breakpoints_inserted" out of infcmd, stick it in breakpoint.c,
> and export an access method.  It makes no sense for anybody except
> breakpoint.c to be keeping track of this anyway.
> 
> Then, read_memory_no_bpt can simply check this, and if it's not set,
> default to target_read_memory.

True - but not in the big picture.  If there's enough breakpoints that
walking the linked list checking ->inserted is a problem, think how
much more of a problem removing them and inserting them every step time
must be.  The nice thing about keeping it private in infrun.c is no one
else will use it...

I don't think we're going to be able to keep being so cavalier with
removing and reinserting breakpoints.

-- 
Daniel Jacobowitz
CodeSourcery


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