[racket-dev] gc vs assignment

From: Sam Tobin-Hochstadt (samth at ccs.neu.edu)
Date: Tue Aug 24 11:53:55 EDT 2010

On Tue, Aug 24, 2010 at 11:43 AM, Kevin Tew <tewk at cs.utah.edu> wrote:
> After a garbage collection all non-nursery memory is write-protected.
> The first write to a page (16kB) , after a garbage collection, incurs the
> cost of unprotecting the page so it is writable and recording that the page
> has been written on.
> All subsequent mutations to objects in a unprotected page do not have a
> write barrier cost, until the next garbage collection run.

Does this means that the GC treats every object in a mutated page as
potentially pointing to the nursery?  That seems like a very coarse
approximation of the remembered set, but it might be worth it to get
the OS to do your write barrier for you.
sam th
samth at ccs.neu.edu

Posted on the dev mailing list.