Program comprehension assisted by slicing and transformation

Mark Harman, Sebastian Danicic, Yogasundary Sivagurunathan · 1995

Program slicing is a technique for program simplification based upon the deletion of statements which cannot affect the values of a chosen set of variables. Because slicing extracts a subcomponent of the program concerned with some specific computation on a set of variables, it can be used to assist program comprehension, allowing a programmer to remodularise a program according to arbitrarily selected slicing criteria. In this paper it is shown that the simplification power of slicing can be improved if the syntactic restriction to statement deletion is removed, allowing slices to be constructed using any simplifying transformation which preserves the effect of the original program upon the set of variables of interest. It is also shown that quasi static slicing, first proposed by Venkatesh (and defined here in a slightly more general form), is the most suitable slicing paradigm for program comprehension. The various forms of slice are formally defined, an algorithm, based upon transformation, symbolic execution and conventional slicing is introduced for computing syntactically unrestricted, quasi static slices. A worked example is used to show howthis approach supports program comprehension by case analysis and simplification.

Read the paper · More papers on PaperTik