What should happen here?
Elronnd
elronnd at elronnd.net
Tue Sep 28 06:38:20 UTC 2021
On Monday, 27 September 2021 at 22:15:26 UTC, deadalnix wrote:
> I don't see why storing the GC root needs to be expensive
Because you need to be able to remove the root later. So it
essentially reduces to a hash table. Wrt contention, concurrent
hash table is doable
(https://github.com/boundary/high-scale-lib/blob/master/src/main/java/org/cliffc/high_scale_lib/NonBlockingHashMap.java) but would need to be implemented; however I agree with Steven that I don't understand why you would do this when you could just store the pointer on the stack or in a register.
More information about the Digitalmars-d
mailing list