Re: RFA/RFC: dump symtab and psymtab lists

Andrew Cagney
2003-04-08T07:39:36Z

> This patch adds two new commands, 'maint print symtabs' and 'maint
> print psymtabs', that print out the full and partial symtab lists.
> You can supply a regexp to match against the (p)symtab name to just
> list a few.
>
> The existing 'maint print symbols' and 'maint print psymbols' are
> exhaustive, which is useful sometimes, but they produce so much output
> that they're a pain to use when you just want to see what's up with
> the symtab and psymtab lists themselves.
>
> The output includes expressions you can cut-and-paste into GDB to get
> a pointer to a specific symtab, psymtab, etc., and it's parenthesized
> to make the Emacs balanced motion commands work usefully. The
> documentation includes examples.

Jim,

The `maint print' series of commands should all use the syntax:

(gdb) maint print <component> [ <output-file> ]

(things todo is check that this is consistent).

Andrew

> gdb/ChangeLog:
> 2003-04-07 Jim Blandy <jimb@redhat.com>
>
> * symmisc.c (maintenance_print_symtabs,
> maintenance_print_psymtabs): New functions.
> * maint.c (_initialize_maint_cmds): Add commands for the above.
> * symtab.h (maintenance_print_symtabs,
> maintenance_print_psymtabs): New declarations.
> * Makefile.in (symmisc.o): Update dependencies.
>
> gdb/doc/ChangeLog:
> 2003-04-07 Jim Blandy <jimb@redhat.com>
>
> * gdb.texinfo (Symbols): Document 'maint print symtabs' and 'maint
> print psymtabs'.
>