...
r
: Run the programb {function_name | line_number}
: Puts breakpoint at beginning of function or at a line numberinfo args
: Prints function argument values of the current frameinfo locals
: Prints local variable values of the current framep *{array}@{n}
: Prints n values of the array (ideally n is the array length)ptype {struct}
: Prints details about type (useful for printing fields in a struct)Epic gdb function I found for printing a linked list: https://stackoverflow.com/questions/16480045/print-the-whole-linked-list-in-gdb
n
: Step into the next line of the current function, doesn’t step into functionss
: Step into the next line of the program: Should probably avoid and use breakpoints for important functions insteadframe
: Prints the current stack frame + the line of code run (maybe useful for code line highlighting?)where
: Prints information about all stack frames
...