Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Pedro Alves <palves@redhat.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: gdb-patches@sourceware.org
Subject: Re: [PATCH] [DOC] Mention what happens when the thread of a thread-specific breakpoint is gone.
Date: Fri, 04 Oct 2013 18:26:00 -0000	[thread overview]
Message-ID: <524F086C.3030908@redhat.com> (raw)
In-Reply-To: <524F01E4.7050902@redhat.com>

On 10/04/2013 06:59 PM, Pedro Alves wrote:
> On 10/04/2013 06:54 PM, Pedro Alves wrote:
>> That was on purpose.  It's what GDB says too.  That's because
>> there are other ways for a thread to disappear other than
>> a regular thread exit, such as "detach", "disconnect"
>> or gdb losing the remote connection, etc.  The thread hasn't
>> really exited in those cases.
> 
> I guess that means I should update the docs to clarify that.  :-)
> A sec while I prepare a new patch.

What about this?  I'm now saying "no longer in the thread list"
instead of "is gone".

Not sure whether GDB's own wording should be changed in the
same way?  This is 78 columns:

-Thread-specific breakpoint 3 deleted - thread 28 is gone.
+Thread-specific breakpoint 3 deleted - thread 28 no longer in the thread list.

It'll of course be larger with higher breakpoint and thread numbers, but
I guess it is still within reasonable bounds...

-----
[DOC] Mention what happens when the thread of a thread-specific breakpoint is gone.

We recently made GDB auto-delete thread-specific breakpoints when the
corresponding thread is gone, but we haven't mentioned it in the manual.

gdb/
2013-10-04  Pedro Alves  <palves@redhat.com>

	PR breakpoints/11568
	* gdb.texinfo (Thread-Specific Breakpoints): Mention what happens
	when the thread is gone.
---

 gdb/doc/gdb.texinfo |   18 ++++++++++++++++++
 1 file changed, 18 insertions(+)

diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo
index a68556b..207a93e 100644
--- a/gdb/doc/gdb.texinfo
+++ b/gdb/doc/gdb.texinfo
@@ -5864,6 +5864,24 @@ after the breakpoint condition, like this:
 
 @end table
 
+Thread-specific breakpoints are automatically deleted when
+@value{GDBN} detects the corresponding thread is no longer in the
+thread list.  For example:
+
+@smallexample
+(@value{GDBP}) c
+Thread-specific breakpoint 3 deleted - thread 28 is gone.
+@end smallexample
+
+There are several ways for a thread to disappear, such as a regular
+thread exit, but also when you detach from the process with the
+@code{detach} command (@pxref{Attach, ,Debugging an Already-running
+Process}), or if @value{GDBN} loses the remote connection
+(@pxref{Remote Debugging}), etc.  Note that with some targets,
+@value{GDBN} is only able to detect a thread has exited when the user
+explictly asks for the thread list with the @code{info threads}
+command.
+
 @node Interrupted System Calls
 @subsection Interrupted System Calls 
 


  reply	other threads:[~2013-10-04 18:26 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-04 15:01 Pedro Alves
2013-10-04 17:49 ` Eli Zaretskii
2013-10-04 17:54   ` Pedro Alves
2013-10-04 17:59     ` Pedro Alves
2013-10-04 18:26       ` Pedro Alves [this message]
2013-10-04 19:20         ` Eli Zaretskii
2013-10-07 11:03           ` Thread-specific breakpoints: say "no longer in the thread list" instead of "gone". (was: [PATCH] [DOC] Mention what happens when the thread of a thread-specific breakpoint is gone.) Pedro Alves
2013-10-07 11:14           ` [PATCH] [DOC] Mention what happens when the thread of a thread-specific breakpoint is gone Pedro Alves
2013-10-04 18:14     ` Eli Zaretskii

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=524F086C.3030908@redhat.com \
    --to=palves@redhat.com \
    --cc=eliz@gnu.org \
    --cc=gdb-patches@sourceware.org \
    /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