Advertisement

A compile-time memory-reuse scheme for concurrent logic programs

  • S. Duvvuru
  • R. Sundararajan
  • E. Tick
  • A. V. S. Sastry
  • L. Hansen
  • X. Zhong
Logic Programming Languages I
Part of the Lecture Notes in Computer Science book series (LNCS, volume 637)

Abstract

As large amounts of garbage are generated in concurrent logic programs, it becomes necessary to salvage used memory frequently and efficiently, with a garbage collector. Another approach is to detect when a data structure becomes garbage and reuse it. In concurrent languages it is particularly difficult to determine when a data structure is garbage and suitable for destructive update. Dynamic schemes, such as reference counting, incur space and time overheads that can be unacceptable. In contrast, static-analysis techniques identify data objects whose storage may be reused. Information from static analysis can be used by the compiler in generating appropriate instructions for reuse, incurring little or no runtime overhead. In this paper we present a new static-analysis technique for reuse detection. We present empirical performance measurements comparing the new scheme against binary reference counting (MRB). It is shown that, a simple static analysis can achieve most of the benefits of MRB and improve the execution time.

Keywords

static analysis garbage collection abstract interpretation 

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. 1.
    A. Bloss. Path Analysis and Optimization of Non-Strict Functional Languages. PhD thesis, Yale University, Dept. of Computer Science, New Haven, May 1989.Google Scholar
  2. 2.
    M. Bruynooghe et al. Abstract Interpretation: Towards the Global Optimization of Prolog Programs. In International Symposium on Logic Programming, pages 192–204. San Francisco, IEEE Computer Society, August 1987.Google Scholar
  3. 3.
    D. R. Chase, M. Wegman, and F. K. Zadeck. Analysis of Pointers and Structures. In SIGPLAN Conference on Programming Language Design and Implementation, pages 296–309, White Plains, NY, June 1990. ACM Press.Google Scholar
  4. 4.
    T. Chikayama and Y. Kimura. Multiple Reference Management in Flat GHC. In International Conference on Logic Programming, pages 276–293. University of Melbourne, MIT Press, May 1987.Google Scholar
  5. 5.
    C. Codognet, P. Codognet, and M. Corsini. Abstract Interpretation of Concurrent Logic Languages. In North American Conference on Logic Programming, pages 215–232. Austin, MIT Press, October 1990.Google Scholar
  6. 6.
    L. P. Deutsch and D. G. Bobrow. An Efficient Incremental, Automatic Garbage Collector. Communications of the ACM, 19:522–526, September 1976.CrossRefGoogle Scholar
  7. 7.
    S. Duvvuru. Monaco: A High Performance Architecture for Concurrent Logic Programs. Master's thesis, University of Oregon, June 1992.Google Scholar
  8. 8.
    I. Foster and W. Winsborough. A Computational Collecting Semantics for Strand. Research report, Argonne National Laboratory, 1990. unpublished.Google Scholar
  9. 9.
    I. Foster and W. Winsborough. Copy Avoidance through Compile-Time Analysis and Local Reuse. In International Symposium on Logic Programming, pages 455–469. San Diego, MIT Press, November 1991.Google Scholar
  10. 10.
    P. Hudak. A Semantic Model of Reference Counting and Its Abstraction. In Conference on Lisp and Functional Programming, pages 351–363, Cambridge, 1986. ACM Press.Google Scholar
  11. 11.
    P. Hudak and A. Bloss. The Aggregate Update Problem in Functional Programming Languages. In SIGPLAN Symposium on Principles of Programming Languages, pages 300–314, New Orleans, January 1985. ACM Press.Google Scholar
  12. 12.
    ICOT. PDSS Manual (Version 2.52e). 21F Mita Kokusai Bldg, 1-4-28 Mita, Minatoku Tokyo 108, Japan, February 1989.Google Scholar
  13. 13.
    Y. Inamura, N. Ichiyoshi, K. Rokusawa, and K. Nakajima. Optimization Techniques Using the MRB and Their Evaluation on the Multi-PSI/V2. In North American Conference on Logic Programming, pages 907–921. Cleveland, MIT Press, October 1989.Google Scholar
  14. 14.
    D. Jacobs and A. Langen. Accurate and Efficient Approximation of Variable Aliasing in Logic Programs. In North American Conference on Logic Programming, pages 154–165. Cleveland, MIT Press, October 1989.Google Scholar
  15. 15.
    A. Mulkers, W. Winsborough, and M. Bruynooghe. Analysis of Shared Data Structures for Compile-Time Garbage Collection in Logic Programs. In International Conference on Logic Programming, pages 747–762. Jerusalem, MIT Press, June 1990.Google Scholar
  16. 16.
    V. A. Saraswat, K. Kahn, and J. Levy. Janus: A Step Towards Distributed Constraint Programming. In North American Conference on Logic Programming, pages 431–446. Austin, MIT Press, October 1990.Google Scholar
  17. 17.
    A. V. S. Sastry and W. Clinger. Order-of-Evaluation Analysis for Destructive Updates in Strict Functional Languages with Flat Aggregates. Technical Report CIS-TR-92-14, University of Oregon, Computer Science Department, 1992.Google Scholar
  18. 18.
    D. Schmidt. Detecting Global Variables in Denotational Specifications. ACM Transactions on Programming Languages and Systems, 7(2):299–310, 1985.CrossRefGoogle Scholar
  19. 19.
    E. Y. Shapiro. The Family of Concurrent Logic Programming Languages. ACM Computing Surveys, 2l(3):413–510, September 1989.CrossRefGoogle Scholar
  20. 20.
    J. E. Stoy. Denotational Semantics: The Scott-Strachey Approach to Programming Language Theory. MIT Press, Cambridge MA, first edition, 1977.Google Scholar
  21. 21.
    R. Sundararajan. An Abstract Interpretation Scheme for Groundness, Freeness, and Sharing Analysis of Logic Programs. Technical Report CIS-TR-91-06, University of Oregon, Department of Computer Science, October 1991.Google Scholar
  22. 22.
    R. Sundararajan, A. V. S. Sastry, and E. Tick. Variable Threadedness Analysis for Concurrent Logic Programs. In Joint International Conference and Symposium on Logic Programming. Washington D.C., MIT Press, November 1992.Google Scholar
  23. 23.
    K. Ueda and M. Morita. A New Implementation Technique for Flat GHC. In International Conference on Logic Programming, pages 3–17. Jerusalem, MIT Press, June 1990.Google Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 1992

Authors and Affiliations

  • S. Duvvuru
    • 1
  • R. Sundararajan
    • 1
  • E. Tick
    • 1
  • A. V. S. Sastry
    • 1
  • L. Hansen
    • 1
  • X. Zhong
    • 1
  1. 1.University of OregonEugeneUSA

Personalised recommendations