Some gdb tips

You can look at the source code with layout src (or ^X-A) and assembly with layout asm

i r (short for info registers) displays current register values (eax, ebx... for x86)

Set breakpoints to all functions in source.c: rbreak source.c:.

You can pass gdb commands at start with -ex "cmd", i.e. gdb a.out -ex "tar rem:1234; b main"


Back