3 ms·
There are production garbage collectors written in languages like Java, so this shouldn't be surprising.
by chrisseaton 7y ago
There are production garbage collectors written in languages like Java, so this shouldn't be surprising.
- pjmlp 7y agoIt isn't for those of us that actually bother to learn about them, unfortunately still feels like spreading gospel, given the sore state of some education institutions.
- DmitrySoshnikov 7y agoAbsolutely valid point, that's why I didn't want to stick specifically on C++ (even though it'd be easier specifically for raw heap memory). As mentioned about though, GC algorithms can be transferred to higher-level system as well. For example, here is a basic Mark-Sweep algorithm implemented in JavaScript on JS objects in a collection: https://gist.github.com/DmitrySoshnikov/4391763 https://gist.github.com/DmitrySoshnikov/4391763
- reitzensteinm 7y agoGarbage collection algorithms are also applicable outside of in process memory management. I wrote a copying collector against a KV store in Clojure that I ran in prod for a while, though I swapped it out for a generational mark and sweep in Java. I'm sure somewhere, somehow, somebody has written a GC in Excel serving some kind of business need.
- DmitrySoshnikov 7y agoGreat point, and the example. Exactly, the GC algorithms are a high-level abstraction, which can be transferred, and applied on higher-level systems.