From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8441 invoked by alias); 30 Nov 2012 10:50:51 -0000 Mailing-List: contact archer-commits-help@sourceware.org; run by ezmlm Sender: Precedence: bulk List-Post: List-Help: List-Subscribe: Received: (qmail 8409 invoked by uid 9514); 30 Nov 2012 10:50:50 -0000 Date: Fri, 30 Nov 2012 10:50:00 -0000 Message-ID: <20121130105050.8394.qmail@sourceware.org> From: pmuldoon@sourceware.org To: archer-commits@sourceware.org Subject: [SCM] archer-pmuldoon-python-backtrace: Add missing help, options and documentation for options. X-Git-Refname: refs/heads/archer-pmuldoon-python-backtrace X-Git-Reftype: branch X-Git-Oldrev: a2871b2eadcd787de03d30f8b6c312aa45640f99 X-Git-Newrev: ff146700b0c59a031ec65b4b5ed216bc0626b297 X-SW-Source: 2012-q4/txt/msg00021.txt.bz2 List-Id: The branch, archer-pmuldoon-python-backtrace has been updated via ff146700b0c59a031ec65b4b5ed216bc0626b297 (commit) from a2871b2eadcd787de03d30f8b6c312aa45640f99 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email. - Log ----------------------------------------------------------------- commit ff146700b0c59a031ec65b4b5ed216bc0626b297 Author: Phil Muldoon Date: Fri Nov 30 10:50:14 2012 +0000 Add missing help, options and documentation for options. ----------------------------------------------------------------------- Summary of changes: gdb/doc/gdb.texinfo | 62 ++++++++++++++++++++++++++++++++++++++++++++------ gdb/stack.c | 4 ++- 2 files changed, 57 insertions(+), 9 deletions(-) First 500 lines of diff: diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo index 7911cc7..5a0215d 100644 --- a/gdb/doc/gdb.texinfo +++ b/gdb/doc/gdb.texinfo @@ -6386,6 +6386,17 @@ Similar, but print only the outermost @var{n} frames. @itemx bt full -@var{n} Print the values of the local variables also. @var{n} specifies the number of frames to print, as described above. + +@item backtrace raw +@itemx bt raw +@itemx bt raw @var{n} +@itemx bt raw -@var{n} +@itemx bt raw full +@itemx bt raw full @var{n} +@itemx bt raw full -@var{n} +Do not run Python frame filters on this backtrace. @xref{Frame +Filters API}, for more information. This is only relevant when +@value{GDBN} has been configured with @code{Python} support. @end table @kindex where @@ -25702,6 +25713,11 @@ The @code{type_printers} attribute is a list of type printer objects. @xref{Type Printing API}, for more information. @end defvar +@defvar Progspace.frame_filters +The @code{frame_filters} attribute is a dictionary of frame filter +objects. @xref{Frame Filters API}, for more information. +@end defvar + @node Objfiles In Python @subsubsection Objfiles In Python @@ -25752,6 +25768,11 @@ The @code{type_printers} attribute is a list of type printer objects. @xref{Type Printing API}, for more information. @end defvar +@defvar Objfile.frame_filters +The @code{frame_filters} attribute is a dictionary of frame filter +objects. @xref{Frame Filters API}, for more information. +@end defvar + A @code{gdb.Objfile} object has the following methods: @defun Objfile.is_valid () @@ -30417,6 +30438,25 @@ Is this going away???? @node GDB/MI Stack Manipulation @section @sc{gdb/mi} Stack Manipulation Commands +@subheading The @code{-enable-frame-filters} Command +@findex -enable-frame-filters + +@smallexample +-enable-frame-filters +@end smallexample + +@value{GDBN} allows Python-based frame filters to affect the output of +the MI commands relating to stack traces. As there is no way to +implement this in a fully backward-compatible way, a front end must +request that this functionality be enabled. + +Once enabled, this feature cannot be disabled. + +Note that if Python support has not been compiled into @value{GDBN}, +this command will still succeed (and do nothing). + +This feature is currently (as of @value{GDBN} 7.6) experimental, and +may work differently in future versions of @value{GDBN}. @subheading The @code{-stack-info-frame} Command @findex -stack-info-frame @@ -30491,7 +30531,7 @@ For a stack with frame levels 0 through 11: @subsubheading Synopsis @smallexample - -stack-list-arguments @var{print-values} + -stack-list-arguments [ --no-frame-filters ] @var{print-values} [ @var{low-frame} @var{high-frame} ] @end smallexample @@ -30508,7 +30548,9 @@ If @var{print-values} is 0 or @code{--no-values}, print only the names of the variables; if it is 1 or @code{--all-values}, print also their values; and if it is 2 or @code{--simple-values}, print the name, type and value for simple data types, and the name and type for arrays, -structures and unions. +structures and unions. If the option @code{--no-frame-filters} is +supplied, then Python frame filters will not be executed. + Use of this command to obtain arguments in a single frame is deprecated in favor of the @samp{-stack-list-variables} command. @@ -30586,7 +30628,7 @@ args=[@{name="intarg",value="2"@}, @subsubheading Synopsis @smallexample - -stack-list-frames [ @var{low-frame} @var{high-frame} ] + -stack-list-frames [ --no-frame-filters @var{low-frame} @var{high-frame} ] @end smallexample List the frames currently on the stack. For each frame it displays the @@ -30616,7 +30658,9 @@ levels are between the two arguments (inclusive). If the two arguments are equal, it shows the single frame at the corresponding level. It is an error if @var{low-frame} is larger than the actual number of frames. On the other hand, @var{high-frame} may be larger than the -actual number of frames, in which case only existing frames will be returned. +actual number of frames, in which case only existing frames will be +returned. If the option @code{--no-frame-filters} is supplied, then +Python frame filters will not be executed. @subsubheading @value{GDBN} Command @@ -30691,7 +30735,7 @@ Show a single frame: @subsubheading Synopsis @smallexample - -stack-list-locals @var{print-values} + -stack-list-locals [ --no-frame-filters ] @var{print-values} @end smallexample Display the local variable names for the selected frame. If @@ -30702,7 +30746,8 @@ type and value for simple data types, and the name and type for arrays, structures and unions. In this last case, a frontend can immediately display the value of simple data types and create variable objects for other data types when the user wishes to explore their values in -more detail. +more detail. If the option @code{--no-frame-filters} is supplied, then +Python frame filters will not be executed. This command is deprecated in favor of the @samp{-stack-list-variables} command. @@ -30734,7 +30779,7 @@ This command is deprecated in favor of the @subsubheading Synopsis @smallexample - -stack-list-variables @var{print-values} + -stack-list-variables [ --no-frame-filters ] @var{print-values} @end smallexample Display the names of local variables and function arguments for the selected frame. If @@ -30742,7 +30787,8 @@ Display the names of local variables and function arguments for the selected fra the variables; if it is 1 or @code{--all-values}, print also their values; and if it is 2 or @code{--simple-values}, print the name, type and value for simple data types, and the name and type for arrays, -structures and unions. +structures and unions. If the option @code{--no-frame-filters} is +supplied, then Python frame filters will not be executed. @subsubheading Example diff --git a/gdb/stack.c b/gdb/stack.c index 46add40..a5ef5d2 100644 --- a/gdb/stack.c +++ b/gdb/stack.c @@ -2582,7 +2582,9 @@ It can be a stack frame number or the address of the frame.\n")); add_com ("backtrace", class_stack, backtrace_command, _("\ Print backtrace of all stack frames, or innermost COUNT frames.\n\ With a negative argument, print outermost -COUNT frames.\nUse of the \ -'full' qualifier also prints the values of the local variables.\n")); +'full' qualifier also prints the values of the local variables.\n\ +Use of the 'raw' qualifier prohibits frame filters from executing\n\ +on this backtrace.\n")); add_com_alias ("bt", "backtrace", class_stack, 0); if (xdb_commands) { hooks/post-receive -- Repository for Project Archer.