16 ms·
How does synchronization or the lack of it carry over and translate to WASM based threading? I’m assumming all the typical threading problems are inherited by
by deckarep 8y ago
How does synchronization or the lack of it carry over and translate to WASM based threading?
I’m assumming all the typical threading problems are inherited by design such as the potential for deadlocks, memory corruption, priority inversion...etc?
Also I’m assumming these threads will allow true parallelism to occur?
- simcop2387 8y agoExactly right, everything sharing the same sharedarraybuffer will have all those same issues and will run in parallel. It's a space that I suspect newer languages like go, rust, d, etc will start to really make a mark on wasm because of the concurrency models and other safety features that they contain.
- mathw 8y agoWithout true parallelism there'd be no point dealing with all the mess the raw threading primitives get you! But yes, it's basically good old pthreads in WebAssembly, with all the snake pits that implies. Although I would hope the runtimes will be robust enough that this can't take out the browser when you trip over a concurrency bug.