Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API

From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
whimsical17912hThat's sad. You can always upgrade to a different language! :) Yh, wasm. I also very stoked for the tech. But actually, what are good use cases? I'm very impressed by openttd in browser and Autocad. What do you think wasm will bring us?
-
lorentz1531312hNot all is lost though, there will probably be a different WASM target with native threading support. I look forward to the third WASM target that will use WASI threading.
-
lorentz1531311h@whimsical I look forward the most to the end of Javascript's hegemony and opening the floor to languages with better static analysis and opportunistic parallelization potential, although that may be a bit ambitious. Otherwise, I hope it can become a democratic distribution method for indie games. Since payment providers like Stripe aren't too difficult, the biggest argument in favour of Steam for many devs is actually player convenience.
-
BordedDev191211hThat's not the end of the threading issues either. You need special cors rules on the server as well, that prevent you from having 3rd party links. It's something @whimsical and I bumped into
-
@BordedDev what has cors got to do with the parallelization of client-side programs?
-
@lorentz "security" it allowed a specter exploit because of an exploit in shared memory (I don't know why this required, instead of just allowing us the same postMessage interface - maybe don't call it a thread then but still a threading setup with the isolation burden would be appreciated) so now you have to have cross-origin isolation.
This has bit more of a write up: https://web.dev/articles/... -
@BordedDev That's odd, I could've sworn that Rust's wasm support uses a virtual stack to allow "blocking" the "invoking thread" which all looks like regular async work from the JS side. I mean, Rust at least actually has a type of async support that makes no assumptions about the executor so you can use that. But still, it surprises me that the general solution isn't to lift all work into promises while we're already on a compilation boundary where anything goes.
-
What the hell is going in with WASM in general. It has been in development for like 10 years and its still like 0.1 alpha. Reference types are still experimental, theres no garbage collector support, no dom access, etc. etc.
Like do they actually want to finish it at some point...?
Related Rants
WASM threads have been supported in every browser since 2021, but Rust can't support them because production users and library authors enabled WASM support in thread-unsafe ways relying on WASM being single threaded, so enabling it would almost certainly introduce vulnerabilities.
rant
threading
wasm
rust