skip to main content
10.1145/1375581.1375586acmconferencesArticle/Chapter ViewAbstractPublication PagespldiConference Proceedingsconference-collections
research-article

Immix: a mark-region garbage collector with space efficiency, fast collection, and mutator performance

Published:07 June 2008Publication History

ABSTRACT

Programmers are increasingly choosing managed languages for modern applications, which tend to allocate many short-to-medium lived small objects. The garbage collector therefore directly determines program performance by making a classic space-time tradeoff that seeks to provide space efficiency, fast reclamation, and mutator performance. The three canonical tracing garbage collectors: semi-space, mark-sweep, and mark-compact each sacrifice one objective. This paper describes a collector family, called mark-region, and introduces opportunistic defragmentation, which mixes copying and marking in a single pass. Combining both, we implement immix, a novel high performance garbage collector that achieves all three performance objectives. The key insight is to allocate and reclaim memory in contiguous regions, at a coarse block grain when possible and otherwise in groups of finer grain lines. We show that immix outperforms existing canonical algorithms, improving total application performance by 7 to 25% on average across 20 benchmarks. As the mature space in a generational collector, immix matches or beats a highly tuned generational collector, e.g. it improves jbb2000 by 5%. These innovations and the identification of a new family of collectors open new opportunities for garbage collector design.

References

  1. D. Abuaiadh, Y. Ossia, E. Petrank, and U. Silbershtein. An efficient parallel heap compaction algorithm. In ACM Conference on Object?Oriented Programming, Systems, Languages, and Applications, pages 224--236, Vancouver, BC, Canada, 2004. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. B. Alpern, D. Attanasio, J. J. Barton, M. G. Burke, P.Cheng, J.-D. Choi, A. Cocchi, S. J. Fink, D. Grove, M. Hind, S. F. Hummel, D. Lieber, V. Litvinov, M. Mergen, T. Ngo, J. R. Russell, V. Sarkar, M. J. Serrano, J. Shepherd, S. Smith, V. C. Sreedhar, H. Srinivasan, and J. Whaley. The Jalapeño virtual machine. IBM System Journal, 39(1), Feb. 2000. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. B. Alpern, D. Attanasio, J. J. Barton, A. Cocchi, S. F. Hummel, D. Lieber, M. Mergen, T. Ngo, J. Shepherd, and S. Smith. Implementing Jalapeño in Java. In ACM Conference on Object?Oriented Programming, Systems, Languages, and Applications, Denver, CO, Nov. 1999. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. A. W. Appel. Simple generational garbage collection and fast allocation. Software Practice and Experience, 19(2):171--183, 1989. Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. M. Arnold, S. J. Fink, D. Grove, M. Hind, and P. Sweeney. Adaptive optimization in the Jalape?no JVM. In ACM Conference on Object?Oriented Programming, Systems, Languages, and Applications, pages 47--65, Minneapolis, MN, October 2000. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. C. Attanasio, D. Bacon, A. Cocchi, and S. Smith. A comparative evaluation of parallel garbage collectors. In Proceedings of the Workshop on Languages and Compilers for Parallel Computing, Cumberland Falls, KY, Aug. 2001. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. D. F. Bacon, P. Cheng, and V. T. Rajan. Controlling fragmentation and space consumption in the Metronome a real-time garbage collector for Java. In ACM Conference on Languages, Compilers, and Tools for Embedded Systems, pages 81--92, San Diego, CA, June 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. D. F. Bacon, P. Cheng, and V. T. Rajan. A real-time garbage collector with low overhead and consistent utilization. In ACM Symposium on the Principles of Programming Languages, pages 285--294, New Orleans, LA, Jan. 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. H. G. Baker. List processing in real-time on a serial computer. Communications of the ACM, 21(4):280--94, 1978. Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. K. Barabash, O. Ben-Yitzhak, I. Goft, E. K. Kolodner, V. Leikehman, Y. Ossia, A. Owshanko, and E. Petrank. A parallel, incremental, mostly concurrent garbage collector for servers. ACM Transactions on Programming Languages and Systems, 27(6):1097--1146, 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. BEA Systems Inc. Using the JRockit runtime analyzer. http://edocs.bea.com/wljrockit/docs142/usingJRA/looking.html, 2007.Google ScholarGoogle Scholar
  12. S. M. Blackburn, P. Cheng, and K. S. McKinley. Myths and realities: The performance impact of garbage collection. In Proceedings of the ACM Conference on Measurement & Modeling Computer Systems, pages 25--36, NY, NY, June 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. S. M. Blackburn, P. Cheng, and K. S. McKinley. Oil and water? High performance garbage collection in Java with MMTk. In Proceedings of the 26th International Conference on Software Engineering, pages 137--146, Scotland, UK, May 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  14. S. M. Blackburn, R. Garner, C. Hoffman, A. M. Khan, K. S. McKinley, R. Bentzur, A. Diwan, D. Feinberg, D. Frampton, S. Z. Guyer, M. Hirzel, A. Hosking, M. Jump, H. Lee, J. E. B. Moss, A. Phansalkar, D. Stefanović, T. VanDrunen, D. von Dincklage, and B. Wiedermann. The DaCapo benchmarks: Java benchmarking development and analysis. In ACM Conference on Object?Oriented Programming, Systems, Languages, and Applications, pages 169--190, Portland, OR, USA, Oct. 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. S. M. Blackburn, R. Garner, C. Hoffman, A. M. Khan, K. S. McKinley, R. Bentzur, A. Diwan, D. Feinberg, D. Frampton, S. Z. Guyer, M. Hirzel, A. Hosking, M. Jump, H. Lee, J. E. B. Moss, A. Phansalkar, D. Stefanović, T. VanDrunen, D. von Dincklage, and B. Wiedermann. The DaCapo Benchmarks: Java benchmarking development and analysis (extended version). Technical Report TR-CS-06-01, Dept. of Computer Science, Australian National University, 2006. http://www.dacapobench.org.Google ScholarGoogle Scholar
  16. S. M. Blackburn and A. Hosking. Barriers: Friend or foe? In The ACM International Symposium on Memory Management, pages 143--151, Vancouver, BC, Canada, Oct. 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. S. M. Blackburn, R. E. Jones, K. S. McKinley, and J. E. B. Moss. Beltway: Getting around garbage collection gridlock. In ACM Conference on Programming Language Design and Implementation, pages 153--164, Berlin, Germany, June 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. S. Borman. Sensible sanitation ? understanding the IBM Java garbage collector. http://www.ibm.com/developerworks/ibm/library/i-garbage1/, Aug. 2002.Google ScholarGoogle Scholar
  19. C. J. Cheney. A nonrecursive list compacting algorithm. Communications of the ACM, 13(11):677--678, Nov. 1970. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. J. Cohen and A. Nicolau. Comparison of compacting algorithms for garbage collection. ACM Transactions on Programming Languages and Systems, 5(4):532--553, Oct. 1983. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. A. Demmers, M. Weiser, B. Hayes, H. Boehm, D. Bobrow, and S. Shenker. Combining generational and conservative garbage collection: framework and implementations. In ACM Symposium on the Principles of Programming Languages, pages 261--269, San Francisco, California, United States, 1990. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  22. D. Detlefs, C. Flood, S. Heller, and T. Printezis. Garbage-first garbage collection. In The ACM International Symposium on Memory Management, Vancouver, BC, Canada, Oct. 2004. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. T. Domani, E. K. Kolodner, and E. Petrank. A generational on-the-fly garbage collector for java. In PLDI ?00: Proceedings of the ACM SIGPLAN 2000 conference on Programming language design and implementation, pages 274--284, Vancouver, British Columbia, Canada, 2000. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  24. Q. Feng and E. Berger. A locality improving dynmaic memory allocator. In The ACM Workshop Memory Systems Performance, pages 68--77, Chicago, IL, June 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  25. D. Frampton, D. F. Bacon, P. Cheng, and D. Grove. Generational realtime garbage collection: A a three-part invention for young obects. In European Conference on Object-Oriented Programming, pages 101--125, Berlin, Germany, July 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  26. R. L. Hudson and J. E. B. Moss. Incremental collection of mature objects. In Proceedings of the International Workshop on Memory Management, number 637 in Lecture Notes on Computer Science, pages 388--403. Springer-Verlag, 1992. Google ScholarGoogle ScholarDigital LibraryDigital Library
  27. Jikes RVMCore Team. VMperformance comparisons. http://jikesrvm.anu.edu.au/~dacapo/index.php?category=release, 2007.Google ScholarGoogle Scholar
  28. H. Kermany and E. Petrank. The compressor: concurrent, incremental, and parallel compaction. In ACM Conference on Programming Language Design and Implementation, pages 354--363, Ottawa, Ontario, Canada, 2006. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  29. D. Lea. A memory allocator. Technical report, SUNY at Oswego, 1996.Google ScholarGoogle Scholar
  30. J. McCarthy. Recursive functions of symbolic expressions and their computation by machine, Part I. Commun. ACM, 3(4):184--195, 1960. Google ScholarGoogle ScholarDigital LibraryDigital Library
  31. P. McGachey and A. L. Hosking. Reducing generational copy reserve overhead with fallback compaction. In The ACM International Symposium on Memory Management, pages 17--28, Ottawa, CA, June 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  32. M. Pettersson. Linux Intel/x86 performance counters, 2003. http://user.it.uu.se/~mikpe/linux/perfctr/.Google ScholarGoogle Scholar
  33. N. Sachindran, J. E. B. Moss, and E. D. Berger. MC2: High-performance garbage collectionn for memory-constrained environments. In ACM Conference on Object?Oriented Programming, Systems, Languages, and Applications, pages 81--98, Vancouver, Canada, Oct. 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  34. D. Spoonhower, G. Blelloch, and R. Harper. Using page residency to balance tradeoffs in tracing garbage collection. In ACM International Conference on Virtual Execution Environments, Chicago, IL, June 2005. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  35. Standard Performance Evaluation Corporation. SPECjbb2000 Documentation, release 1.01 edition, 2001.Google ScholarGoogle Scholar
  36. D. Stefanović, K. S. McKinley, and J. E. B. Moss. Age-based garbage collection. In ACM Conference on Object?Oriented Programming, Systems, Languages, and Applications, Denver, CO, Nov. 1999. Google ScholarGoogle ScholarDigital LibraryDigital Library
  37. P. Styger. LISP 2 garbage collector specifications. Technical Report TM-3417/500/00 1, System Development Cooperation, Santa Monica, CA, Apr. 1967.Google ScholarGoogle Scholar

Index Terms

  1. Immix: a mark-region garbage collector with space efficiency, fast collection, and mutator performance

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

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!