skip to main content
10.1145/292540.292552acmconferencesArticle/Chapter ViewAbstractPublication PagespoplConference Proceedingsconference-collections
Article
Free Access

Parametric shape analysis via 3-valued logic

Authors Info & Claims
Published:01 January 1999Publication History

ABSTRACT

We present a family of abstract-interpretation algorithms that are capable of determining "shape invariants" of programs that perform destructive updating on dynamically allocated storage. The main idea is to represent the stores that can possibly arise during execution using three-valued logical structures.

Questions about properties of stores can be answered by evaluating predicate-logic formulae using Kleene's semantics of three-valued logic:

  • If a formula evaluates to true, then the formula holds in every store represented by the three-valued structure.

  • If a formula evaluates to false, then the formula does not hold in any store represented by the three-valued structure.

  • If a formula evaluates to unknown, then we do not know if this formula always holds, never holds, or sometimes holds and sometimes does not hold in the stores represented by the three-valued structure.

Three-valued logical structures are thus a conservative representation of memory stores.

The approach described is a parametric framework: It provides the basis for generating a family of shape-analysis algorithms by varying the vocabulary used in the three-valued logic.

References

  1. 1.U. Assmann and M. Weinhardt. Interprocedural heap analysis for parallelizing imperative programs. In W. K. Giloi, S. J~ihnichen, and B. D. Shriver, editors, Programming Models For Massively Parallel Computers, pages 74-82, Washington, DC, September 1993. IEEE Press.Google ScholarGoogle ScholarCross RefCross Ref
  2. 2.D.R. Chase, M. Wegman, and F. Zadeck. Analysis of pointers and structures. In SIGPLAN Conf. on Prog. Lang. Design and lmpl., pages 296-310, New York, NY, 1990. ACM Press. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. 3.P. Cousot and R. Cousot. Systematic design of program analysis frameworks. In Syrup. on Princ. of Prog. Lang., pages 269-282, New York, NY, 1979. ACM Press. Google ScholarGoogle Scholar
  4. 4.A. Deutsch. A storeless model for aliasing and its abstractions using finite representations of right-regular equivalence relations. In IEEE International Conference on Computer Languages, pages 2-13, Washington, DC, 1992. IEEE Press.Google ScholarGoogle ScholarCross RefCross Ref
  5. 5.A. Deutsch. Interprocedural may-alias analysis for pointers: Beyond k-limiting. In SIGPLAN Conf. on Prog. Lang. Design and Impl., pages 230-241, New York, NY, 1994. ACM Press. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. 6.L. Hendren. Parallelizing Programs with Recursive Data Structures. PhD thesis, CorneI1 Univ., Ithaca, NY, Jan 1990. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. 7.L. Hendren, J. Hummel, and A. Nicolau. Abstractions for recursive pointer data structures: Improving the analysis and the transformation of imperative programs. In SIGPLAN Conf. on Prog. Lang. Design and lmpl., pages 249-260, New York, NY, June 1992. ACM Press. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. 8.L. Hendren and A. Nicolau. Parallelizing programs with recursive data structures. IEEE Trans. on Par. and Dist. Syst., 1(1):35-47, January 1990. Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. 9.C.A.R. Hoare. Recursive data structures. Int. d. of Comp. and Inf. Sci., 4(2):105-132, 1975.Google ScholarGoogle Scholar
  10. 10.S. Horwitz, P. Pfeiffer, and T. Reps. Dependence analysis for pointer variables. In SIGPLAN Conf. on Prog. Lang. Design and lmpl., pages 28-40, New York, NY, 1989. ACM Press. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. 11.N.D. Jones and S.S. Muchnick. Flow analysis and optimization of Lisp-like structures. In S.S. Muchnick and N.D. Jones, editors, Program Flow Analysis: Theory and Applications, chapter 4, pages 102-131. Prentice-Hall, Englewood Cliffs, NJ, 1981.Google ScholarGoogle Scholar
  12. 12.N.D. Jones and S.S. Muchnick. A flexible approach to interprocedural data flow analysis and programs with recursive data structures. In Syrup. on Princ. of Prog. Lang., pages 66-74, New York, NY, 1982. ACM Press. Google ScholarGoogle Scholar
  13. 13.S.C. Kleene. Introduction to Metamathematics. North- Holland, second edition, 1987.Google ScholarGoogle Scholar
  14. 14.W. Landi and B.G. Ryder. Pointer induced aliasing: A problem classification. In Syrup. on Princ. of Prog. Lang., pages 93-103, New York, NY, January 1991. ACM Press. Google ScholarGoogle Scholar
  15. 15.J.R. Larus and P.N. Hilfinger. Detecting conflicts between structure accesses. In SIGPLAN Conf. on Prog. Lang. Design and Impl., pages 21-34, New York, NY, 1988. ACM Press. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. 16.J. Plevyak, A.A. Chien, and V. Karamcheti. Analysis of dynamic structures for efficient parallel execution, in U. Banerjee, D. Gelernter, A. Nicolau, and D. Padua, editors, Languages and Compilers .for Parallel Computing, volume 768 of Lec. Notes in Comp. Sci., pages 37-57, Portland, OR, August 1993. Springer-Verlag. Google ScholarGoogle Scholar
  17. 17.M. Sagiv, T. Reps, and R. Wilhelm. Solving shape-analysis problems in languages with destructive updating. In Syrup. on Princ. of Prog. Lang., New York, NY, January 1996. ACM Press. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. 18.M. Sagiv, T. Reps, and R. Wilhelm. Parametric shape analysis via 3-valued logic. Tech. Rep. TR-1383, Comp. Sci. Dept., Univ. of Wisconsin, Madison, WI, July 1998. Available at "http://www.cs.wisc.edu/wpis/papers/parametric.ps".Google ScholarGoogle Scholar
  19. 19.M. Sagiv, T. Reps, and R. Wilhelm. Solving shape-analysis problems in languages with destructive updating. 7~ns. on Prog. Lang. and Syst., 20(1):1-50, January 1998. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. 20.S. Sagiv, N. Francez, M. Rodeh, and R. Wilhelm. A logic-based approach to data flow analysis problems. Acta Inf., 35(6):457- 504, June 1998.Google ScholarGoogle ScholarCross RefCross Ref
  21. 21.J. Stransky. A lattice for abstract interpretation of dynamic (Lisp-like) structures. Inf. and Comp., 101(1):70-102, Nov. 1992. Google ScholarGoogle ScholarDigital LibraryDigital Library
  22. 22.E. Y.-B. Wang. Analysis of Recursive Types in an Imperative Language. PhD thesis, Univ. of Calif., Berkeley, CA, 1994. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Parametric shape analysis via 3-valued logic

          Recommendations

          Comments

          Login options

          Check if you have access through your login credentials or your institution to get full access on this article.

          Sign in
          • Published in

            cover image ACM Conferences
            POPL '99: Proceedings of the 26th ACM SIGPLAN-SIGACT symposium on Principles of programming languages
            January 1999
            324 pages
            ISBN:1581130953
            DOI:10.1145/292540

            Copyright © 1999 ACM

            Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

            Publisher

            Association for Computing Machinery

            New York, NY, United States

            Publication History

            • Published: 1 January 1999

            Permissions

            Request permissions about this article.

            Request Permissions

            Check for updates

            Qualifiers

            • Article

            Acceptance Rates

            POPL '99 Paper Acceptance Rate24of136submissions,18%Overall Acceptance Rate824of4,130submissions,20%

            Upcoming Conference

            POPL '25

          PDF Format

          View or Download as a PDF file.

          PDF

          eReader

          View online with eReader.

          eReader