4 ms·
I find it incredible how much design room there is in GC research and how much is as yet unexplored. In my opinion, GC (and relatedly, event loop scheduling) ar
by WJW 3y ago
I find it incredible how much design room there is in GC research and how much is as yet unexplored. In my opinion, GC (and relatedly, event loop scheduling) are often way too integrated in a language runtime. I would love seeing this become more configurable, and am glad to see developments in this direction like the fiber schedulers in modern Ruby and custom allocators in Zig.
I once inquired about making the Haskell IO manager configurable at runtime but the GHC maintainer team was extremely apprehensive about it because they feared that they would be on the hook for any bugs introduced by third-party IO managers. As it is, Java gets all the GC research love while most other languages make do with very basic GC algorithms. It doesn't have to be like this.
- rbranson 3y agoThe reason is that runtime design forms the constraints of the GC design. Java allows relocating objects, Go does not. Go allows interior pointers, Java does not. These decisions have deep impact on GC design. Something this performance critical needs to be tailored to the runtime.
- felixge 3y agoAFAIK Go’s spec allows relocating objects. The door towards a moving GC is kept open.
- _old_dude_ 3y agoThere are so many packages that only work with GODEBUG=cgocheck=0 that practically that door is closed
- memco 3y agoIn that same vein of thought Nim recently launched version 2 of the language which makes the ORC GC the default with options to use a few others. I don’t know if there’s new ones on the horizon but there’s already plumbing in case that’s an interest for you to explore further.
- pjmlp 3y agoWhich is a reason why randomly talking about programming language capabilities with automatic memory management is nonsense, without actually looking into the details. Unfortunately that is exactly what the manual memory management crowd does.
- mynameisnoone 3y agoErlang enters the chat to brag about efficient HiPE GC by tying objects to processes. Pony enters the chat to brag about ORCA. Rust enters the chat to brag about precise memory management without GC per se. Those bastards!
- pjmlp 3y agoYour Erlang and Pony examples use automatic memory management and only reinforce my remarks. Additionally, linear and affine type systems isn't the same as manual memory management.