On Sun, 26 Jul 2015 20:36:35 +0200, Sönke Ludwig wrote:

Am 23.07.2015 um 16:48 schrieb Etienne Cimon:

On Thu, 23 Jul 2015 08:56:05 +0200, Sönke Ludwig wrote:

the isolated reference is passed between threads. That, or isolated
values would live on their own or on the shared heap until they are made
thread-local mutable or immutable.

What I would do next, is migrate the current druntime GC to a shared GC, like you say.

Allocations to this GC would be made with new shared or new immutable. Or TLS data copied to the shared GC with .sdup

Forgot to send this reply: Just a side note about "sdup" that you may
already be aware of - it's important that this is only be allowed on
types that have no non-shared/non-immutable references, so that it
doesn't create references from the shared heap to the thread local one.

I tried using thread-local allocators with a shared GC, it leaked because GC calls destructors from any thread. Using scoped pools would be the only way to allow thread-local heap to co-exist at the moment..

I actually want to make it produce a recursive deep copy in those cases but it would have to be possible to manually overload them. It's one of those question marks that are blocking me at this moment.