# Debugging with GDB

## The GNU Source-Level Debugger

## Seventh Edition, for GDB version 4.18

## February 1999

This file describes GDB, the GNU symbolic debugger.

This is the Seventh Edition, February 1999, for GDB Version 4.18.

Copyright (C) 1988-1999 Free Software Foundation, Inc.

- Summary: Summary of GDB
- Sample Session: A sample GDB session
- Invocation: Getting in and out of GDB
- Commands: GDB commands
- Running: Running programs under GDB
- Stopping: Stopping and continuing
- Stack: Examining the stack
- Source: Examining source files
- Data: Examining data
- Languages: Using GDB with different languages
- Symbols: Examining the symbol table
- Altering: Altering execution
- GDB Files: GDB files
- Targets: Specifying a debugging target
- Controlling GDB: Controlling GDB
- Sequences: Canned sequences of commands
- Emacs: Using GDB under @sc{gnu} Emacs
- GDB Bugs: Reporting bugs in GDB
- Formatting Documentation: How to format and print GDB documentation
- Command Line Editing: Command Line Editing
- Using History Interactively: Using History Interactively
- Installing GDB: Installing GDB
- Index: Index -- The Detailed Node Listing --- Summary of GDB
- Free Software: Freely redistributable software
- Contributors: Contributors to GDB Getting In and Out of GDB
- Invoking GDB: How to start GDB
- Quitting GDB: How to quit GDB
- Shell Commands: How to use shell commands inside GDB Invoking GDB
- File Options: Choosing files
- Mode Options: Choosing modes GDB Commands
- Command Syntax: How to give commands to GDB
- Completion: Command completion
- Help: How to ask GDB for help Running Programs Under GDB
- Compilation: Compiling for debugging
- Starting: Starting your program
- Arguments: Your program's arguments
- Environment: Your program's environment
- Working Directory: Your program's working directory
- Input/Output: Your program's input and output
- Attach: Debugging an already-running process
- Kill Process: Killing the child process
- Process Information: Additional process information
- Threads: Debugging programs with multiple threads
- Processes: Debugging programs with multiple processes Stopping and Continuing
- Breakpoints: Breakpoints, watchpoints, and catchpoints
- Continuing and Stepping: Resuming execution
- Signals: Signals
- Thread Stops: Stopping and starting multi-thread programs Breakpoints and watchpoints
- Set Breaks: Setting breakpoints
- Set Watchpoints: Setting watchpoints
- Set Catchpoints: Setting catchpoints
- Delete Breaks: Deleting breakpoints
- Disabling: Disabling breakpoints
- Conditions: Break conditions
- Break Commands: Breakpoint command lists
- Breakpoint Menus: Breakpoint menus Examining the Stack
- Frames: Stack frames
- Backtrace: Backtraces
- Selection: Selecting a frame
- Frame Info: Information on a frame
- Alpha/MIPS Stack: Alpha and MIPS machines and the function stack Examining Source Files
- List: Printing source lines
- Search: Searching source files
- Source Path: Specifying source directories
- Machine Code: Source and machine code Examining Data
- Expressions: Expressions
- Variables: Program variables
- Arrays: Artificial arrays
- Output Formats: Output formats
- Memory: Examining memory
- Auto Display: Automatic display
- Print Settings: Print settings
- Value History: Value history
- Convenience Vars: Convenience variables
- Registers: Registers
- Floating Point Hardware: Floating point hardware Using GDB with Different Languages
- Setting: Switching between source languages
- Show: Displaying the language
- Checks: Type and range checks
- Support: Supported languages Switching between source languages
- Filenames: Filename extensions and languages.
- Manually: Setting the working language manually
- Automatically: Having GDB infer the source language Type and range checking
- Type Checking: An overview of type checking
- Range Checking: An overview of range checking Supported languages
- C: C and C++ C Language Support
- C Operators: C operators C Language Support
- C Operators: C and C++ operators
- C Constants: C and C++ constants
- Cplus expressions: C++ expressions
- C Defaults: Default settings for C and C++
- C Checks: C and C++ type and range checks
- Debugging C: GDB and C
- Debugging C plus plus: GDB features for C++ Modula-2
- M2 Operators: Built-in operators
- Built-In Func/Proc: Built-in functions and procedures
- M2 Constants: Modula-2 constants
- M2 Defaults: Default settings for Modula-2
- Deviations: Deviations from standard Modula-2
- M2 Checks: Modula-2 type and range checks
- M2 Scope: The scope operators @code{::} and @code{.}
- GDB/M2: GDB and Modula-2 Altering Execution
- Assignment: Assignment to variables
- Jumping: Continuing at a different address
- Signaling: Giving your program a signal
- Returning: Returning from a function
- Calling: Calling your program's functions
- Patching: Patching your program GDB Files
- Files: Commands to specify files
- Symbol Errors: Errors reading symbol files Specifying a Debugging Target
- Active Targets: Active targets
- Target Commands: Commands for managing targets
- Byte Order: Choosing target byte order
- Remote: Remote debugging Remote debugging
- Remote Serial: GDB remote serial protocol
- i960-Nindy Remote: GDB with a remote i960 (Nindy)
- UDI29K Remote: The UDI protocol for AMD29K
- EB29K Remote: The EBMON protocol for AMD29K
- VxWorks Remote: GDB and VxWorks
- ST2000 Remote: GDB with a Tandem ST2000
- Hitachi Remote: GDB and Hitachi Microprocessors
- MIPS Remote: GDB and MIPS boards
- Simulator: Simulated CPU target Controlling GDB
- Prompt: Prompt
- Editing: Command editing
- History: Command history
- Screen Size: Screen size
- Numbers: Numbers
- Messages/Warnings: Optional warnings and messages Canned Sequences of Commands
- Define: User-defined commands
- Hooks: User-defined command hooks
- Command Files: Command files
- Output: Commands for controlled output Reporting Bugs in GDB
- Bug Criteria: Have you found a bug?
- Bug Reporting: How to report bugs Installing GDB
- Separate Objdir: Compiling GDB in another directory
- Config Names: Specifying names for hosts and targets
- Configure Options: Summary of options for configure

This document was generated on 7 November 1999 using the texi2html translator version 1.51a.