-
Andreas Haas authored
With the origin trial for WebAssembly threads, threads can be turned on and off by the embedder depending on the context we are currently in. With this CL we call the embedder callback stored on the isolate to determine whether threads are enabled in the current context or not. Design decision: I decided to extend the {WasmFeaturesFromIsolate} function to ask the embedder if WebAssembly threads are enabled. This is the function which defines dynamically which features are turned on. It would be awkward to have two such functions, one which calls the embedder and one which does not. A downside is that in WasmJs::Install the embedder does not seem to be ready to be called. That's why I changed the code there to call {WasmFeaturesFromFlags} instead. R=titzer@chromium.org, mstarzinger@chromium.org Bug: chromium:868844 Change-Id: I6bfa89960a54cec71992756e3717bbb3a9fe195e Reviewed-on: https://chromium-review.googlesource.com/1169180 Commit-Queue: Andreas Haas <ahaas@chromium.org> Reviewed-by: Ben Titzer <titzer@chromium.org> Cr-Commit-Position: refs/heads/master@{#55076}
1408e127