WasmGC - Garbage Collection In WebAssembly

There's not a whole lot of code for the Ren-C garbage collector.

The lack of code is good and bad. On the bad side, it's not very fast or clever (though the Stub and Cell formats themselves are very clever). On the good side, it means that it could maybe be swapped out with a more sophisticated one, or a GC that integrates better with its specific environment.

One emerging possibility in the WebAssembly build is WasmGC:

gc/proposals/gc/Overview.md at main · WebAssembly/gc · GitHub

I'm not sure exactly how much of a sacrifice of the design it would be to use such things. All the sizes and bits are very precisely arranged, and it may be that in order to make use of a generalized garbage collector you have to give up control of struct layout and put everything in a form that the generic GC expects.

But it's something to look at.

3 Likes