skip to main content
article
Free Access

Age-based garbage collection

Authors Info & Claims
Published:01 October 1999Publication History
Skip Abstract Section

Abstract

Modern generational garbage collectors look for garbage among the young objects, because they have high mortality; however, these objects include the very youngest objects, which clearly are still live. We introduce new garbage collection algorithms, called age-based, some of which postpone consideration of the youngest objects. Collecting less than the whole heap requires write barrier mechanisms to track pointers into the collected region. We describe here a new, efficient write barrier implementation that works for age-based and traditional generational collectors. To compare several collectors, their configurations, and program behavior, we use an accurate simulator that models all heap objects and the pointers among them, but does not model cache or other memory effects. For object-oriented languages, our results demonstrate that an older-first collector, which collects older objects before the youngest ones, copies on average much less data than generational collectors. Our results also show that an older-first collector does track more pointers, but the combined cost of copying and pointer tracking still favors an older-first over a generational collector in many cases. More importantly, we reopen for consideration the question where in the heap and with which policies copying collectors will achieve their best performance.

References

  1. 1 Appel, A. W. Simple generational garbage collection and fast allocation. Software Practice and Experience 19, 2 (1989), 171- 183. Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. 2 Baker, H. G. List processing in real-time on a serial computer. Commun. ACM 21, 4 (1978), 280-94. Also AI Laboratory Working Paper 139, 1977. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. 3 Baker, H. G. 'infant Mortality' and generational garbage collection. SIGPLAN Notices 28, 4 (1993), 55-57. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. 4 Barendregt, H.P. The Lambda Calculus: Its Syntax and Semantics. Elsevier (North-Holland), Amsterdam, 1984. Second edition.Google ScholarGoogle Scholar
  5. 5 Barrett, D. A., and Zorn, B. Garbage collection using a dynamic threatening boundary. In Proceedings of SIGPLAN'95 Conference on Programming Languages Design and Implementation (La Jolla, CA, June 1995), vol. 30 of SIGPLAN Notices, ACM Press, pp. 301-314. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. 6 Bekkers, Y., Canet, B., Ridoux, O., and Ungaro, L. MALI: A memory with a real-time garbage collector for implementing logic programming languages, in 3rd Symposium on Logic Programming (1986), IEEE Press, pp. 258-264.Google ScholarGoogle Scholar
  7. 7 Bekkers, Y., and Cohen, J., Eds. International Workshop on Memory Management (St. Malo, France, Sept. 1992), no. 637 in Lecture Notes in Computer Science, Springer-Verlag. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. 8 Bishop, P.B. Computer Systems with a Very Large Address Space and Garbage Collection. PhD thesis, Massachusetts Institute of Technology, Cambridge, MA, May 1977.Google ScholarGoogle Scholar
  9. 9 Cheney, C. J. A nonrecursive list compacting algorithm. Commun. ACM 13, 11 (Nov. 1970), 677--678. Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. 10 Cheng, P., Harper, R., and Lee, P. Generational stack collection and profile-driven pretenuring. In Proceedings of SIGPLAN'98 Conference on Programming Languages Design and Implementation (Montreal, Qurbec, Canada, June 1998), vol. 33 of SIG- PLAN Notices, ACM Press, pp. 162-173. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. 11 Clinger, W. D., and Hansen, L. T. Generational garbage collection and the radioactive decay model. SIGPLAN Notices 32, 5 (May 1997), 97-108. Proceedings of the ACM SIGPLAN '97 Conference on Programming Language Design and Implementation. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. 12 Goldberg, A., and Robson, D. Smalltalk-80: The Language and its Implementation. Addison-Wesley, 1983. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. 13 Hayes, B. Key Objects in Garbage Collection. PhD thesis, Stanford University, Stanford, California, Mar. 1993. Google ScholarGoogle ScholarDigital LibraryDigital Library
  14. 14 Hosking, A. L., and Hudson, R. L. Remembered sets can also play cards. In OOPSI_A/ECOOP '93 Workshop on Garbage Collection in Object-Oriented Systems (Oct. 1993), E. Moss, P. R. Wilson, and B. Zorn, Eds.Google ScholarGoogle Scholar
  15. 15 Hosking, A. L., Moss, J. E. B., and Stefanovir, D. A comparative performance evaluation of write barrier implementations. In Proceedings of the Conference on Object-Oriented Programming Systems, Languages, and Applications (Vancouver, Canada, Oct. 1992), SIGPLAN Notices 27, 10 (Oct. 1992), pp. 92-109. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. 16 Hudson, R. L., and Moss, J. E.B. Incremental collection of mature objects. In Bekkers and Cohen {7}, pp. 388--403. Google ScholarGoogle Scholar
  17. 17 Jones, R., and Lins, R. Garbage Collection: Algorithms for Automatic Dynamic Memory Management. John Wiley, Chichester, 1996. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. 18 Lang, B., and Dupont, F. Incremental incrementally compacting garbage collection. In SIGPLAN'87 Symposium on Interpreters and Interpretive Techniques (Inst. Rech. Informat. Automat. Lab., France, 1987), vol. 22(7) of SIGPLAN Notices, ACM Press, pp. 253-263. Google ScholarGoogle ScholarDigital LibraryDigital Library
  19. 19 Lieberman, H., and Hewitt, C. A real-time garbage collector based on the lifetimes of objects. Commun. ACM 26, 6 (June 1983), 419-429. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. 20 Moon, D. Garbage collection in a large Lisp system. In Proceedings of the A CM Symposium on Lisp and Functional Programming (Austin, TX, Aug. 1984), pp. 235-246. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. 21 Nystrom, N. Bytecode-level analysis and optimization of Java class files. Master's thesis, Purdue University, West Lafayette, IN, May 1998.Google ScholarGoogle Scholar
  22. 22 Odersky, M., and Wadler, P. Pizza into Java: translating theory into practice. In POPL '97. Proceedings of the 24th ACM SIGPLAN-SIGACT symposium on Principles of programming (New York, 1997), ACM Press, pp. 146-159. Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. 23 Proebsting, T. A., Townsend, G., Bridges, P., Hartman, J. H., Newsham, T., and Watterson, S.A. Toba: Java for applications, a way ahead of time (WAT) compiler. (at http://www.cs.arizona.edu/sumatra/toba/), 1998.Google ScholarGoogle Scholar
  24. 24 Sobalvarro, P. G. A lifetime-based garbage collector for LISP systems on general-purpose computers, 1988. B.S. Thesis, Dept. of EECS, Massachusetts Institute of Technology, Cambridge.Google ScholarGoogle Scholar
  25. 25 Stefanovir, D. Properties of Age-Based Automatic Memory Reclamation Algorithms. PhD thesis, University of Massachusetts, Amherst, MA, Feb. 1999. Google ScholarGoogle ScholarDigital LibraryDigital Library
  26. 26 Stefanovi6, D., and Moss, J. E. B. Characterisation of object behaviour in Standard ML of New Jersey. In 1994 ACM Conference on Lisp and Functional Programming (Orlando, Florida, June 1994), ACM Press. Google ScholarGoogle ScholarDigital LibraryDigital Library
  27. 27 Ungar, D. Generation scavenging: A non-disruptive high performance storage reclamation algorithm. In Proceedings of the ACM SIGSOFT/SIGPLAN Software Engineering Symposium on Practical Software Development Environments (Pittsburgh, Pennsylvania, Apr. 1984), SIGPLAN Notices 19, 5 (May 1984), pp. 157-167. Google ScholarGoogle ScholarDigital LibraryDigital Library
  28. 28 Ungar, D. M. The Design and Evaluation of a High Performance Smalltalk System. ACM distinguished dissertation 1986. MIT Press, 1986. Google ScholarGoogle ScholarDigital LibraryDigital Library
  29. 29 Ungar, D. M., and Jackson, E Tenuring policies for generationbased storage reclamation. SIGPLAN Notices 23, 11 (1988), 1-17. Google ScholarGoogle ScholarDigital LibraryDigital Library
  30. 30 Ungar, D. M., and Jackson, F. An adaptive tenuring policy for generation scavengers. ACM Transactions on Programming Languages and Systems 14, 1 (1992), 1-27. Google ScholarGoogle ScholarDigital LibraryDigital Library
  31. 31 Wilson, P. R. A simple bucket-brigade advancement mechanism for generation-based garbage collection. SIGPLAN Notices 24, 5 (May 1989), 38--46. Google ScholarGoogle ScholarDigital LibraryDigital Library
  32. 32 Wilson, P. R. Uniprocessor garbage collection techniques. In Bekkers and Cohen {7}, pp. 1-42. Google ScholarGoogle Scholar
  33. 33 Wilson, P. R., and Moher, T. G. A "card-marking" scheme for controlling intergenerational references in generation-based garbage collection on stock hardware. SIGPLAN Notices 24, 5 (May 1989), 87-92. Google ScholarGoogle ScholarDigital LibraryDigital Library
  34. 34 Wilson, P. R., and Moher, T.G. Design of the opportunistic garbage collector. In Proceedings of the Conference on Object- Oriented Programming Systems, Languages, and Applications (New Orleans, Louisiana, Oct. 1989), SIGPLAN Notices 24, 10 (Oct. 1989), pp. 23-35. Google ScholarGoogle ScholarDigital LibraryDigital Library
  35. 35 Zorn, B. Barrier methods for garbage collection. Tech. Rep. CU-CS-494-90, University of Colorado at Boulder, Nov. 1990.Google ScholarGoogle Scholar
  36. 36 Zorn, B. G. Comparative Performance Evaluation of Garbage Collection Algorithms. PhD thesis, University of California at Berkeley, Dec. 1989. Available as Technical Report UCB/CSD 89/544. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Age-based garbage collection

        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

        Full Access

        • Published in

          cover image ACM SIGPLAN Notices
          ACM SIGPLAN Notices  Volume 34, Issue 10
          Oct. 1999
          460 pages
          ISSN:0362-1340
          EISSN:1558-1160
          DOI:10.1145/320385
          Issue’s Table of Contents
          • cover image ACM Conferences
            OOPSLA '99: Proceedings of the 14th ACM SIGPLAN conference on Object-oriented programming, systems, languages, and applications
            October 1999
            462 pages
            ISBN:1581132387
            DOI:10.1145/320384

          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 October 1999

          Check for updates

          Qualifiers

          • article

        PDF Format

        View or Download as a PDF file.

        PDF

        eReader

        View online with eReader.

        eReader