DeBUG  with GDB

                                                                                                                         
<< CONTENTS >>
        SET MAN PAGES

            SET

                  
set
                   Evaluate expression EXP and assign result to variable VAR, using assignment
                   syntax appropriate for the current language (VAR = EXP or VAR := EXP for
                   example).  VAR may be a debugger "convenience" variable (names starting
                   with $), a register (a few standard names starting with $), or an actual
                   variable in the program being debugged.  EXP is any valid expression.
                   Use "set variable" for variables with names identical to set subcommands.

                   With a subcommand, this command modifies parts of the gdb environment.
                   You can see these environment settings with the "show" command.

                  COMMANDS LIST
          set abi -- Set the C++ ABI  (new/old)
          set admit-internal-symbols -- Set admission of internal symbols into gdb tables
set annotate -- Set annotation_level
set archdebug -- Set architecture debugging
set architecture -- Set architecture of target
set args -- Set argument list to give program being debugged when it is started
set auto-solib-add -- Set autoloading size threshold (in megabytes) of shared library symbols
set can-use-hw-watchpoints -- Set debugger's willingness to use watchpoint hardware
set case-sensitive -- Set case sensitivity in name search
set check -- Set the status of the type/range checker
set complain-if-sigtrap-disabled -- Set whether gdb will complain whenever the program blocks SIGTRAPs
set complaints -- Set max number of complaints about incorrect symbols
set confirm -- Set whether to confirm potentially dangerous operations
set debug -- Generic command for setting gdb debugging flags
set debug-dld --
set debugvarobj -- Set varobj debugging
set demangle-style -- Set the current C++ demangling style
set download-write-size -- Set the write size used when doownloading a program
set editing -- Set editing of command lines as they are typed
set endian -- Set endianness of target
set environment -- Set environment variable value to give the program
set eventdebug -- Set event debugging
set exec-done-display -- Set notification of completion for asynchronous execution commands
set extension-language -- Set mapping between filename extension and source language
set follow-fork-mode -- Set debugger response to a program call of fork or vfork
set gnutarget -- Set the current BFD target
set heap-check -- Set heap-check { on/off | <option> on/off | <option> <num> }
set height -- Set number of lines gdb thinks are in a page
set history -- Generic command for setting command history parameters
set hp-aries-pa32 -- Set support for debugging Aries on PA32
set hp-aries-pa64 -- Set support for debugging Aries on PA64
set ignore-uninteresting-signals -- Set whether gdb should get involved in the delivery of uninteresting signals
set incremental-expansion -- Set incremental symbol table prrocessing behavior
set input-radix -- Set default input radix for entering numbers
set language -- Set the current source language
set lazy-demangling -- Set just in time demangling mode (applicable only to WDB)
set listsize -- Set number of source lines gdb will list by default
set live-core -- Set to debug core generated by dumpcore command
set max-function-matches -- Set maximum number of function matches reported by info functions (set to zero to report all matches)
set namespaces-enabled -- Set enabling of namespace support
set non-debug-functions -- Set listing of non-debug functiions by info functions
set old-vtable -- Set debugger to use old DW_VIRTUALITY values (on/off)
set opaque-type-resolution -- Set resolution of opaque struct/class/union types (if set before loading symbols)
set os -- Set operating system
set output-radix -- Set default output radix for printing of values
set overload-resolution -- Set overload resolution in evalluating C++ functions
set pagination -- Set state of pagination
set print -- Generic command for setting how things print
set print-changed-registers -- Set showing of register changes
set prompt -- Set gdb's prompt
set prompt-escape-char -- Set escape character for formatting of gdb's prompt
set radix -- Set default input and output number radices
set redirect -- Set redirection to file {on|off}
set redirect-file -- Set redirect-file <file>
set redirect-mode -- Set redirect-mode {overwrite | append}
set remote -- Remote protocol specific variables
set remoteaddresssize -- Set the maximum size of the address (in bits) in a memory packet
set remotebaud -- Set baud rate for remote serial I/O
set remotebreak -- Set whether to send break if interrupted
set remotecache -- Set cache use for remote targets
set remotedebug -- Set debugging of remote protocol
set remotedevice -- Set device for remote serial I/O
set remotelogbase -- Set numerical base for remote session logging
set remotelogfile -- Set filename for remote session recording
set remotetimeout -- Set timeout limit to wait for target to respond
set remotewritesize -- Set the maximum number of bytes per memory write packet (deprecated)
set remove-convenience-variables-on-rerun -- Set debugger to remove convenience variables on a rerun(on/off)
                                                                            (only applies to i
nteger values
set scheduler-locking -- Set mode for locking scheduler during execution
set show-all-kthreads -- Set to see all the kernel threads in the program
set src-no-g -- Set debugger response to source level debugging without compiling with -g
set stop-on-solib-events -- Set stopping for shared libraryy events
set symbol-reloading -- Set dynamic symbol table reloading multiple times in one run
set threadverbose -- Set thread verbosity
set tui-auto-refresh -- Set automatic screen refresh
set unwindonsignal -- Set unwinding of stack if a signal is received while in a call dummy
set variable -- Evaluate expression EXP and assign result to variable VAR
set verbose -- Set verbosity
set watchdog -- Set watchdog timer
set width -- Set number of characters gdb thinks are in a line
set write -- Set writing into executable and core files

                    set abi
                    Set the C++ ABI  (new/old)
                    Some pre-release versions of C++ used an old ABI definition.
  
                    set admit-internal-symbols
                    Set admission of internal symbols into gdb tables.

                    set annotate
                    Set annotation_level.
                    0 == normal;     1 == fullname (for use when running under emacs)
                    2 == output annotated suitably for use by programs that control GDB.

                    Set architecture debugging
                    When non-zero, architecture debugging is enabled.

                    set architecture
                    Set architecture of target.
 
                   set args
                   Set argument list to give program being debugged when it is started.
                   Follow this command with any number of args, to be passed to the program.
                  
                   set auto-solib-add
                   Set autoloading size threshold (in megabytes) of shared library symbols.
                   If nonzero, symbols from all shared object libraries will be loaded
                   automatically when the inferior begins execution or when the dynamic linker
                   informs gdb that a new library has been loaded, until the symbol table
                   of the program and libraries exceeds this threshold.
                   Otherwise, symbols must be loaded manually, using `sharedlibrary'.

                   set can-use-hw-watchpoints
                   Set debugger's willingness to use watchpoint hardware.
                   If zero, gdb will not use hardware for new watchpoints, even if
                   such is available.  (However, any hardware watchpoints that were
                   created before setting this to nonzero, will continue to use watchpoint
                   hardware.)

                   set case-sensitive
                   Set case sensitivity in name search.  (on/off/auto)
                   For Fortran the default is off; for other languages the default is on.
           
                   set check
                   Set the status of the type/range checker
                   set check subcommands
                    set check range -- Set range checking
                    set check type -- Set type checking

                    set check range
                    Set range checking.  (on/warn/off/auto)

                    set check type
                    Set type checking.  (on/warn/off/auto)
         
                    set complain-if-sigtrap-disabled
                    Set whether gdb will complain whenever the program blocks SIGTRAPs.
                    This is supported only on HPUX 11.00 at present.

                    set complaints
                    Set max number of complaints about incorrect symbols.

                    set confirm
                    Set whether to confirm potentially dangerous operations.
   
                    set debug
                    Generic command for setting gdb debugging flags
                   
                    set debug subcommands
                    set debug arch -- Set architecture debugging
                    set debug event -- Set event debugging
                    set debug expression -- Set expression debugging
                    set debug overload -- Set debugging of C++ overloading
                    set debug remote -- Set debugging of remote protocol
                    set debug serial -- Set serial debugging
                    set debug target -- Set target debugging

                    set debug arch
                    Set architecture debugging.
                    When non-zero, architecture debugging is enabled.
                   
                    set debug event
                    Set event debugging.
                    When non-zero, event/notify debugging is enabled.
                   
                    set debug expression
                    Set expression debugging.
                    When non-zero, the internal representation of expressions will be printed.

                    set debug overload
                    Set debugging of C++ overloading.
                    When enabled, ranking of the functions is displayed.

                    set debug remote
                    Set debugging of remote protocol.
                    When enabled, each packet sent or received with the remote target is displayed.

                    set debug serial
                    Set serial debugging.
                    When non-zero, serial port debugging is enabled.

                    set debug target
                    Set target debugging.
                    When non-zero, target debugging is enabled.

                    set debug-dld
                   
                    set debugvarobj
                    Set varobj debugging.
                    When non-zero, varobj debugging is enabled.

                    set demangle-style
                    Set the current C++ demangling style.
                    Use `set demangle-style' without arguments for a list of demangling styles.
                   
                    set download-write-size
                    Set the write size used when downloading a program.
                    Only used when downloading a program onto a remote
                    target. Specify zero, or a negative value, to disable
                    blocked writes. The actual size of each transfer is also
                    limited by the size of the target packet and the memory
                    cache.

                    set editing
                    Set editing of command lines as they are typed.
                    Use "on" to enable the editing, and "off" to disable it.
                    Without an argument, command line editing is enabled.  To edit, use
                    EMACS-like or VI-like commands like control-P or ESC.

                    set endian
                    Set endianness of target.
           
                    set environment
                    Set environment variable value to give the program.
                    Arguments are VAR VALUE where VAR is variable name and VALUE is value.
                    VALUES of environment variables are uninterpreted strings.
                    This does not affect the program until the next "run" command.

                    set eventdebug
                    Set event debugging.
                    When non-zero, event/notify debugging is enabled.
           
                    set exec-done-display
                    Set notification of completion for asynchronous execution commands.
                    Use "on" to enable the notification, and "off" to disable it.
   
                    set extension-language
                    Set mapping between filename extension and source language.
                    Usage: set extension-language .foo bar
   
                    set follow-fork-mode
                    Set debugger response to a program call of fork or vfork.
                    A fork or vfork creates a new process.  follow-fork-mode can be:
                    parent  - the original process is debugged after a fork
                    child   - the new process is debugged after a fork
                    ask     - the debugger will ask for one of the above choices
                    For "parent" or "child", the unfollowed process will run free.
                    By default, the debugger will follow the parent process.

                    set gnutarget
                    Set the current BFD target.
                    Use `set gnutarget auto' to specify automatic detection.
 
                    set heap-check
                    Set heap-check { on/off | <option> on/off | <option> <num> }.
                    where <option> on/off can be one of the following:

                    leaks on/off        : Toggle the leak detection capability.
                    bounds on/off       : Toggle bounds check on heap blocks.
                    free on/off         : Toggle validation of calls to free()
                    scramble on/off     : Specify whether freed blocks should be scrambled
                    frame-count <num>   : Specify the depth of call stack to be captured
                    min-leak-size <num> : Specify the minimum size of a block for stack
                                                          trace collection. GDB will still be able to
                                                          report leaks of blocks smaller than this value.
                                                          However, no stack trace would be provided.
                    block-size <num>    : Stop the program whenever it makes an allocation
                                                        request exceeding <num> bytes (0 to disable).
                    heap-size <num>     : Stop target program whenever it's heap grows by
                                                        <num> bytes (0 to disable).
                    watch <address>     : Instruct GDB to stop whenever a block at the
                                                       given address gets allocated or deallocated.

                    Simply typing `set heap-check on' uses the following defaults :
                    leak check on, bounds check on, free check on, scrambling on

                    set height
                    Set number of lines gdb thinks are in a page.

                    set history
                    Generic command for setting command history parameters.
                    set history subcommands
                    set history expansion -- Set history expansion on command input
                    set history filename -- Set the filename in which to record the command history
                    set history save -- Set saving of the history record on exit
                    set history size -- Set the size of the command history

                    set history expansion
                    Set history expansion on command input.
                    Without an argument, history expansion is enabled.

                    set history filename
                    Set the filename in which to record the command history
                    (the list of previous commands of which a record is kept).

                    set history save
                    Set saving of the history record on exit.
                    Use "on" to enable the saving, and "off" to disable it.
                    Without an argument, saving is enabled.
               
                    set history size
                    Set the size of the command history,
                    ie. the number of previous commands to keep a record of.

                   set hp-aries-pa32
                   Set support for debugging Aries on PA32.
                  
                   set hp-aries-pa64
                   Set support for debugging Aries on PA64.
           
                   set ignore-uninteresting-signals
                   Set whether gdb should get involved in the delivery of uninteresting signals.
                   (nostop, noprint, pass)
   
                   set incremental-expansion
                   Set incremental symbol table processing behavior.

                   set input-radix
                   Set default input radix for entering numbers.

                   set language
                   Set the current source language.

                   set lazy-demangling
                   Set just in time demangling mode (applicable only to WDB)

                   set listsize
                   Set number of source lines gdb will list by default.

                   set live-core
                   Set to debug core generated by dumpcore command

                   set max-function-matches
                   Set maximum number of function matches reported by info functions (set to zero to report all matches).
                  
                   set namespaces-enabled
                   Set enabling of namespace support. Default is on.

                   set non-debug-functions
                   Set listing of non-debug functions by info functions.
                
                   set old-vtable
                   Set debugger to use old DW_VIRTUALITY values (on/off).

                   set opaque-type-resolution
                   Set resolution of opaque struct/class/union types (if set before loading symbols).
            
                   set os
                   Set operating system
      
                   set output-radix
                   Set default output radix for printing of values.

                   set overload-resolution
                   Set overload resolution in evaluating C++ functions.
   
                   set pagination
                   Set state of pagination.
   
                   set print
                   Generic command for setting how things print.
                   set print subcommands:
                    set print address -- Set printing of addresses
                    set print args -- Set printing of function arguments
                    set print array -- Set prettyprinting of arrays
                    set print asm-demangle -- Set demangling of C++ names in disassembly listings
                    set print demangle -- Set demangling of encoded C++ names when displaying symbols
                    set print elements -- Set limit on string chars or array elements to print
                    set print max-symbolic-offset -- Set the largest offset that will be printed in <symbol+1234> form
                    set print null-stop -- Set printing of char arrays to stop at first null char
                    set print object -- Set printing of object's derived type based on vtable info
                    set print pretty -- Set prettyprinting of structures
                    set print repeats -- Set threshold for repeated print elements
                    set print sevenbit-strings -- Set printing of 8-bit characters in strings as \nnn
                    set print static-members -- Set printing of C++ static members
                    set print symbol-filename -- Set printing of source filename and line number with <symbol>
                    set print union -- Set printing of unions interior to structures
                    set print vtbl -- Set printing of C++ virtual function tables

                    set print-changed-registers
                    Set showing of register changes.
                   
                    set prompt
                    Set gdb's prompt

                    set prompt-escape-char
                    Set escape character for formatting of gdb's prompt

                    set radix
                    Set default input and output number radices.
                    Use 'set input-radix' or 'set output-radix' to independently set each.
                    Without an argument, sets both radices back to the default value of 10.
           
                    set redirect
                    Set redirection to file {on|off}
                    [Also see 'set redirect-file' and 'set redirect-mode']

                    set redirect-file
                    Set redirect-file <file>
                    Set redirection into file specified by <file> [default = .gdb_output]
   
                    set redirect-mode
                    Set redirect-mode {overwrite | append}
                    Set redirection to file mode to overwrite or append. [default : append]

                    set remote
                    Remote protocol specific variables
                    Configure various remote-protocol specific variables such as
                    the packets being used
                    set remote subcommands
                    set remote P-packet -- Set use of remote protocol `P' (set-register) packet
                    set remote X-packet -- Set use of remote protocol `X' (binary-download) packet
                    set remote Z-packet -- Set use of remote protocol `Z' (breakpoint) packet
                    set remote memory-read-packet-size -- Set the maximum number of bytes per memory-read packet
                    set remote memory-write-packet-size -- Set the maximum number of bytes per memory-write packet

                    set remoteaddresssize
                    Set the maximum size of the address (in bits) in a memory packet.

                    set remotebaud
                    Set baud rate for remote serial I/O.
                    This value is used to set the speed of the serial port when debugging
                    using remote targets.

                    set remotebreak
                    Set whether to send break if interrupted.

                    set remotecache
                    Set cache use for remote targets.
                    When on, use data caching for remote targets.  For many remote targets
                    this option can offer better throughput for reading target memory.
                    Unfortunately, gdb does not currently know anything about volatile
                    registers and thus data caching will produce incorrect results with
                    volatile registers are in use.  By default, this option is off.

                    set remotedebug
                    Set debugging of remote protocol.
                    When enabled, each packet sent or received with the remote target
                    is displayed.

                    set remotedevice
                    Set device for remote serial I/O.
                    This device is used as the serial port when debugging using remote
                    targets.

                    set remotelogbase
                    Set numerical base for remote session logging
       
                    set remotelogfile
                    Set filename for remote session recording.
                    This file is used to record the remote session for future playback
                    by gdbserver.
       
                    set remotetimeout
                    Set timeout limit to wait for target to respond.
                    This value is used to set the time limit for gdb to wait for a response
                    from the target.

                    set remotewritesize
                    Set the maximum number of bytes per memory write packet (deprecated).

                    set remove-convenience-variables-on-rerun
                    Set debugger to remove convenience variables on a rerun(on/off) (only applies to convenience
                    variables which have integer values.
   
                    set scheduler-locking
                    Set mode for locking scheduler during execution.
                    off  == no locking (threads may preempt at any time)
                    on   == full locking (no thread except the current thread may run)
                    step == scheduler locked during every single-step operation.
                    In this mode, no other thread may run during a step command.
                    Other threads may run while stepping over a function call ('next').

                    set show-all-kthreads
                    Set to see all the kernel threads in the program.
                    By default this is set to 0 and gdb reports only those kernel threads which have
                    user threads associated with them.

                    set src-no-g
                    Set debugger response to source level debugging without compiling with -g .
                    Limited source level debugging is available using minimal line tables.
                    src-no-g  can be:
                    none        -    No source level debugging possible without -g.
                    no_sys_libs - For all source files except those in system libraries.
                    all         - For all source files.
                    By default, the debugger will not provide source level debugging without compiling with -g.

                    set stop-on-solib-events
                    Set stopping for shared library events.
                    If nonzero, gdb will give control to the user when the dynamic linker
                    notifies gdb of shared library events.  The most common event of interest
                    to the user would be loading/unloading of a new library.

                    set symbol-reloading
                    Set dynamic symbol table reloading multiple times in one run.

                    set threadverbose
                    Set thread verbosity.

                    set tui-auto-refresh
                    Set automatic screen refresh

                    set unwindonsignal
                    Set unwinding of stack if a signal is received while in a call dummy.
                    The unwindonsignal lets the user determine what gdb should do if a signal
                    is received while in a function called from gdb (call dummy).  If set, gdb
                    unwinds the stack and restore the context to what as it was before the call.
                    The default is to stop in the frame where the signal was received.

                    set variable
                    Evaluate expression EXP and assign result to variable VAR, using assignment
                    syntax appropriate for the current language (VAR = EXP or VAR := EXP for
                    example).  VAR may be a debugger "convenience" variable (names starting
                    with $), a register (a few standard names starting with $), or an actual
                    variable in the program being debugged.  EXP is any valid expression.
                    This may usually be abbreviated to simply "set".

                    set verbose
                    Set verbosity.

                    set watchdog
                    Set watchdog timer.
                    When non-zero, this timeout is used instead of waiting forever for a target to
                    finish a low-level step or continue operation.  If the specified amount of time
                    passes without a response from the target, an error occurs.
   
                    set width
                    Set number of characters gdb thinks are in a line.
               
                    set write
                    Set writing into executable and core files.               
  

                    SET help page                                                                Muthukumar Kandasamy <[email protected]>
               
 
                 

                   
Hosted by www.Geocities.ws

1