public inbox for gdb@sourceware.org
 help / color / mirror / Atom feed
From: Vladimir Prus <vladimir@codesourcery.com>
To: Michael Snyder <msnyder@specifix.com>
Cc: gdb@sources.redhat.com
Subject: Re: Keeping breakpoints inserted
Date: Fri, 30 Nov 2007 10:11:00 -0000	[thread overview]
Message-ID: <200711301311.01113.vladimir@codesourcery.com> (raw)
In-Reply-To: <1196385134.2501.144.camel@localhost.localdomain>

On Friday 30 November 2007 04:12:14 you wrote:
> On Thu, 2007-11-29 at 22:24 +0300, Vladimir Prus wrote:
> > One of the infrastructure bits necessary for the non-stop threads
> > debugging is always-inserted-breakpoints mode. If GDB has stopped
> > one thread, and other threads are running, we want those other threads
> > to still hit breakpoints and watchpoints. However, current GDB removes
> > all breakpoints from the target before giving user a prompt, and this
> > has to change.
> >
> > I've spend quite time examining breakpoint.c and infrun.c and
> > cleaning/localizing the decisions as to when breakpoints are
> > inserted/removed, and I believe I now have a fully workable plan
> > to make breakpoints always inserted.
> >
> > [...]
> >
> > Anybody has comments on this approach?
>
> Might there be a user preference, under some circumstances,
> to NOT have them inserted while some threads run and some
> are stopped?

Honestly, originally I planned to have breakpoints always inserted,
unconditionally. Unfortunately, that does not work with remote targets --
since the Z0 packet may use memory breakpoints, and remote protocol does
not requires the memory read packet to return original memory content,
without breakpoints, we'd need to explicitly read the memory ourself --
which is not necessary without non-stop mode.

At the same time, I don't yet know any scenario when 
always-inserted-breakpoints mode should not be used in non-stop mode -- 
as non-stop mode needs some support from remote side anyway, we might
as well demand "right" behaviour from Z0/m.

- Volodya

  reply	other threads:[~2007-11-30 10:11 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-11-29 19:24 Vladimir Prus
2007-11-30  1:25 ` Michael Snyder
2007-11-30 10:11   ` Vladimir Prus [this message]
2007-11-30 21:03 ` Thiago Jung Bauermann
2007-11-30 21:41   ` Michael Snyder
2007-12-01  0:08     ` Jim Blandy
2007-12-01  1:43       ` Michael Snyder
2007-12-01 17:52         ` Jim Blandy
2007-12-02 18:38           ` Thiago Jung Bauermann
2007-12-03 18:14             ` Jim Blandy
2007-11-30 23:53   ` Jim Blandy

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200711301311.01113.vladimir@codesourcery.com \
    --to=vladimir@codesourcery.com \
    --cc=gdb@sources.redhat.com \
    --cc=msnyder@specifix.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).