Re: [RFA] Try2: Ignore breakpoints when reading memory.

Vladimir Prus
2008-03-10T20:57:47Z

On Monday 10 March 2008 23:42:42 Daniel Jacobowitz wrote:
> On Sun, Feb 24, 2008 at 05:50:39PM +0300, Vladimir Prus wrote:
> >
> > This a second attempt at making gdb always ignore
> > any memory breakpoints that are inserted and show the original
> > memory content. This patch is the immediate prerequisite for the
> > patch that makes breakpoints always inserted.
> >
> > Unlike the previous patch, there's a mechanism to:
> > 1. Control the new behaviour from command line.
>
> Do you think we need the option is useful? I think we'll want one for
> leave-breakpoints-inserted mode, which is a bigger change, but this
> patch should only affect GDB internals.

I've added the option as it might be helpful to see real
memory content, say, when diagnosing problems with gdb/stub itself.

>
> > +static void
> > +restore_show_memory_breakpoints (void *arg)
> > +{
> > + show_memory_breakpoints = (int)arg;
> > +}
>
> This will fail with -Werror on a 64-bit host.

Ah, right.

> That leaves the attached patch. Tested on x86_64-linux, no
> regressions. How's it look? I deleted read_memory_nobpt
> entirely.

I think it's good.

- Volodya