Skip to content

Opt out of tokio's per-task budget in wasip2 noop polls - #14265

Merged
alexcrichton merged 1 commit into
bytecodealliance:mainfrom
alexcrichton:less-budge
Sep 2, 2026
Merged

Opt out of tokio's per-task budget in wasip2 noop polls#14265
alexcrichton merged 1 commit into
bytecodealliance:mainfrom
alexcrichton:less-budge

Conversation

@alexcrichton

Copy link
Copy Markdown
Member

This commit updates various calls of noop_waker and poll_noop throughout wasip2 to ensure they're all using
tokio::task::unconstrained to specifically opt-out of Tokio's default task-budgeting mechanism. This is necessary to get some various tests I'm working on wasi-libc working on wasip2 because otherwise the test exhausts the task budget pretty quickly and then results in pretty surprising I/O behavior. One example is that a TCP socket ready for writing with check-write is subsequently not actually ready for writing because the task budget ran out.

To the best of my ability to understand what I'm running into is the same as what's run into in #14174. I'm not entirely sure though, but I'm going to conservatively say...

Closes #14174

This commit updates various calls of `noop_waker` and `poll_noop`
throughout wasip2 to ensure they're all using
`tokio::task::unconstrained` to specifically opt-out of Tokio's default
task-budgeting mechanism. This is necessary to get some various tests
I'm working on wasi-libc working on wasip2 because otherwise the test
exhausts the task budget pretty quickly and then results in pretty
surprising I/O behavior. One example is that a TCP socket ready for
writing with `check-write` is subsequently not actually ready for
writing because the task budget ran out.

To the best of my ability to understand what I'm running into is the
same as what's run into in bytecodealliance#14174. I'm not entirely sure though, but I'm
going to conservatively say...

Closes bytecodealliance#14174
@alexcrichton
alexcrichton requested review from a team as code owners September 1, 2026 23:42
@alexcrichton
alexcrichton requested review from pchickey and removed request for a team September 1, 2026 23:42
@github-actions github-actions Bot added the wasi Issues pertaining to WASI label Sep 2, 2026
@alexcrichton
alexcrichton added this pull request to the merge queue Sep 2, 2026
Merged via the queue into bytecodealliance:main with commit d826d8a Sep 2, 2026
54 checks passed
@alexcrichton
alexcrichton deleted the less-budge branch September 2, 2026 17:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

wasi Issues pertaining to WASI

Projects

None yet

2 participants