Other GDB Buffers
Other buffers provided by M-x gdb whose display you can optionally request include:
- Locals Buffer
- This buffer displays the values of local variables of the current stack frame for simple data types (Information on a frame). Press
RETor clickmouse-2on the value if you want to edit it. Arrays and structures display their type only. With GDB 6.4 or later, you can examine the value of the local variable at point by typingRET, or with amouse-2click. With earlier versions of GDB, useRETormouse-2on the type description ([struct/union]or[array]). Watch Expressions. To display the Locals buffer, typeM-x gdb-display-locals-buffer. - I/O Buffer
- If the program you are debugging uses standard input and output streams for interaction with the user, or emits a significant amount of output to its standard output, you may wish to separate its I/O from interaction with GDB. Use the command
M-x gdb-display-io-bufferto show a window with a buffer to which Emacs redirects the input and output from the program you are debugging. However, if the variablegdb-display-io-bufferisnil, Emacs will not create nor display a separate I/O buffer, but will instead redirect the program's interaction to the GUD interaction buffer. - Registers Buffer
- This buffer displays the values held by the registers (Registers). Request the display of this buffer with the command
M-x gdb-display-registers-buffer. PressRETor clickmouse-2on a register if you want to edit its value. With GDB 6.4 or later, recently changed register values display withfont-lock-warning-face. - Assembler Buffer
- The assembler buffer displays the current frame as machine code. An arrow points to the current instruction, and you can set and remove breakpoints as in a source buffer. Breakpoint icons also appear in the fringe or margin. To request the display of this buffer, use
M-x gdb-display-disassembly-buffer. - Memory Buffer
- The memory buffer lets you examine sections of program memory (Examining memory). Click
mouse-1on the appropriate part of the header line to change the starting address or number of data items that the buffer displays. Alternatively, useSorNrespectively. Clickmouse-3on the header line to select the display format or unit size for these data items. UseM-x gdb-display-memory-bufferto request display of this buffer.
When gdb-many-windows is non-nil, the locals buffer shares its window with the registers buffer, just like breakpoints and threads buffers. To switch from one to the other, click with mouse-1 on the relevant button in the header line.