skip to main content
research-article

Adaptive scanning reduces sweep time for the Lisp2 mark-compact garbage collector

Published:20 June 2013Publication History
Skip Abstract Section

Abstract

Mark-compact garbage collection helps long-running programs avoid fragmentation. The Lisp2 mark-compact collector is a classic but still widely-used compaction algorithm. It sequentially scans the entire heap to compact all live objects at one end of the heap while preserving their order of addresses. Since the heap is generally large, this scanning takes a long time. Although some collectors adopt a separate bitmap into which mark bits of objects are stored to reduce the scanning time, we observed that scanning the bitmap can take longer than scanning the heap if objects are densely located. We propose a new scanning method from this observation, which adaptively alternates methods of scanning depending on heap usage; it scans those parts of the heap where live objects are densely located whereas it scans the bitmap for the remaining parts. We implemented this scanning method in the Lisp2 collector of Jikes RVM.

The experimental results revealed that the adaptive scanner scanned faster than the method that only scanned the heap and the method that only scanned the bitmap.

References

  1. D. Abuaiadh, Y. Ossia, E. Petrank, and U. Silbershtein.An efficient parallel heap compaction algorithm. Proceedings of the 19th Annual ACM SIGPLAN Conferenceon Object-Oriented Programming Systems, Languages, and Applications Languages, and Applications(OOPSLA 2004), 224--236, 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. B. Alpern et al.The Jikes Research Virtual Machine project: Building an opensource research community. IBM Systems Journal,44(2):399--417, 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. S. M. Blackburn, P. Cheng, and K. S. McKinley. Myths and realities: The performance impact of garbage collection. Proceedings of the ACM International Conference onMeasurements and Modeling Computer Systems (SIGMETRICS 2004),25--36, 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. S. M. Blackburn et al. The DaCapo benchmarks: Java benchmarking development and analysis. Proceedings of the 21st Annual ACM SIGPLAN Conferenceon Object-Oriented Programming Systems, Languages, and Applications(OOPSLA 2006), 169--190, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. H. J. Boehm and M. Weiser.Garbage collection in an uncooperative environment. Software Practice & Experience, 18(9):807--820, 1988. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. Y. C. Chung, S.-M. Moon, K. Ebcioğlu, and D. Sahlin. Reducing sweep time for a nearly empty heap. Proceedings of the 27th ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages (POPL 2000), 378--389, 2000. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. B. Hayes. Using key object opportunism to collect old objects. Proceedings of the 6th Annual ACM SIGPLAN Conference on Object-Oriented Programming Systems, Languages, and Applications (OOPSLA 1991), 33--46, 1991. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. R. Jones, A. Hosking, and E. Moss. The Garbage Collection Handbook. Chapman and Hall/CRC Press, 2012. Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. R. Jones and R. Lins. Garbage Collection Algorithms for Automatic Dynamic Memory Management.John Wiley and Sons, New York, 1996. Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. H. Kermany and E. Petrank. The Compressor: concurrent, incremental, and parallel compaction. Proceedings of the ACM SIGPLAN 2006 Conference on Programming Language Design and Implementation (PLDI 2006), 354--363, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. X.-F. Li, L. Wang, and C. Yang. A fully parallel LISP2 compactor with preservation of the sliding properties. Proceedings of Languages and Compilers for Parallel Computing (LCPC 2008),LNCS 5335, 264--278, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. P. McGachey and A. L. Hosking.Reducing generational copy reserve overhead with fallback compaction. Proceedings of the 5th International Symposium on Memory Management (ISMM 2006), 17--28, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. Sun Microsystems. Memory management in the Java HotSpot(™) virtual machine.http://www.oracle.com/technetwork/java/javase/ memorymanagement-whitepaper-50215.pdf, 2006.Google ScholarGoogle Scholar
  14. G. D. Ripley, R. E. Griswold, and D. R. Hanson. Performance of storage management in an implementation of SNOBOL4. IEEE Transactions on Software Engineering, 4(2):130--137, 1978. Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. P. G. Sobalvarro. A lifetime-based garbage collector for lisp systems on general-purpose computers. Technical report, MIT, 1988. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. L. Tong and F. C. M. Lau. Index-compact garbage collection. Proceedings of the 8th Asian conference on Programming Languages and Systems (APLAS 2010),LNCS 6461, 271--286, 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. K. Ueno, A. Ohori, and T. Otomo. An efficient non-moving garbage collector for functional languages. Proceedings of the ACM SIGPLAN Conference on Functional programming (ICFP 2011), 196--208, 2011. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. D. Ungar. Generation scavenging: A non-disruptive high performance storagereclamation algorithm. Proceedings of the first ACM SIGSOFT/SIGPLAN Software Engineering Symposium on Practical Software Development Environments(SDE 1984), 157--167, 1984. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Adaptive scanning reduces sweep time for the Lisp2 mark-compact garbage collector

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 48, Issue 11
    ISMM '13
    November 2013
    128 pages
    ISSN:0362-1340
    EISSN:1558-1160
    DOI:10.1145/2555670
    Issue’s Table of Contents
    • cover image ACM Conferences
      ISMM '13: Proceedings of the 2013 international symposium on memory management
      June 2013
      140 pages
      ISBN:9781450321006
      DOI:10.1145/2491894

    Copyright © 2013 ACM

    Publisher

    Association for Computing Machinery

    New York, NY, United States

    Publication History

    • Published: 20 June 2013

    Check for updates

    Qualifiers

    • research-article

PDF Format

View or Download as a PDF file.

PDF

eReader

View online with eReader.

eReader
About Cookies On This Site

We use cookies to ensure that we give you the best experience on our website.

Learn more

Got it!