Introducing Sampling to the GC

Martin Nowak via Digitalmars-d digitalmars-d at puremagic.com
Sun May 25 19:20:14 PDT 2014


On Friday, 23 May 2014 at 21:14:38 UTC, Etienne Cimon wrote:
> My proposal is to implement pointer sampling in the GC (using 
> hypothesis testing - hypergeometric or poisson distributions) 
> to tweak this collection efficiency. The idea would be to be 
> able to specify how much % we'd like the GC to swipe on average 
> at every cycle, so that these cycles run less frequently.

I still think an adaptive threshold for when to trigger a
collection would be much simpler and equally effective. So when
you can only reclaim very little memory you increase the
threshold, so that the next collection would be delayed.


More information about the Digitalmars-d mailing list