aboutsummaryrefslogtreecommitdiff
path: root/gdb/maint.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/maint.c')
-rw-r--r--gdb/maint.c15
1 files changed, 14 insertions, 1 deletions
diff --git a/gdb/maint.c b/gdb/maint.c
index 952e8cc..3b94eb9 100644
--- a/gdb/maint.c
+++ b/gdb/maint.c
@@ -21,7 +21,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "defs.h"
-#if MAINTENANCE_CMDS /* Entire file goes away if not including maint cmds */
+#if MAINTENANCE_CMDS /* Entire rest of file goes away if not including maint cmds */
#include <signal.h>
#include "command.h"
@@ -243,6 +243,15 @@ maintenance_info_sections (arg, from_tty)
}
}
+/* ARGSUSED */
+void
+maintenance_print_statistics (args, from_tty)
+ char *args;
+ int from_tty;
+{
+ print_objfile_statistics ();
+}
+
/* The "maintenance print" command is defined as a prefix, with allow_unknown
0. Therefore, its own definition is called only for "maintenance print"
with no args. */
@@ -339,6 +348,10 @@ If a SOURCE file is specified, dump only that file's partial symbols.",
"Print dump of current object file definitions.",
&maintenanceprintlist);
+ add_cmd ("statistics", class_maintenance, maintenance_print_statistics,
+ "Print statistics about internal gdb state.",
+ &maintenanceprintlist);
+
add_cmd ("check-symtabs", class_maintenance, maintenance_check_symtabs,
"Check consistency of psymtabs and symtabs.",
&maintenancelist);