On Wed, Oct 29, 2008 at 01:04:52AM +0900, Roger Pack wrote:
> A way to avoid this [as Boehm does (?)] would be to throw up a write
> barrier during collection and search it in the parent thread for new
> references--I am somewhat scared of doing so since it sounds hard :)

Requiring all ObjectSpace methods to grab a mutex and wait for the
collector to complete should probably be sufficient.

#each_object becomes tricky, because you still want the collector to be
invokable when you are iterating over all objects.  The easiest solution
is to disable #each_object when your patch is enabled.

Paul