This paper studies program slicing in the presence of input statements. If unnecessary input statements are sliced away, the remaining input statements are assumed to read the same data as within the entire program. For specifying the relation of one program being a slice of another under this assumption, one needs a formalism for treating "stages of computation". This paper presents an approach where stages of computation, called run points, are encoded by rational numbers. Run points of the slice and the corresponding run points of the whole program are encoded by equal numbers. We adapt a program analysis used by a classic slicing algorithm to our setting, in order to prove correctness of the slicing algorithm.
展开▼