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

Async with Workers, SharedArrayBuffer and Atomics #45

Open
AntonPieper opened this issue Feb 21, 2024 · 0 comments · May be fixed by #46
Open

Async with Workers, SharedArrayBuffer and Atomics #45

AntonPieper opened this issue Feb 21, 2024 · 0 comments · May be fixed by #46

Comments

@AntonPieper
Copy link

AntonPieper commented Feb 21, 2024

Workers can be blocked using Atomics on a SharedArrayBuffer and the screen buffer can be sent using OffscreenCanvas, therefore it is theoretically possible to load zozlib.js in a worker, block calls and send the screen to the main thread. This does come with an overhead and some complexity. I think this is worth investigating though, as it would be a rather niche (as far as I can tell from a Google search) approach to handling Async in web assembly.

@AntonPieper AntonPieper linked a pull request Feb 21, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant