You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Support ASYNCIFY_IMPORTS and add ASYNCIFY_EXPORTS for JSPI. (#18165)
Pass asyncified imports and exports on to the JSPI wasm-opt pass so
only the specified functions are wrapped.
* Update src/library_async.js
Co-authored-by: Alon Zakai <[email protected]>
// Add space for the suspender promise that will be used in the
56
+
// Wasm wrapper function.
57
+
type.parameters.unshift('externref');
58
+
imports[x]=original=newWebAssembly.Function(
59
+
type,
60
+
original,
61
+
{suspending: 'first'}
62
+
);
63
+
}
63
64
#endif
64
65
#if ASSERTIONS&&ASYNCIFY!=2// We cannot apply assertions with stack switching, as the imports must not be modified from suspender.suspendOnReturnedPromise TODO find a way
0 commit comments