This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
Re: MI: reporting of multiple breakpoints
On Sun, Feb 19, 2006 at 09:52:14PM +0200, Eli Zaretskii wrote:
> > Date: Sun, 19 Feb 2006 13:08:41 -0500
> > From: Paul Koning <pkoning@equallogic.com>
> > Cc: ghost@cs.msu.su, gdb@sources.redhat.com
> >
> > My point is that, at least on some of the platforms, a watchpoint
> > exception will deliver the PC of the instruction doing the store, or
> > that PC can be deduced.
>
> I think this happens on _all_ platforms that support watchpoints.
Really? On x86, I suspect that the exception is always at the
instruction following the store; so it's possible, although
non-trivial, to identify the store by backtracking. Is that right?
But I can easily imagine this not being the case on some architecture
with delay slots.
> > Therefore, on such platforms, that is the PC that should be
> > reported, which will make the report point to the right source line.
>
> We already do precisely that.
>
> Again, the place that caused the store is known (and shown to the
> user), but the place where the inferior is stopped is a different
> place on many architectures, including x86. Wed are arguing about the
> latter, not the former.
Could you give me an example? I think that is desirable, but not at
all what we do today - I have no idea how to retrieve the address of
the store when I stop at a watchpoint. We show the old and new value,
but that's it.
--
Daniel Jacobowitz
CodeSourcery