On Mon, Jul 15, 2013 at 3:03 PM, Jon Zeppieri <[email protected]> wrote: > When I looked into LLVM's GC support recently, my conclusion was that > the price of doing accurate collection was to preemptively spill all > of your registers to the stack. Or, to put it another way, LLVM will > happily track stack roots but cannot track register roots, so if you > want to do accurate GC, LLVM will keep all of your roots on the stack. >
That's what I thought. Basically, they've integrated the technique that Fergus Henderson proposed. It's actually not as bad as it sounds, since those registers tend to get spilled anyway. The issue isn't *spilling* the registers, so much as it is ensuring that the registers get reloaded. The essential requirement on the optimizer is to know the types of values in registers. LLVM doesn't do that. Implementors of managed languages have been complaining about that for years, but it isn't a priority at Apple. Jonathan
_______________________________________________ bitc-dev mailing list [email protected] http://www.coyotos.org/mailman/listinfo/bitc-dev
