aboutsummaryrefslogtreecommitdiff
path: root/gdb/doc
diff options
context:
space:
mode:
authorVladimir Prus <vladimir@codesourcery.com>2008-03-15 13:53:25 +0000
committerVladimir Prus <vladimir@codesourcery.com>2008-03-15 13:53:25 +0000
commit8e8901c5c22072ecab98e3f3e121df2bf0aefc01 (patch)
tree25ab58963d0a6a3199cd4190561f6417efb5a435 /gdb/doc
parent7d1e6fb8639f8b672daaa338744003b4b2595d37 (diff)
downloadfsf-binutils-gdb-8e8901c5c22072ecab98e3f3e121df2bf0aefc01.zip
fsf-binutils-gdb-8e8901c5c22072ecab98e3f3e121df2bf0aefc01.tar.gz
fsf-binutils-gdb-8e8901c5c22072ecab98e3f3e121df2bf0aefc01.tar.bz2
Implement -thread-info.
* gdbthread.h (print_thread_info): Declare. * thread.c (print_thread_info): New, extracted from info_threads_command and adjusted to work for CLI and MI. (info_threads_command): Use print_thread_info. * Makefile.in: Update dependencies. * mi/mi-cmds.c (mi_cmds): Specify a handler for -thread-info. * mi/mi-cmds.h (mi_cmd_thread_info): Declare. * mi/mi-main.c (mi_cmd_thread_info): New. (mi_cmd_list_features): Include 'thread-info'.
Diffstat (limited to 'gdb/doc')
-rw-r--r--gdb/doc/ChangeLog5
-rw-r--r--gdb/doc/gdb.texinfo37
2 files changed, 24 insertions, 18 deletions
diff --git a/gdb/doc/ChangeLog b/gdb/doc/ChangeLog
index 60b83e9..d32caf6 100644
--- a/gdb/doc/ChangeLog
+++ b/gdb/doc/ChangeLog
@@ -1,3 +1,8 @@
+2008-03-15 Vladimir Prus <vladimir@codesourcery.com>
+
+ * gdb.texinfo (Thread Commands): Document
+ -thread-info. Remove -thread-list-all-threads.
+
2008-03-14 Pedro Alves <pedro@codesourcery.com>
Sandra Loosemore <sandra@codesourcery.com>
diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo
index 9b69ad6..2ed036c 100644
--- a/gdb/doc/gdb.texinfo
+++ b/gdb/doc/gdb.texinfo
@@ -18924,34 +18924,33 @@ The corresponding @value{GDBN} command is @samp{pwd}.
@subsubheading Synopsis
@smallexample
- -thread-info
+ -thread-info [ @var{thread-id} ]
@end smallexample
+Reports information about either a specific thread, if
+the @var{thread-id} parameter is present, or about all
+threads. When printing information about all threads,
+also reports the current thread.
+
@subsubheading @value{GDBN} Command
-No equivalent.
+The @samp{info thread} command prints the same information
+about all threads.
@subsubheading Example
-N.A.
-
-
-@subheading The @code{-thread-list-all-threads} Command
-@findex -thread-list-all-threads
-
-@subsubheading Synopsis
@smallexample
- -thread-list-all-threads
+-thread-info
+^done,threads=[
+@{id="2",target-id="Thread 0xb7e14b90 (LWP 21257)",
+ frame=@{level="0",addr="0xffffe410",func="__kernel_vsyscall",args=[]@},
+@{id="1",target-id="Thread 0xb7e156b0 (LWP 21254)",
+ frame=@{level="0",addr="0x0804891f",func="foo",args=[@{name="i",value="10"@}],
+ file="/tmp/a.c",fullname="/tmp/a.c",line="158"@}@}],
+current-thread-id="1"
+(gdb)
@end smallexample
-@subsubheading @value{GDBN} Command
-
-The equivalent @value{GDBN} command is @samp{info threads}.
-
-@subsubheading Example
-N.A.
-
-
@subheading The @code{-thread-list-ids} Command
@findex -thread-list-ids
@@ -21845,6 +21844,8 @@ The current list of features is:
@item
@samp{pending-breakpoints}---indicates presence of the @code{-f}
option to the @code{-break-insert} command.
+@item
+@samp{thread-info}---indicates presence of the @code{-thread-info} command.
@end itemize