GC-Safe Interprocedural Unboxing
Modern approaches to garbage collection (GC) require information about which variables and fields contain GC-managed pointers. Interprocedural flow analysis can be used to eliminate otherwise unnecessary heap allocated objects (unboxing), but must maintain the necessary GC information. We define a core language which models compiler correctness with respect to the GC, and develop a correctness specification for interprocedural unboxing optimizations. We prove that any optimization which satisfies our specification will preserve GC safety properties and program semantics, and give a practical unboxing algorithm satisfying this specification.
KeywordsEquivalence Class Operational Semantic Garbage Collection Dynamic Semantic Garbage Collector
- 1.Harper, R., Morrisett, G.: Compiling polymorphism using intensional type analysis. In: Twenty-Second ACM Symposium on Principles of Programming Languages, San Francisco, CA, pp. 130–141 (January 1995)Google Scholar
- 5.Leroy, X.: The effectiveness of type-based unboxing. Tech. rep., Boston College, Computer Science Department (1997)Google Scholar
- 7.Petersen, L., Glew, N.: GC-safe interprocedural unboxing: Extended version (2012), http://leafpetersen.com/leaf/papers.html