back

by Rochus·6y ago·view on hn ↗
How about efficiency? Looks like the collector has to scan through all allocated memory and the whole stack to check whether there could be a pointer. And if any data looks like such a pointer (even by coincidence) the corresponding memory cannot be collected. Anyway: isn't this just the same concept as the Boehm conservative GC? What's the difference/improvement?
1 comments
Second paragraph in README:

> The focus of gc is to provide a conceptually clean implementation of a mark-and-sweep GC, without delving into the depths of architecture-specific optimization (see e.g. the Boehm GC for such an undertaking). It should be particularly suitable for learning purposes and is open for all kinds of optimization (PRs welcome!).