Is there a modern GC for D?
sandford at jhu.edu
Tue Feb 9 22:03:30 PST 2010
Based on a thread on the DMD concurrency mailing list I've begun to get a
sinking regarding the future of the garbage collector in D: most of the
work in GC algorithms has gone into functional and (mostly) pure-OO
languages, leaving a multi-paradigm systems programming language like D
out in the cold. So far, I know mark-sweep and mark-region algorithms in
either serial, parallel or thread-local forms should work. But based on
Java we'd really like incremental, generational and/or concurrent options.
So I'd like to ask people to help brainstorm some ideas.
Some things I've run into:
-structs/pointers/slices/etc make finding memory meta information, like
mark-bits or ref-counts, non-trivial.
-C function calls and assembler blocks make code instrumentation
-Getting concurrent GC code correct is very hard. Boehm's algorithm, for
instance, looks extremely racy.
More information about the Digitalmars-d