-
Notifications
You must be signed in to change notification settings - Fork 3.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix broken JS glue for AUDIO_WORKLETS with EXPORT_ES6 (#21192)
WASM Audio Worklets with EXPORT_ES6 may break at runtime: test.js:989 Uncaught (in promise) TypeError: Cannot set property wasmTable of #<Object> which has only a getter at receiveInstance (test.js:989:25) at receiveInstantiationResult (test.js:1011:5) The read-only getter at issue is created in ASSERTIONS-enabled builds, and conflicts with the current way of exporting wasmTable on the Module object. Exporting wasmTable via EXPORTED_RUNTIME_METHODS prevents the getter from being created in normal builds. In MINIMAL_RUNTIME builds, we make sure to delete the getter before manually exporting as before. We also prevent an ES6 Audio Worklet from loading the .wasm binary via `new URL()`, as `URL` is unavailable in AudioWorkletGlobalScope.
- Loading branch information
1 parent
9c93641
commit 2a00e26
Showing
4 changed files
with
22 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters