Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

internal/task: use asyncify on WASM #2011

Merged
merged 2 commits into from Nov 14, 2021
Merged

Commits on Nov 11, 2021

  1. internal/task: use asyncify on webassembly

    This change implements a new "scheduler" for WebAssembly using binaryen's asyncify transform.
    This is more reliable than the current "coroutines" transform, and works with non-Go code in the call stack.
    
    runtime (js/wasm): handle scheduler nesting
    
    If WASM calls into JS which calls back into WASM, it is possible for the scheduler to nest.
    The event from the callback must be handled immediately, so the task cannot simply be deferred to the outer scheduler.
    This creates a minimal scheduler loop which is used to handle such nesting.
    niaow committed Nov 11, 2021
  2. fix binaryen build in docker

    Oops I forgot to install cmake and ninja.
    niaow committed Nov 11, 2021