| OCR Text |
Show A problem with reverse execution are peripheral devices, since it is physically impossible to return some devices, like printers, to a state in the past. Fortunately, the most common device, a graphical display, does not pose that limitation. It can display an arbitrary picture at any time. During reverse execution, the state of a display must be returned to the past to reflect the actual state of the executor. Since the executor is not aware that a reverse execution was performed, the display must be updated by someone else. An inefficient solution would be to include the support for reverse execution in the graphic display system itself. An introspective computer offers an alternative. A special director that recreates the display from executor's data structures could be constructed. A related solution without using directing would be to integrate the director with the executor. This solution is less flexible than a separate director, since the director is fixed and cannot be changed during the execution. 3.2.4 P ro g ram Visualization A graphical representation of an executing program can greatly improve the understanding of the program's behavior. The most interesting features of a program are data structures and control flow. Two directors were implemented in Dynascope providing a dynamic visualization of linked data structures and the control flow graph. Visualizing Da ta Structures A program to maintain a sorted linked list was taken as a test case. Numbers in the list are sorted in increasing order. To visualize a linked list, a director was written that monitors pointer assignments and calls to memory management routines. Each change to the list is displayed on the screen. The executor randomly inserts and deletes random numbers from the list. A snapshot from the director's display is shown in Figure 3.4. The bottom part of the figure displays the list. This 41 |