Skip to main content

Annotated structure shape graphs for abstract analysis of Prolog

  • Progam Analysis
  • Conference paper
  • First Online:
Programming Languages: Implementations, Logics, and Programs (PLILP 1996)

Part of the book series: Lecture Notes in Computer Science ((LNCS,volume 1140))

  • 165 Accesses

Abstract

The paper presents an abstract interpretation of Prolog that derives information about the shape and sharing of structures to which variables are bound at runtime. The purpose is to support analysis of live structures, which in turn supports compile-time memory reuse. The abstract domain consists of graphs that use shared subgraphs to represent shared substructure in the heap. This sharing in the abstract representation is not new, though we are the first to use it in a context where unification must be modeled. The principal contribution is a system of annotations that increases the precision of the sharing information and the efficiency of the analysis.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. B. Burton, G. Gudjonsson, and W. Winsborough. An algorithm for computing alternating closure. Technical Report CS-92-15, Penn State, June 1992.

    Google Scholar 

  2. J.D. Choi, M.G. Burke, and P. Carini. Efficient flow-sensitive interprocedural computation of pointer-induced aliases and side-effects. POPL, pages 232–245, January 1993.

    Google Scholar 

  3. D.R. Chase, M. Wegman, and F.K. Zadeck. Analysis of pointers and structures. PLDI, pages 20–22, June 1990.

    Google Scholar 

  4. A. Deutsch. Interprocedural may-alias analysis for pointers: Beyond k-limiting. PLDI, pages 230–241, June 1994.

    Google Scholar 

  5. G. Gudjonsson and W. Winsborough. Update in place: Overview of the siva project. In Dale Miller, editor, ILPS, pages 94–113. MIT Press, 1993.

    Google Scholar 

  6. N. Heintze. Practical aspects of set based analysis. In Krzysztok Apt, editor, JICSLP, pages 765–779. MIT Press, 1992.

    Google Scholar 

  7. G. Janssens and M. Bruynooghe. Deriving descriptions of possible values of program variables by means of abstract interpretation. Journal of Logic Programming, 13(2&3):205–258, July 1992.

    Google Scholar 

  8. N.D. Jones and S. Muchnick. Flow analysis and optimzation of lisp-like structures. In S. Muchnick and N.D. Jones, editors, Program Flow Analysis: Theory and Applications, pages 102–131. Prentice-Hall, 1981.

    Google Scholar 

  9. N.D. Jones and S. Muchnick. A flexible approach to interprocedural data flow analysis and programs with recursive data structures. POPL, pages 66–74, 1982.

    Google Scholar 

  10. A. Kagedal. Improvements in compile-time analysis for ground prolog. In M. Bruynooghe, J. Penjam, editors, PLILP. LNCS 714, Springer-Verlag, August 1993.

    Google Scholar 

  11. F. Kluźniak. Compile-time garbage collection for ground Prolog. In R. A. Kowalski and K. A. Bowen, editors, ICSLP, pages 1490–1505. MIT Press, August 1988.

    Google Scholar 

  12. J. R. Larus and P. N. Hilfinger. Detecting conflicts between structure accesses. PLDI, pages 21–34, July 1988.

    Google Scholar 

  13. B. Le Charlier and P. Van Hentenryck. Experimental evaluation of a generic abstract interpretation algorithm for prolog (extended abstract). Fourth IEEE International Conference on Computer Languages, April 1992.

    Google Scholar 

  14. A. Marien, G. Janssens, A. Mulkers, and M. Bruynooghe. The impact of abstract interpretation: An experiment in code generation. In G. Levi and M. Martelli, editors, ICLP. MIT Press, 1989.

    Google Scholar 

  15. A. Mulkers, W. Winsborough, and M. Bruynooghe. Analysis of shared data structures for compile-time garbage collection in logic programs. In D. H. D. Warren and P. Szeredi, editors, ICLP. MIT Press, 1990.

    Google Scholar 

  16. A. Mulkers, W. Winsborough, and M. Bruynooghe. Live-structure dataflow analysis for Prolog. TOPLAS, 16, 1994.

    Google Scholar 

  17. M. S. Patterson and M. N. Wegman. Linear unification. Journal of computer and system sciences, 16:158–167, 1978.

    Google Scholar 

  18. P. Van Hentenryck, A. Cortesi, and B. Le Charlier. Type analysis of prolog using type graphs. PLDI, 1994.

    Google Scholar 

  19. G. Weyer. Structure shape graphs with explicit sharing for prolog-like languages. Master's thesis, Dept of Computer Science and Engineering, Penn State, May 1996.

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Herbert Kuchen S. Doaitse Swierstra

Rights and permissions

Reprints and permissions

Copyright information

© 1996 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Weyer, G., Winsborough, W. (1996). Annotated structure shape graphs for abstract analysis of Prolog. In: Kuchen, H., Doaitse Swierstra, S. (eds) Programming Languages: Implementations, Logics, and Programs. PLILP 1996. Lecture Notes in Computer Science, vol 1140. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3-540-61756-6_79

Download citation

  • DOI: https://doi.org/10.1007/3-540-61756-6_79

  • Published:

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-61756-3

  • Online ISBN: 978-3-540-70654-0

  • eBook Packages: Springer Book Archive

Publish with us

Policies and ethics