[jhc] good news everyone
John Meacham
john at repetae.net
Fri Apr 9 17:14:10 EDT 2010
On Fri, Apr 09, 2010 at 11:09:14AM -0300, Vinicius Callegari wrote:
> I'm a little outdated regarding the current status of jhc. As John said he'd
> wired in a garbage collector, does it mean that jhc doesn't use region
> inference anymore?
It has had a basic form of region inference for a while that was able to
allocate some structures on the stack. However, a hybrid approach seems
to be the best. The GC can perform optimiaztions such as short
circuiting indirections that can't be done with pure region inference,
and there never was a good way to infer the lifetime of mutable objects
like IORefs. So, it is likely both will co-exist in jhc. This is fairly
straightforward as I just need to maintain the invarient that objects
allocated in regions can only point to objects in other regions or
constants. That way the GC can stop tracing as soon as it hits a region.
This is fairly straightforward to ensure statically, since for the most
part haskell data structures arn't mutable.
> I've set up a party today so I can impress the girls with that... (just
> kidding :-)
Hey. That's why we write compilers. To get the ladies. Also, why no
invite? :)
John
--
John Meacham - ⑆repetae.net⑆john⑈ - http://notanumber.net/
More information about the jhc
mailing list