GDB cheatsheet

must compile the program using flags -O0 -g.

Basic

Breakpoints

Info

Code

Split view (TUI)

Reverse debugging

might not always work properly!

Remote

Valgrind

must compile the program using flags -O0 -g.