4.11.2 Single-Step Execution

When single-stepping, CVW pauses after each line of code is executed. If a line contains more than one executable statement, CVW executes all the statements on the line before pausing. The next line to be executed is displayed in reverse video. You can use either the Trace command or the Step command to single-step through an application.

To use Trace, press F8. Trace displays each step of every function for which CVW has symbolic information. Each line of the function is a separate step. If CVW does not have symbolic information for a function, the function runs in a single step.

To use Step, press F10. Step displays each step of the current function but does not step into function calls. Instead, the called function runs as a single step.

You can alternate between Trace and Step as you like. Which method you should use depends on whether you want to see what happens within a particular function.

Attempting to step or trace through Windows startup code while viewing assembly-language instructions causes unpredictable results. To step through your application while viewing assembly-language instructions, set a breakpoint at the WinMain function and begin stepping through the application only after the breakpoint has been reached.

Using the Trace command to step out of a window procedure causes CVW to step into Windows system code.