Extending The UHCLLVMBackend:AddingSupportForAccurateGarbageCollection
Stc
Date: 2010-10-14
Time: 11:45
Room: BBL 079
Speaker: Paul van der Ende
Title: Extending the UHC LLVM backend: Adding support for accurate garbage collection
Abstract
The Utrecht Haskell Compiler has an LLVM backend for whole program analyse mode. This backend previously used the Boehm-Weiser library for heap allocation and conservative garbage collection. Recently an accurate garbage collector for the UHC compiler has been developed. We wanted this new garbage collection library to work with the LLVM backend. But since this new collector is accurate, it needs cooperation with the LLVM backend. Functionality needs to be added to find the set of root references and traversing all live references.
To find the root set, the bytecode interpreter backend currently uses static stack maps. This is where the problem arises. The LLVM compiler is known to do various aggressive transformations. These optimizations might change the stack layout described by the static stack map. So to avoid this problem we wanted to use the shadow-stack provided by the LLVM framework. This is a dynamic structure maintained on the stack to safely find the garbage collection roots.
We expect that the shadow-stack approach comes with a runtime overhead for maintaining this information dynamically on the stack. So we did measure the impact of this method. We also measured the performance improvement of the new garbage collection method used and compare it with the other UHC backends.
--
PaulVanDerEnde - 12 Oct 2010