From: "Jim Blandy" <jimb@red-bean.com>
To: "Michael Snyder" <msnyder@specifix.com>
Cc: "Jim Blandy" <jimb@codesourcery.com>,
"Thiago Jung Bauermann" <bauerman@br.ibm.com>,
"Vladimir Prus" <vladimir@codesourcery.com>,
gdb@sources.redhat.com
Subject: Re: Keeping breakpoints inserted
Date: Sat, 01 Dec 2007 17:52:00 -0000 [thread overview]
Message-ID: <8f2776cb0712010952y5330258akfe3086287f59ccb9@mail.gmail.com> (raw)
In-Reply-To: <1196472622.2501.180.camel@localhost.localdomain>
On Nov 30, 2007 5:30 PM, Michael Snyder <msnyder@specifix.com> wrote:
> > Since breakpoints only make the threads that hit them execute "very
> > slowly", I don't see how they could introduce a deadlock in code that
> > didn't already have the potential for deadlock in the absence of a
> > debugger.
>
> Well, just 'cause you've changed the timing. Thread A holds
> a resource that thread B needs; thread A hits a breakpoint
> but thread B gets to keep running (for a while) because you
> haven't finished inserting breakpoints.
Non-stop debugging can affect the relative timing of threads more than
all-stop debugging. And even if the developer only stops one thread,
others may stop too, because they're waiting for the developer's
thread to do something. But I don't think what you've described is
deadlock: B is blocked waiting for A, which may take a long time
(until the developer lets go of it, to be exact) to get through what
it's doing. When A resumes, both will resume.
The original concern you raised was that non-stop debugging is "more
intrusive than we already are". But clearly all-stop debugging on a
live system is maximally intrusive to the system's users; non-stop
debugging has the potential to be much less intrusive, when used with
knowledge of the interactions between the system's threads.
I think what's bothering you is that the degree of effective
interference depends on the developer knowing stuff about the system
under debug; it's not just a flat-out guarantee made by the debugger:
"no matter what you do, we promise X, or at least roughly X." But
there are reasonable debugger use cases that are simply not possible
at all with all-stop debugging. We want to support those, in addition
to the ones we support now.
next prev parent reply other threads:[~2007-12-01 17:52 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
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 [this message]
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=8f2776cb0712010952y5330258akfe3086287f59ccb9@mail.gmail.com \
--to=jimb@red-bean.com \
--cc=bauerman@br.ibm.com \
--cc=gdb@sources.redhat.com \
--cc=jimb@codesourcery.com \
--cc=msnyder@specifix.com \
--cc=vladimir@codesourcery.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).