-
Notifications
You must be signed in to change notification settings - Fork 258
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
wasi_snapshot_preview2 - lack of sched_yield interface #582
Comments
I expect it was just an omission, but I do increasingly think (especially in concurrent composition scenarios like we're considering for Preview 3) that a cooperative "yield" call is pretty important, so maybe this could be a candidate for inclusion in the short term ( |
I suppose one short-term 0.2.0 workaround (which is not ideal, but probably gives the runtime what it needs to perform a cooperative yield) is to implement |
Agree with Luke -we omitted |
Another reasonable polyfill is to have As background here, |
I think it'd be helpful for projects that continue using wasi threads with preview 2. |
Hi all,
I'm looking to migrate some of the WSP1 code to WSP2 and I noticed there's no
sched_yield
equivalent in any of the existing world launched here: #577. Is this functionality covered by any of the existing proposals? I'm not sure if that's in scope of the https://github.com/WebAssembly/shared-everything-threads proposal, but even if so, the proposal is in a very early stage right now, but WSP2 is already launched.My assumption was that WSP1 can be implemented using WSP2 (not other way around though) and that assumption was confirmed yesterday during the WASM64 discussion. I wonder if lack of the interface is simply a miss or was it deliberately omitted?
Thanks
The text was updated successfully, but these errors were encountered: