skip to main content
article

Bounding space usage of conservative garbage collectors

Published: 01 January 2002 Publication History

Abstract

Conservative garbage collectors can automatically reclaim unused memory in the absence of precise pointer location information. If a location can possibly contain a pointer, it is treated by the collector as though it contained a pointer. Although it is commonly assumed that this can lead to unbounded space use due to misidentified pointers, such extreme space use is rarely observed in practice, and then generally only if the number of misidentified pointers is itself unbounded.We show that if the program manipulates only data structures satisfying a simple GC-robustness criterion, then a bounded number of misidentified pointers can at most result in increasing space usage by a constant factor. We argue that nearly all common data structures are already GC-robust, and it is typically easy to identify and replace those that are not. Thus it becomes feasible to prove space bounds on programs collected by mildly conservative garbage collectors, such as the one in [2]. The worst-case space overhead introduced by such mild conservatism is comparable to the worst-case fragmentation overhead for inherent in any non-moving storage allocator.The same GC-robustness criterion also ensures the absence of temporary space leaks of the kind discussed in [13] for generational garbage collectors.

References

[1]
A. Appel. Compiling with Continuations. Cambridge University Press, 1992.
[2]
K. Barabash, N. Buchbinder, T. Domani, B. K. Kolodner, Y. Ossia, S. S. Pinter, J. Shepherd, R. Sivan, and V. Umansky. Mostly accurate stack scanning. In Proceedings of the Usenix Java Virtual Machine gesearvh and Technology Symposium, April 2001.
[3]
J. F. Bartlett. Compacting garbage collection with ambiguous roots. Lisp Pointers, pages 3-12, April-June 1988.
[4]
H.-J. Boehm. Space efficient conservative garbage collection. In SIGPLAN '93 Confervnce on Programming Language Design and Implementation, pages 197-206, June 1993.
[5]
D. R. Chase. Safety considerations for storage allocation optimization. In SIGPLAN '88 Confervnce on Programming Language Design and Implementation, pages 1-10, June 1988.
[6]
W. D. Clinger. Proper tail recursion and space efficiency. In SIGPLAN '98 Conference on Programming Language Design and Implementation, pages 174-185, June 1998.
[7]
M. R. Garey and D. S. Johnson. Computers and Intractability: A Guide to the Theory of NiP-Completeness. W. H. Freeman and Company, 1979.
[8]
M. Hirzel and A. Diwan. On the type accuracy of garbage collection. In Proceedings of the International Symposium on Memory Management 2000, pages 1-11, October 2000.
[9]
R. L. Hudson and J. E. B. Moss. Incremental collection of mature objects. In Proceedings of the 1992 International Workshop on Memory Management (LNCS 637), pages 92-109. Springer, 1992.
[10]
S. Liang. The Java Native Interface: Programmer's Guide and Specification. Addison-Wesley, 1999.
[11]
J. M. Robson. An estimate of the store size necessary for dynamic storage allocation. Journal of the ACM, 18(3):416-42a, 1971.
[12]
J. M. Robson. Bounds for some functions concerning dynamic storage allocation. Journal of the AUM, 21(3):491-499, 1974.
[13]
N. Rojemo. Generational garbage collection without temporary space leaks. In Prvceedings of the 1995 International Workshop on Memory Management (LNCS 986), pages 145 162. Springer, 1995.
[14]
M. Serrano and H.-J. Boehm. Understanding memory allocation of Scheme programs. In Prvceedings of the 2000 International Confervnce on Functional Programming (ICFP), pages 245 256, 2000.
[15]
M. Wiser, A. Demers, and C. Hauser. The portable common runtime approach to interoperability. In Pwceedings of the 12th ACM Symposium on Operating Systems Principles, December 1989.
[16]
E. Wentworth. Pitfalls of conservative garbage collection. Sol, ware Practice and Experience, 20(7):719-727, 1990.

Cited By

View all
  • (2024)Sticky Tags: Efficient and Deterministic Spatial Memory Error Mitigation using Persistent Memory Tags2024 IEEE Symposium on Security and Privacy (SP)10.1109/SP54263.2024.00263(4239-4257)Online publication date: 19-May-2024
  • (2022)MineSweeper: a “clean sweep” for drop-in use-after-free preventionProceedings of the 27th ACM International Conference on Architectural Support for Programming Languages and Operating Systems10.1145/3503222.3507712(212-225)Online publication date: 28-Feb-2022
  • (2018)A Functional Paradigm using the C Language for Teaching Programming for Engineers2018 XLIV Latin American Computer Conference (CLEI)10.1109/CLEI.2018.00103(820-828)Online publication date: Oct-2018
  • Show More Cited By

Recommendations

Comments

Information & Contributors

Information

Published In

cover image ACM SIGPLAN Notices
ACM SIGPLAN Notices  Volume 37, Issue 1
Jan. 2002
342 pages
ISSN:0362-1340
EISSN:1558-1160
DOI:10.1145/565816
Issue’s Table of Contents
  • cover image ACM Conferences
    POPL '02: Proceedings of the 29th ACM SIGPLAN-SIGACT symposium on Principles of programming languages
    January 2002
    351 pages
    ISBN:1581134509
    DOI:10.1145/503272
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: 01 January 2002
Published in SIGPLAN Volume 37, Issue 1

Check for updates

Qualifiers

  • Article

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • Downloads (Last 12 months)9
  • Downloads (Last 6 weeks)1
Reflects downloads up to 10 Nov 2024

Other Metrics

Citations

Cited By

View all
  • (2024)Sticky Tags: Efficient and Deterministic Spatial Memory Error Mitigation using Persistent Memory Tags2024 IEEE Symposium on Security and Privacy (SP)10.1109/SP54263.2024.00263(4239-4257)Online publication date: 19-May-2024
  • (2022)MineSweeper: a “clean sweep” for drop-in use-after-free preventionProceedings of the 27th ACM International Conference on Architectural Support for Programming Languages and Operating Systems10.1145/3503222.3507712(212-225)Online publication date: 28-Feb-2022
  • (2018)A Functional Paradigm using the C Language for Teaching Programming for Engineers2018 XLIV Latin American Computer Conference (CLEI)10.1109/CLEI.2018.00103(820-828)Online publication date: Oct-2018
  • (2017)Limitations of Partial CompactionACM Transactions on Programming Languages and Systems10.1145/299459739:1(1-44)Online publication date: 6-Mar-2017
  • (2015)Resource Management in Native Languages Using Dynamic Binary Instrumentation (PIN)Advanced Computing and Systems for Security10.1007/978-81-322-2653-6_8(107-119)Online publication date: 19-Nov-2015
  • (2014)Mutable checkpoint-restartProceedings of the 15th International Middleware Conference10.1145/2663165.2663328(133-144)Online publication date: 8-Dec-2014
  • (2013)Cross-compiling Java to JavaScript via tool-chainingProceedings of the 2013 International Conference on Principles and Practices of Programming on the Java Platform: Virtual Machines, Languages, and Tools10.1145/2500828.2500831(25-34)Online publication date: 11-Sep-2013
  • (2012)Running Android Applications without a Virtual MachineMobile Wireless Middleware, Operating Systems, and Applications10.1007/978-3-642-30607-5_12(121-134)Online publication date: 2012
  • (2010)Cross-compiling Android applications to the iPhoneProceedings of the 8th International Conference on the Principles and Practice of Programming in Java10.1145/1852761.1852772(69-77)Online publication date: 15-Sep-2010
  • (2009)Garbage Collection TechniquesThe Compiler Design Handbook10.1201/9781420043839.ch6(6-1-6-35)Online publication date: 7-Dec-2009
  • Show More Cited By

View Options

Get Access

Login options

View options

PDF

View or Download as a PDF file.

PDF

eReader

View online with eReader.

eReader

Media

Figures

Other

Tables

Share

Share

Share this Publication link

Share on social media