[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: What type of GC is used in PLT?



Quoting Thomas Wager:
> I am wondering what type of GC PLT uses (especially in v200 for MacOS 
> X)? As far as I know from the Unix port by default a conservative GC is 
> used, with the option to build a VM with a precise GC (which is more 
> portable).

That's correct.

> Conservative GC is said to produce large "memory leaks" in the long run. 
> Is this a) true? b) true if I do not use any foreign C code but "only" 
> Scheme?

Using continuations or especially deep recursion (nested thousands
deep) will sometimes trigger leaks. Threads can also cause a problem,
though somewhat less often than the other two.

Those three cause problems because they copy registers and the C stack,
which induces a great deal of imprecision in conservative collection.

Other problems are rare, but if 3m (the version with the more precise
collector) builds for your platform, that's definitely the way to go
for a long-running process.

Matthew