by devit · 10y ago · 0 comments
Also it's not (any longer) considered good practice to have languages that allow mutable memory sharing since that makes software unreliable, so it's not really a good idea.
Without arbitrary memory sharing, multi-threading is already supported with web workers.
It gives many of the benefits of sharing memory without all of the gotchas
[1]https://developer.mozilla.org/en-US/docs/Web/API/Transferabl...
https://github.com/lars-t-hansen/ecmascript_sharedmem/blob/m...
You know what happens with shared typed arrays? Shared Uint8 arrays.
You know what happens with shared Uint8 arrays? Multiple workers using JSON.parse.
Do you want ants? Because this is how we get ants. :(