3 ms·
gdb is magic once you get the hang of it, I'd definitely recommend spending some time getting comfortable with it.
by briansteffens 10y ago
gdb is magic once you get the hang of it, I'd definitely recommend spending some time getting comfortable with it.
- AdmiralAsshat 10y agoI know my way around GDB, but only as a C debugger. Haven't really used it for Assembly.
- sigjuice 10y ago(gdb) help si Step one instruction exactly. (gdb) help ni Step one instruction, but proceed through subroutine calls. (gdb) help info registers List of integer registers and their contents, for selected stack frame. Register name as argument means describe only that register. (gdb) layout reg # to enable view of registers in split screen Also, you can use register names in expressions. e.g. p $r11 All of this is applicable when debugging a C program as well.
- AdmiralAsshat 10y ago`layout reg` Did exactly what I wanted. Thank-you so much!
- barrkel 10y agoI've found it very buggy when working at the assembly level on a complex program (e.g. JVM). I think it coredumped on average every 5 minutes as I tried to step through things or set breakpoints.
- BellsOnSunday 10y agoYes, and there is an appendix on gdb in the Bartlett book which will get OP started.