Beltway: getting around garbage collection gridlock

We present the design and implementation of a new garbage collection framework that significantly generalizes existing copying collectors. The Beltway framework exploits and separates object age and incrementality. It groups objects in one or more increments on queues called belts, collects belts independently, and collects increments on a belt in first-in-first-out order. We show that Beltway configurations, selected by command line options, act and perform the same as semi-space, generational, and older-first collectors, and encompass all previous copying collectors of which we are aware. The increasing reliance on garbage collected languages such as Java requires that the collector perform well. We show that the generality of Beltway enables us to design and implement new collectors that are robust to variations in heap size and improve total execution time over the best generational copying collectors of which we are aware by up to 40%, and on average by 5 to 10%, for small to moderate heap sizes. New garbage collection algorithms are rare, and yet we define not just one, but a new family of collectors that subsumes previous work. This generality enables us to explore a larger design space and build better collectors.

[1]  Chris J. Cheney A nonrecursive list compacting algorithm , 1970, Commun. ACM.

[2]  Peter Boehler Bishop,et al.  Computer systems with a very large address space and garbage collection , 1977 .

[3]  David Ungar Generation scavenging: a nondisruptive high performance storage reclamation algorithm , 1984 .

[4]  David A. Moon,et al.  Garbage collection in a large LISP system , 1984, LFP '84.

[5]  David M. Ungar,et al.  Generation Scavenging: A non-disruptive high performance storage reclamation algorithm , 1984, SDE 1.

[6]  Andrew W. Appel,et al.  RETROSPECTIVE : Real-time Concurrent Collection on Stock Multiprocessors , 2004 .

[7]  Robert Courts,et al.  Improving locality of reference in a garbage-collecting memory management system , 1988, CACM.

[8]  Paul R. Wilson,et al.  A “card-marking” scheme for controlling intergenerational references in generation-based garbage collection on stock hardware , 1989, SIGP.

[9]  Paul R. Wilson A simple bucket-brigade advancement mechanism for generation-bases garbage collection , 1989, SIGP.

[10]  Andrew W. Appel,et al.  Simple generational garbage collection and fast allocation , 1989, Softw. Pract. Exp..

[11]  Benjamin G. Zorn,et al.  Comparative performance evaluation of garbage collection algorithms , 1989 .

[12]  Scott Shenker,et al.  Mostly parallel garbage collection , 1991, PLDI '91.

[13]  Barry Hayes Using key object opportunism to collect old objects , 1991, OOPSLA '91.

[14]  Paul R. Wilson,et al.  Uniprocessor Garbage Collection Techniques , 1992, IWMM.

[15]  A comparative performance evaluation of write barrier implementation , 1992, OOPSLA '92.

[16]  J. Eliot B. Moss,et al.  Incremental Collection of Mature Objects , 1992, IWMM.

[17]  Frank Jackson,et al.  An adaptive tenuring policy for generation scavengers , 1992, TOPL.

[18]  John H. Reppy A High-performance Garbage Collector for Standard ML , 1993 .

[19]  Urs Hölzle,et al.  A third-generation SELF implementation: reconciling responsiveness with performance , 1994, OOPSLA '94.

[20]  Benjamin G. Zorn,et al.  Garbage collection using a dynamic threatening boundary , 1995, PLDI '95.

[21]  Rafael Dueire Lins,et al.  Garbage collection: algorithms for automatic dynamic memory management , 1996 .

[22]  William D. Clinger,et al.  Generational garbage collection and the radioactive decay model , 1997, PLDI '97.

[23]  Mads Tofte,et al.  Region-based Memory Management , 1997, Inf. Comput..

[24]  Peter Lee,et al.  Generational stack collection and profile-driven pretenuring , 1998, PLDI.

[25]  David Gay,et al.  Memory management with explicit regions , 1998, PLDI.

[26]  Scott Nettles,et al.  A study of large object spaces , 1998, ISMM '98.

[27]  Alex Garthwaite,et al.  The GC Interface in the EVM 1 , 1998 .

[28]  Kathryn S. McKinley,et al.  Age-based garbage collection , 1999, OOPSLA '99.

[29]  Darko Stefanovic,et al.  Properties of age-based automatic memory reclamation algorithms , 1999 .

[30]  Urs Hölzle,et al.  A Study of the Allocation Behavior of the SPECjvm98 Java Benchmark , 1999, ECOOP.

[31]  Bowen Alpern,et al.  Implementing jalapeño in Java , 1999, OOPSLA '99.

[32]  Ron Cytron,et al.  Contaminated garbage collection , 2000, PLDI '00.

[33]  Stephen J. Fink,et al.  The Jalapeño virtual machine , 2000, IBM Syst. J..

[34]  Lars Thomas Hansen,et al.  Older-First Garbage Collection in Practice , 2000 .

[35]  Bjarne Steensgaard,et al.  Thread-specific heaps for multi-threaded programs , 2000, ISMM '00.

[36]  Guy E. Blelloch,et al.  A parallel, real-time garbage collector , 2001, PLDI '01.

[37]  Kathryn S. McKinley,et al.  Pretenuring for Java , 2001, OOPSLA '01.

[38]  Chang Li,et al.  Controlling garbage collection and heap growth to reduce the execution time of Java applications , 2001, OOPSLA '01.

[39]  Kathryn S. McKinley,et al.  In or out?: putting write barriers in their place , 2002, ISMM '02.