Affiliation:
1. Massachusetts Institute of Technology, Cambridge, MA
Abstract
We present a new analysis for removing unnecessary write barriers in programs that use generational garbage collection. To our knowledge, this is the first static program analysis for this purpose. Our algorithm uses a pointer analysis to locate assignments that always create a reference from a younger object to an older object, then transforms the program to remove the write barriers normally associated with such assignments. We have implemented two transformations that reorder object allocations; these transformations can significantly increase the effectiveness of our write barrier removal algorithm.Our base technique assumes that the collector promotes objects in age order. We have developed an extension that enables the optimistic removal of write barriers, with the collector lazily adding each newly promoted object into a remembered set of objects whenever the compiler may have removed write barriers involving the object at statements that have yet to execute. This mechanism enables the application of our technique to virtually any memory management system that uses write barriers to enable generational garbage collection.Results from our implemented system show that our technique can remove substantial numbers of write barriers from the majority of the programs in our benchmark set, producing modest performance improvements of up to 6% of the overall execution time. Moreover, by dynamically instrumenting the executable, we are able to show that for six of our nine benchmark programs, our analysis is close to optimal in the sense that it removes the write barriers for almost all assignments that do not, in the observed execution, create a reference from an older object to a younger object. Finally, our results show that the overhead of our optimistic extension is negligible.
Publisher
Association for Computing Machinery (ACM)
Subject
Computer Graphics and Computer-Aided Design,Software
Cited by
7 articles.
订阅此论文施引文献
订阅此论文施引文献,注册后可以免费订阅5篇论文的施引文献,订阅后可以查看论文全部施引文献
1. Design and analysis of field-logging write barriers;Proceedings of the 2019 ACM SIGPLAN International Symposium on Memory Management - ISMM 2019;2019
2. Lock Removal for Concurrent Trace Programs;Computer Aided Verification;2012
3. Class invariants as abstract interpretation of trace semantics;Computer Languages, Systems & Structures;2009-07
4. The KaffeOS Java runtime system;ACM Transactions on Programming Languages and Systems;2005-07
5. Abstract Interpretation and Object-oriented Programming: Quo Vadis?;Electronic Notes in Theoretical Computer Science;2005-05