Concept

Stepping (debugging)

Summary
Program animation or stepping refers to the debugging method of executing code one instruction or line at a time. The programmer may examine the state of the program, machine, and related data before and after execution of a particular line of code. This allows the programmer to evaluate the effects of each statement or instruction in isolation, and thereby gain insight into the behavior (or misbehavior) of the executing program. Nearly all modern IDEs and debuggers support this mode of execution. Instruction stepping or single cycle originally referred to the technique of stopping the processor clock and manually advancing it one cycle at a time. For this to be possible, three things are required: A control that allows the clock to be stopped (e.g. a "Stop" button). A second control that allows the stopped clock to be manually advanced by one cycle (e.g. An "instruction step" switch and a "Start" button). Some means of recording the state of the processor after each cycle (e.g. register and memory displays). On the IBM System 360 processor range announced in 1964, these facilities were provided by front panel switches, buttons and banks of neon lights. Other systems, such as the PDP-11, provided similar facilities. On newer processors, which may not support physically stopping the clock and have too much internal state to reasonably display on a panel, similar functionality may be provided via a trap flag, which when enabled instructs the processor to stop after each instruction in a similar manner to a breakpoint. As multiprocessing became more commonplace, such techniques would have limited practicality, since many independent processes would be stopped simultaneously. This led to the development of proprietary software from several independent vendors that provided similar features but deliberately restricted breakpoints and instruction stepping to particular application programs in particular address spaces and threads.
About this result
This page is automatically generated and may contain information that is not correct, complete, up-to-date, or relevant to your search query. The same applies to every other page on this website. Please make sure to verify the information with EPFL's official sources.