Debugging – step, next, continue

When you hit a breakpoint you have several options on how code execution should proceed – e.g. step, next, continue.

Here’s what the different terms mean:

continue: resume program execution until your program completes normally

step: run program until control reaches a different source line then stop code

next: continue to the next source line in the current (innermost) stack frame.

This is similar to step but function calls that appear within the line of code are executed without stopping.

This is specific to gdb but useful:

http://sourceware.org/gdb/onlinedocs/gdb/Continuing-and-Stepping.html

and for more on stack frames:

http://stackoverflow.com/questions/10057443/explain-the-concept-of-a-stack-frame-in-a-nutshell

Leave a Reply

Your email address will not be published. Required fields are marked *