-
Notifications
You must be signed in to change notification settings - Fork 67
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
Enable usage of timers on WASM #89
Comments
I'm not sure if we need to introduce such a breaking change to support WASM. |
That's probably the best way of going about this. I'll rearrange the PR I wrote to use OS flags instead of feature flags. |
A few points of note I discovered while implementing this:
|
Not relevant for now |
notgull
changed the title
Optionally disable timers or Asyncs on features
Enable usage of timers on WASM
Nov 1, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
WASM targets don't support
Async
and probably won't until WASI reaches a more stable point. However, sinceparking
is usable on WASM thanks to atomics, it may be desirable to use theTimer
implementation.My suggestion is to add two new features:
io
andtimers
. They compose as such:io
disabled buttimers
enabled, theReactor
retains its timer processing capabilities but instead of calling topolling
, it callsparking
(which works with WASM) with the timeout resulting fromprocess_timer_ops
.Reactor
no longer exists andblock_on
is just an alias to the ones infutures_lite
.This would be a breaking change.
The text was updated successfully, but these errors were encountered: