MI: document the -catch-load/-unload commands
authorMircea Gherzan <mgherzan@sourceware.org>
Wed, 12 Dec 2012 21:23:29 +0000 (21:23 +0000)
committerMircea Gherzan <mgherzan@sourceware.org>
Wed, 12 Dec 2012 21:23:29 +0000 (21:23 +0000)
2012-11-16 Mircea Gherzan <mircea.gherzan@intel.com>

gdb/doc:
* gdb.texinfo (GDB/MI Catchpoint Commands): New section.

gdb/:
* NEWS: mention the -catch-load/-catch-unload MI commands.

gdb/ChangeLog
gdb/NEWS
gdb/doc/ChangeLog
gdb/doc/gdb.texinfo

index a3bcbeb69d0de04288236f1617a3624a52cde14f..5ea7d67d21e365a767f2a5ff817b1fdaedeadcc1 100644 (file)
@@ -1,3 +1,7 @@
+2012-12-12  Mircea Gherzan  <mircea.gherzan@intel.com>
+
+       * NEWS: Mention the -catch-load/-catch-unload MI commands.
+
 2012-12-12  Mircea Gherzan  <mircea.gherzan@intel.com>
     
        * Makefile.in (SUBDIR_MI_OBS): Add mi-cmd-catch.o.
index ceb81a2d35cdd72248d253e0c434cdfb011a83f9..7c467f87e75ec6064e20370bf940da754ec14703 100644 (file)
--- a/gdb/NEWS
+++ b/gdb/NEWS
@@ -101,6 +101,8 @@ show print type typedefs
      has been requested.
   ** New optional parameter COUNT added to the "-data-write-memory-bytes" 
      command, to allow pattern filling of memory areas.
+  ** New commands "-catch-load"/"-catch-unload" added for intercepting
+     library load/unload events.
 
 * GDB now supports the "mini debuginfo" section, .gnu_debugdata.
   You must have the LZMA library available when configuring GDB for this
index 226fb55840ad33c00753c76c4c1df2bccc2d4b4a..535f266a3318123b61d5bb59d0cc66884d262571 100644 (file)
@@ -1,3 +1,7 @@
+2012-12-12 Mircea Gherzan <mircea.gherzan@intel.com>
+    
+       * gdb.texinfo (GDB/MI Catchpoint Commands): New section.
+
 2012-12-11  Pedro Alves  <palves@redhat.com>
 
        * gdb.texinfo: Remove all mentions of Unixware throughout.
index 9964cbf10bd3e77f512ee63e8b261c50a8c1a082..c23e5debda2bbeae324b164b25e0ea870e2ca204 100644 (file)
@@ -27155,6 +27155,7 @@ may repeat one or more times.
 * GDB/MI Simple Examples::
 * GDB/MI Command Description Format::
 * GDB/MI Breakpoint Commands::
+* GDB/MI Catchpoint Commands::
 * GDB/MI Program Context::
 * GDB/MI Thread Commands::
 * GDB/MI Ada Tasking Commands::
@@ -28729,6 +28730,73 @@ times="1"@}]@}
 (gdb)
 @end smallexample
 
+
+@c %%%%%%%%%%%%%%%%%%%%%%%%%%%% SECTION %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+@node GDB/MI Catchpoint Commands
+@section @sc{gdb/mi} Catchpoint Commands
+
+This section documents @sc{gdb/mi} commands for manipulating
+catchpoints.
+
+@subheading The @code{-catch-load} Command
+@findex -catch-load
+
+@subsubheading Synopsis
+
+@smallexample
+ -catch-load [ -t ] [ -d ] @var{regexp}
+@end smallexample
+
+Add a catchpoint for library load events.  If the @samp{-t} option is used,
+the catchpoint is a temporary one (@pxref{Set Breaks, ,Setting
+Breakpoints}).  If the @samp{-d} option is used, the catchpoint is created
+in a disabled state.  The @samp{regexp} argument is a regular
+expression used to match the name of the loaded library.
+
+
+@subsubheading @value{GDBN} Command
+
+The corresponding @value{GDBN} command is @samp{catch load}.
+
+@subsubheading Example
+
+@smallexample
+-catch-load -t foo.so
+^done,bkpt=@{number="1",type="catchpoint",disp="del",enabled="y",
+what="load of library matching foo.so",times="0"@}
+(gdb)
+@end smallexample
+
+
+@subheading The @code{-catch-unload} Command
+@findex -catch-unload
+
+@subsubheading Synopsis
+
+@smallexample
+ -catch-unload [ -t ] [ -d ] @var{regexp}
+@end smallexample
+
+Add a catchpoint for library unload events.  If the @samp{-t} option is
+used, the catchpoint is a temporary one (@pxref{Set Breaks, ,Setting
+Breakpoints}).  If the @samp{-d} option is used, the catchpoint is
+created in a disabled state.  The @samp{regexp} argument is a regular
+expression used to match the name of the unloaded library.
+
+@subsubheading @value{GDBN} Command
+
+The corresponding @value{GDBN} command is @samp{catch unload}.
+
+@subsubheading Example
+
+@smallexample
+-catch-unload -d bar.so
+^done,bkpt=@{number="2",type="catchpoint",disp="keep",enabled="n",
+what="load of library matching bar.so",times="0"@}
+(gdb)
+@end smallexample
+
+
 @c %%%%%%%%%%%%%%%%%%%%%%%%%%%% SECTION %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 @node GDB/MI Program Context
 @section @sc{gdb/mi}  Program Context