Abstract

AbstractProgram slicing is a useful technique for debugging, testing and program integration. Intuitively, by the slice of a program P is meant, for a point n and a variable v in P, the set of statements and expressions in P that affect the value of v at n. To determine a slice, there must be a precise analysis of the dependencies among the statements in the program. It is difficult, on the other hand, to analyze the program containing recursions.This paper presents a static analysis for the dependencies in the program containing recursion, as well as the algorithm to determine the slice based on the result of the analysis. To cope with the recursive definition of the procedure, the proposed algorithm assumes the interprocedure information needed in the computation. This information is modified to the correct direction, and the process is iterated until the result converges.The program dependence graph is extended to hold the interprocedure information. Compared to the conventional algorithm, the proposed algorithm can analyze efficiently the program containing recursions, and can be used in the system to provide interactively the slice information.

Full Text
Published version (Free)

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call