Recovery of noncurrent variables in source-level debugging of optimized code
Source-level debugging and code optimization are important tools of programming. A debugger has to supply precise information about the values of the variables at any run time error or breakpoint. Code optimization, on the other hand, removes dead stores and reorders code to save time and space, causing intermediate events to happen out of sequence. A thorough implementation of either limits the usefulness of the other. Hennessy, in his paper “Symbolic Debugging of Optimized Code” , suggested various techniques to handle this. However, he explicitly chose not to take advantage of the fact that many operations are reversible and many partial results will be avaiable in registers and temporaries. This paper considers these questions in order to extend Hennessy's techniques for recovery of noncurrent variables. The algorithms developed can detect most of the recoverable variables, and run in linear time. We also consider methods to limit our search to only a part of the dag.
Unable to display preview. Download preview PDF.
- A.V. Aho and J. D. Ullman, Principles of Compiler Design, Addison-Wesely, Menlo Park, California, 1977.Google Scholar
- J. Hennessy, Symbolic Debugging of Optimized Code, ACM Transactions on Programming Languages and Systems 4,3 (July 1982),323–344.Google Scholar
- David Wall, Amitabh Srivastava and Fred Templin, A Note on Hennessy's 'symbolic Debugging of Optimized Code,’ Tech Corr, ACM Transactions on Programming Languages and Systems, 7,1 (January 1985), 176–181.Google Scholar