[PATCH]: add set/show debug, move gdb debugging flags into it

Daniel Berlin dan@cgsoftware.com
Mon Mar 13 09:04:00 GMT 2000


Attached is a patch to add "set debug" and "show debug", and move the gdb
debugging stuff (targetdebug,expressiondebug,etc) into those lists.

I renamed targetdebug,expressiondebug,etc (all the debug settings i
moved), to remove the "debug" from their name, so you do "set debug target
1" rather than "set debug targetdebug 1".

The new command lists are named setdebuglist/showdebuglist, and are in
command.c.
I put set_debug and show_debug into command.c, for lack of a better place.
The point of all this is to make it much easier to see what debugging
flags you can set for GDB, and what they were set to. It also declutters
the set list.
I also enabled monitordebug, since it said int he comment it was waiting
for "set debug".

I have no idea who needs to approve this, since it touches a bunch of
stuff, but is only related to one domain so to speak.

I'm working on a changelog entry,  i wanted to get comments first.

Example of what you get with the patch installed:
(gdb) help set debug
Generic command for setting gdb debugging flags
List of set debug subcommands:
set debug arch -- Set architecture debugging
set debug event -- Set event debugging
set debug expression -- Set expression debugging
set debug remote -- Set debugging of remote protocol
set debug serial -- Set serial debugging
set debug target -- Set target debugging
set debug varobj -- Set varobj debugging
Type "help set debug" followed by set debug subcommand name for full
documentation.
Command name abbreviations are allowed if unambiguous.
(gdb)

(gdb) help show debug
Generic command for showing gdb debugging flags
List of show debug subcommands:
show debug arch -- Show architecture debugging
show debug event -- Show event debugging
show debug expression -- Show expression debugging
show debug remote -- Show debugging of remote protocol
show debug serial -- Show serial debugging
show debug target -- Show target debugging
show debug varobj -- Show varobj debugging
Type "help show debug" followed by show debug subcommand name for full
documenta
tion.
Command name abbreviations are allowed if unambiguous.
(gdb)
(gdb) show debug
arch:  Architecture debugging is 0.
event:  Event debugging is 0.
expression:  Expression debugging is 0.
remote:  Debugging of remote protocol is 0.
serial:  Serial debugging is 0.
target:  Target debugging is 0.
varobj:  Varobj debugging is 0.
(gdb) set debug
"set debug" must be followed by the name of a print subcommand.
List of set debug subcommands:
set debug arch -- Set architecture debugging
set debug event -- Set event debugging
set debug expression -- Set expression debugging
set debug remote -- Set debugging of remote protocol
set debug serial -- Set serial debugging
set debug target -- Set target debugging
set debug varobj -- Set varobj debugging
Type "help set debug" followed by set debug subcommand name for full
documentati
on.
Command name abbreviations are allowed if unambiguous.
(gdb)



More information about the Gdb-patches mailing list