back

by dcminter·5mo ago·view on hn ↗
> people who never actually used WASM ;)

Fair if you mean me - I've at most toyed with it, but the shim stuff was off-putting.

I'm a backender though, I don't pretend my opinion is of any consequence here.

> Personally I'm not a fan of this

You make it sound like the shim layer is actively desirable - why is that?

1 comments
> You make it sound like the shim layer is actively desirable - why is that?

More flexibility. For instance even though the 'official' WebGPU shim has the upside that it is compatible with the webgpu.h C API header, it buys that compatibility with some pretty serious performance compromises which can be avoided when using a non-standard JS shim (for instance reading/writing data from/to mapped WebGPU buffers which live in their own ArrayBuffer object, I don't think the WASM Component Model has a solution for such scenarios). The WASM Component Model solution basically has to deal with the exact same problems, but the WebGPU C API will essentially be baked into the browser. I expect though that it will still be possible to write your own specialized JS shim, so it's not a too big of an issue. I would prefer if the WASM peeps first focus on solving other problems which provide more bang for the buck though.