Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> We're talking about garbage collection though, this will always be inefficient, doesn't matter much on which side of the fence it is implemented.

No, that's just not true.

You can't implement GC in WASM currently in any sane way.

As already said more than once here: WASM is lacking needed features. (For example memory fence instructions).

Any GC build in WASM will be extremely slow and inefficient. It will be also a stop-the-world GC. Because you can't build anything else.

GC implemented in WASM is at the moment completely impracticable.

Sure, you "can" do it still. But that's like building a banking application in Brainfuck. You can do that. In theory. Maybe even someone did it "for real". All this does not matter. It's brainfuck.

And that's not only the GC.

VM runtimes, and JITs need some more features to be implemented efficiently.

WASM is also lacking those features (like computed go-to).

Bottom line is: It's impossible to implement a VM in the WASM VM even remotely acceptable.

This is also backed by data:

I've showed already the catastrophic performance of Blazor. (And this is something where millions of dollars went for years to make it even "work".)



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: