Abstract
Theslice of a program with respect to a componentc is a projection of the program that includes all components that might affect (either directly or transitively) the values of the variables used atc. Slices can be extracted particularly easily from a program representation called a program dependence graph, originally introduced as an intermediate program representation for performing optimizing, vectorizing, and parallelizing transformations. This paper presents a linear-time algorithm for determining whether two slices of a program dependence graph are isomorphic.
Similar content being viewed by others
References
Allen, J.R.: Dependence analysis for subscripted variables and its application to program transformations. Ph.D. Thesis, Department of Mathematics Sciences, Rice University, Houston, TX, 1983
Ball, T.: Personal communication 1991
Binkley, D.: Multi-procedure program integration. Ph.D. dissertation and Technical Report 1038, Computer Sciences Department University of Wisconsin, Madison, WI, 1991
Cytron, R., Ferrante, J., Rosen, B.K., Wegman, M.N., Zadeck, K.: An efficient method of computing static single assignment form. Conference Record of the Sixteenth ACM Symposium on Principles of Programming Languages, pp. 25–35, New York, ACM 1989
Ferrante, J., Ottenstein, K., Warren, J.: The program dependence graph and its use in optimization. ACM Trans. Program. Lang. Syst.9(3) 319–349 (1987)
Hoffmann, C.M.: Group-theoretic algorithms and graph isomorphism (Lect. Notes Comput. Sci., Vol. 136). Berlin Heidelberg New York: Springer 1982
Horwitz, S., Prins, J., Reps, T.: On the adequacy of program dependence graphs for representing programs. Conference Record of the 15th ACM Symposium on Principles of Programming Languages, pp. 146–157. New York: ACM 1988
Horwitz, S., Prins, J., Reps, T.: Integrating non-interfering versions of programs. ACM Trans. Program. Lang. Systems11(3), 345–387 (1989)
Horwitz, S.: Identifying the semantic and textual differences between two versions of a program. Proceedings of the SIGPLAN 90 Conference on Programming Language Design and Implementation. ACM SIGPLAN Notices25(6), 234–246 1990
Horwitz, S., Reps, T., Binkley, D.: Interprocedural slicing using dependence graphs. ACM Trans. Program. Lang. Systems12(1), 26–60 (1990)
Kuck, D.J., Muraoka, Y., Chen, S.C.: On the number of operations simultaneously executable in FORTRAN-like programs and their resulting speed-up. IEEE Trans. Comput.C-21, 1293–1310 (1972)
Luks, E.: Isomorphism of bounded valence can be tested in polynomial time. Proceedings of the Twenty-First IEEE Symposium on Foundations of Computer Science, pp. 42–49. Washington, DC: IEEE Computer Society 1980
Ottenstein, K.J., Ottenstein, L.M.: The program dependence graph in a software development environment. Proceedings of the ACM SIGSOFT/SIGPLAN Software Engineering Symposium on Practical Software Development Environments. ACM SIGPLAN Notices19(5), 177–184 (1984)
Reps, T., Yang, W.: The semantics of program slicing. Technical Report 777, Department of Computer Sciences, University of Wisconsin, Madison, WI, 1988
Reps, T.: Demonstration of a prototype tool for program integration. Technical Report 819, Department of Computer Sciences, University of Wisconsin, Madison, WI, 1989
Reps, T.: The Wisconsin program-integration system reference manual. Unpublished document. Computer Sciences Department, University of Wisconsin, Madison, WI, 1990
Reps, T.: Algebraic properties of program integration. Sci. Comput. Program. In press
Weiser, M.: Program slicing. IEEE Trans. Software EngeSE-10(4), 352–357 (1984)
Yang, W., Horwitz, S., Reps, T.: Detecting program components with equivalent behaviors. Technical Report 840, Department of Computer Sciences, University of Wisconsin, Madison, WI, 1989
Author information
Authors and Affiliations
Additional information
This work was supported in part by a David and Lucile Packard Fellowship for Science and Engineering, by the National Science Foundation under grants DCR-8552602 and CCR-8958530, by the Defense Advanced Research Projects Agency, monitored by the Office of Naval Research under contract N00014-88-K-0590, and by grants from IBM, DEC, Xerox, 3M, Eastman Kodak, and the Cray Research Foundation.
Rights and permissions
About this article
Cite this article
Horwitz, S., Reps, T. Efficient comparison of program slices. Acta Informatica 28, 713–732 (1991). https://doi.org/10.1007/BF01261653
Received:
Issue Date:
DOI: https://doi.org/10.1007/BF01261653