Closed lars-t-hansen closed 7 years ago
https://tc39.github.io/ecmascript_sharedmem/dom_shmem.html#clusters.creation is incorrect. The HTML Standard runs the "run a worker" steps in parallel with the main thread. So the worker is not necessarily immediately created. (It would also help if your text named or linked the algorithms in question.)
From talking to @bakulf what Firefox does in practice with several objects, including SharedArrayBuffer
, is to just not support them for MessagePort
/MessageChannel
and instead special case Worker
to not use MessageChannel
underneath. I'm not sure what other browsers do here.
(Note also that such a model might be problematic if going forward certain <iframe>
s run in a different process as that would affect whether certain objects can be shared with them.)
I think this is fixed now since we have updated HTML. Unless you want to have an issue for tracking new features in HTML that might be needed here as well, but maybe that's better done as a new dedicated issue for that purpose.
Agreed.
@binji, @domenic, @annevk, @juj
We need to write up the changes that we need to DOM and/or HTML so that we have a canonical reference for what browsers need to support. Aids interoperation.
Evolving spec in the dom/ directory, formatted copy here: https://tc39.github.io/ecmascript_sharedmem/dom_shmem.html