After 3 months of coding weekends, my attempt to create a relocating nonblocking garbage collector in C++ has failed. It works in theory, but in practice the read barrier is pervasive and costly, and the threading invariants are incredibly tricky to maintain.
-
-
What's the usecase for relocation? Fragmentation? Large allocs with serial access?
-
Relocation ensures less fragmentation and higher cache and TLB locality, and can also enable lower-cost freeing than random access memory managers. Yet any purely concurrent scheme requires some pinning, so the benefits of relocation are reduced.
End of conversation
New conversation -
-
-
HW support for read barriers has been proposed, have you looked into that? Might be relevant for you: https://people.eecs.berkeley.edu/~maas/papers/maas-asbd16-hwgc.pdf …. And there is Azul, who abuse the page tables to implement read barriers. I've been wondering for some time why Intel/AMD don't plan to offer sth. in hw.
-
I think of modern CPU architectures like SkyLake as offering hardware support for everything, since they can issue 4-6 instructions per clock and often do. Only problem is the high-cost unspeculated atomics.
- 1 more reply
New conversation -
-
-
Doesn’t the new .NET background GC allow allocations on non-GC collecting threads to continue for a prespecified amount of allocations while GC is happening? IIRC there should be a 16MB window, at least on workstations...
-
My understanding of .NET: mutator threads can run during some parts of GC but not during the stop-the-world stack scanning and relocation phase. For that, it has to pause all threads.
- 2 more replies
New conversation -
-
-
For games I think incremental may be better than concurrent, but where you manually invoke the GC once per frame while waiting for the present queue semaphore (or some minimum after presenting if not GPU bound)
Thanks. Twitter will use this to make your timeline better. UndoUndo
-
-
-
Please build a sea server
Thanks. Twitter will use this to make your timeline better. UndoUndo
-
-
-
so you're saying the only way to scale is through .NET?
Thanks. Twitter will use this to make your timeline better. UndoUndo
-
-
-
What if we had a language that didn't leave it's pointers dangling out in the open. Then let the compiler deal with memory management. Compile-time GC.
Thanks. Twitter will use this to make your timeline better. UndoUndo
-
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.