* [RFA] add gdbserver --remote-debug switch
@ 2009-01-25 22:39 Pedro Alves
2009-01-25 23:09 ` Daniel Jacobowitz
2009-01-26 3:48 ` Eli Zaretskii
0 siblings, 2 replies; 4+ messages in thread
From: Pedro Alves @ 2009-01-25 22:39 UTC (permalink / raw)
To: gdb-patches
[-- Attachment #1: Type: text/plain, Size: 320 bytes --]
Hello,
I've found it useful before to have remote protocol debug output
on the gdbserver side. There's a 'set remote-debug <0|1>' monitor command
available, but no corresponding command line switch, which enables
debugging the initial connection setup, for instance, and it's easier
to use IMHO.
OK?
--
Pedro Alves
[-- Attachment #2: remote_debug_switch.diff --]
[-- Type: text/x-diff, Size: 2770 bytes --]
gdb/gdbserver/
2009-01-25 Pedro Alves <pedro@codesourcery.com>
* server.c (gdbserver_usage): Mention --remote-debug.
(main): Accept '--remote-debug' switch.
gdb/doc/
2009-01-25 Pedro Alves <pedro@codesourcery.com>
* gdb.texinfo (Using the `gdbserver' Program): Document
--remote-debug.
---
gdb/doc/gdb.texinfo | 9 +++++----
gdb/gdbserver/server.c | 9 ++++++---
2 files changed, 11 insertions(+), 7 deletions(-)
Index: src/gdb/gdbserver/server.c
===================================================================
--- src.orig/gdb/gdbserver/server.c 2009-01-21 12:51:34.000000000 +0000
+++ src/gdb/gdbserver/server.c 2009-01-25 20:55:10.000000000 +0000
@@ -1299,9 +1299,10 @@ gdbserver_usage (FILE *stream)
"HOST:PORT to listen for a TCP connection.\n"
"\n"
"Options:\n"
- " --debug\t\tEnable debugging output.\n"
- " --version\t\tDisplay version information and exit.\n"
- " --wrapper WRAPPER --\tRun WRAPPER to start new programs.\n");
+ " --debug Enable general debugging output.\n"
+ " --remote-debug Enable remote protocol debugging output.\n"
+ " --version Display version information and exit.\n"
+ " --wrapper WRAPPER -- Run WRAPPER to start new programs.\n");
if (REPORT_BUGS_TO[0] && stream == stdout)
fprintf (stream, "Report bugs to \"%s\".\n", REPORT_BUGS_TO);
}
@@ -1378,6 +1379,8 @@ main (int argc, char *argv[])
}
else if (strcmp (*next_arg, "--debug") == 0)
debug_threads = 1;
+ else if (strcmp (*next_arg, "--remote-debug") == 0)
+ remote_debug = 1;
else if (strcmp (*next_arg, "--disable-packet") == 0)
{
gdbserver_show_disableable (stdout);
Index: src/gdb/doc/gdb.texinfo
===================================================================
--- src.orig/gdb/doc/gdb.texinfo 2009-01-25 20:58:16.000000000 +0000
+++ src/gdb/doc/gdb.texinfo 2009-01-25 21:03:20.000000000 +0000
@@ -13985,10 +13985,11 @@ You can terminate it by using @code{moni
@subsubsection Other Command-Line Arguments for @code{gdbserver}
-You can include @option{--debug} on the @code{gdbserver} command line.
-@code{gdbserver} will display extra status information about the debugging
-process. This option is intended for @code{gdbserver} development and
-for bug reports to the developers.
+The @option{--debug} tells @code{gdbserver} to display extra status
+information about the debugging process. The @option{--remote-debug}
+tells @code{gdbserver} to display remote protocol debug output. These
+options are intended for @code{gdbserver} development and for bug
+reports to the developers.
The @option{--wrapper} option specifies a wrapper to launch programs
for debugging. The option should be followed by the name of the
^ permalink raw reply [flat|nested] 4+ messages in thread* Re: [RFA] add gdbserver --remote-debug switch
2009-01-25 22:39 [RFA] add gdbserver --remote-debug switch Pedro Alves
@ 2009-01-25 23:09 ` Daniel Jacobowitz
2009-01-26 3:48 ` Eli Zaretskii
1 sibling, 0 replies; 4+ messages in thread
From: Daniel Jacobowitz @ 2009-01-25 23:09 UTC (permalink / raw)
To: Pedro Alves; +Cc: gdb-patches
On Sun, Jan 25, 2009 at 10:40:18PM +0000, Pedro Alves wrote:
> Hello,
>
> I've found it useful before to have remote protocol debug output
> on the gdbserver side. There's a 'set remote-debug <0|1>' monitor command
> available, but no corresponding command line switch, which enables
> debugging the initial connection setup, for instance, and it's easier
> to use IMHO.
>
> OK?
OK.
--
Daniel Jacobowitz
CodeSourcery
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [RFA] add gdbserver --remote-debug switch
2009-01-25 22:39 [RFA] add gdbserver --remote-debug switch Pedro Alves
2009-01-25 23:09 ` Daniel Jacobowitz
@ 2009-01-26 3:48 ` Eli Zaretskii
2009-01-26 16:26 ` Pedro Alves
1 sibling, 1 reply; 4+ messages in thread
From: Eli Zaretskii @ 2009-01-26 3:48 UTC (permalink / raw)
To: Pedro Alves; +Cc: gdb-patches
> From: Pedro Alves <pedro@codesourcery.com>
> Date: Sun, 25 Jan 2009 22:40:18 +0000
>
> gdb/doc/
> 2009-01-25 Pedro Alves <pedro@codesourcery.com>
>
> * gdb.texinfo (Using the `gdbserver' Program): Document
> --remote-debug.
This part is approved, thanks.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2009-01-26 16:26 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-01-25 22:39 [RFA] add gdbserver --remote-debug switch Pedro Alves
2009-01-25 23:09 ` Daniel Jacobowitz
2009-01-26 3:48 ` Eli Zaretskii
2009-01-26 16:26 ` Pedro Alves
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox