diff options
author | Stan Shebs <shebs@codesourcery.com> | 2010-06-18 17:44:40 +0000 |
---|---|---|
committer | Stan Shebs <shebs@codesourcery.com> | 2010-06-18 17:44:40 +0000 |
commit | 6aed2dbcba548376cdc0b98231fb9b174f9ca978 (patch) | |
tree | 37933482f06cdff97129271eb76c1e8401649ef9 /gdb/doc | |
parent | 6508b958ffb3afc176ac6b978e15baafbc85e4ab (diff) | |
download | gdb-6aed2dbcba548376cdc0b98231fb9b174f9ca978.zip gdb-6aed2dbcba548376cdc0b98231fb9b174f9ca978.tar.gz gdb-6aed2dbcba548376cdc0b98231fb9b174f9ca978.tar.bz2 |
* thread.c (thread_id_make_value): Make a value representing the
current thread.
(_initialize_thread): Create $_thread.
* gdb.texinfo (Debugging Programs with Multiple Threads): Describe
$_thread.
* gdb.threads/thread-specific.exp: Add tests of $_thread.
Diffstat (limited to 'gdb/doc')
-rw-r--r-- | gdb/doc/ChangeLog | 5 | ||||
-rw-r--r-- | gdb/doc/gdb.texinfo | 7 |
2 files changed, 12 insertions, 0 deletions
diff --git a/gdb/doc/ChangeLog b/gdb/doc/ChangeLog index 60ae888..e853346 100644 --- a/gdb/doc/ChangeLog +++ b/gdb/doc/ChangeLog @@ -1,3 +1,8 @@ +2010-06-18 Stan Shebs <stan@codesourcery.com> + + * gdb.texinfo (Debugging Programs with Multiple Threads): Describe + $_thread. + 2010-06-18 Hui Zhu <teawater@gmail.com> * gdb.texinfo: (Process Record and Replay): Add documentation diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo index 03752b6..8c19696 100644 --- a/gdb/doc/gdb.texinfo +++ b/gdb/doc/gdb.texinfo @@ -2788,6 +2788,13 @@ As with the @samp{[New @dots{}]} message, the form of the text after @samp{Switching to} depends on your system's conventions for identifying threads. +@vindex $_thread@r{, convenience variable} +The debugger convenience variable @samp{$_thread} contains the number +of the current thread. You may find this useful in writing breakpoint +conditional expressions, command scripts, and so forth. See +@xref{Convenience Vars,, Convenience Variables}, for general +information on convenience variables. + @kindex thread apply @cindex apply command to several threads @item thread apply [@var{threadno}] [@var{all}] @var{command} |