Issue #3037: Runtime: user-pool 1 runs on the program’s thread, the pool starts lazily

Open and answer this issue on GitHub.

async, ready, queued · opened 2026-12-01 · updated 2026-12-01 · 0 comments

Part of #3027. Decided in ADR-threads-v1 D2, D6, D7.

Why: with the switch gone, user-pool decides the thread count, 1 included, and a run at one worker must keep today’s no order.

To build

  1. user-pool = 1: the executor is the program’s own thread, no worker starts; tasks of a group interleave at their suspension points in today’s no order; a parallel fold is its sequential fold (ADR-372 D7).
  2. The pool starts at the first spawn that needs it; a program that never spawns starts no worker.
  3. task::cores() is the pool’s size.
  4. A target without threads (bare metal, wasm32-unknown) has user-pool fixed at 1.

Done when: the existing no tests run unchanged at user-pool = 1 with the same stdout (determinism probe); a program without a spawn shows no worker thread; a probe reads task::cores() at 1 and at 4.


Generated by Claude Code

Back to Open Issues