docs(roadmap): split v0.6 into up-next / later; add RFC 004 summary
Up next: channel mutex migration, named registry, gen_server call timeout. Later: RFC 004 (tunable scheduler idle policy), unbounded slab, handle_info, IO fd hygiene, arm-port.
This commit is contained in:
+36
-26
@@ -104,9 +104,7 @@ precondition.
|
||||
|
||||
---
|
||||
|
||||
## v0.6 — Fast follows & open tracks
|
||||
|
||||
Priority order within the cycle; each item is its own commit.
|
||||
## v0.6 — Up next
|
||||
|
||||
### 1. Channel mutex migration (first change)
|
||||
`channel::Inner<T>` holds a `std::sync::Mutex`. Phase 2 surfaced a sharp
|
||||
@@ -126,37 +124,49 @@ keep it cheap/pure.
|
||||
`HashMap<String, Pid>` in `SharedState`, guarded by the shared lock. No
|
||||
architecture changes; can land immediately after #1.
|
||||
|
||||
### 3. gen_server: handle_info + call timeout
|
||||
- `handle_info`: needs a cross-channel mailbox merge (call/cast inbox +
|
||||
out-of-band signals). The still-unmade decision: whether to introduce a
|
||||
unified per-actor mailbox or keep per-channel `recv_match` composition.
|
||||
- Call timeout: `call` with a deadline — monitor the server, wait
|
||||
reply-or-Down-or-deadline, then `demonitor`+drop so a timed-out call leaks
|
||||
no registration. Requires a per-`recv` deadline / `Signal::Timeout` primitive
|
||||
that doesn't exist yet.
|
||||
### 3. gen_server: call timeout
|
||||
`call` with a deadline — monitor the server, wait reply-or-Down-or-deadline,
|
||||
then `demonitor`+drop so a timed-out call leaks no registration. Requires a
|
||||
per-`recv` deadline / `Signal::Timeout` primitive that doesn't exist yet.
|
||||
(`handle_info` deferred — needs cross-channel mailbox merge; see Later.)
|
||||
|
||||
These two can land independently; call timeout is smaller and more useful
|
||||
first.
|
||||
---
|
||||
|
||||
### 4. Unbounded / configurable-bounded actor count
|
||||
v0.5 ships a fixed slab with a loud assert (`Config::max_actors(n)`, default
|
||||
16 384). Revisit with a segmented slab (array of `AtomicPtr<Segment>`, doubling
|
||||
segment sizes, append-only) once the cap is actually hit or a workload demands
|
||||
it. Do not let the fixed cap calcify into an assumption.
|
||||
## Later
|
||||
|
||||
### 5. Idle-wakeup eventcount
|
||||
Idle scheduler threads currently poll-sleep at 100 µs. A futex-based eventcount
|
||||
would reduce idle latency. Defer until benches show it matters.
|
||||
### Tunable scheduler idle policy (RFC 004)
|
||||
Today idle schedulers fall back to `thread::sleep(100µs)`, putting ~100µs
|
||||
worst-case latency on every cross-thread actor handoff. RFC 004 specifies a
|
||||
bounded spinning-worker policy (Go/Tokio model): idle schedulers spin on a
|
||||
cheap atomic for a configurable budget before parking, so a burst of work is
|
||||
picked up in cache-coherency time rather than after a kernel reschedule.
|
||||
|
||||
### 6. IO fd hygiene on actor death
|
||||
Two new `Config` knobs: `spin_budget_cycles` (RDTSC cycles to spin; `0`
|
||||
recovers today's behaviour) and `max_spinners` (cap on concurrent spinners;
|
||||
default `N/2`). Single new atomic `n_spinning`. No change to the run-queue
|
||||
data structure — lands on the current `Mutex<VecDeque>` and is independent of
|
||||
any future queue topology work.
|
||||
|
||||
Full spec: `rfc_004-tunable-scheduler-idle-policy.md` (artefacts.kalsbeek.dev).
|
||||
|
||||
### Unbounded / configurable-bounded actor count
|
||||
Fixed slab with a loud assert (`Config::max_actors(n)`, default 16 384).
|
||||
Revisit with a segmented slab (array of `AtomicPtr<Segment>`, doubling segment
|
||||
sizes, append-only) once the cap is actually hit. Do not let it calcify.
|
||||
|
||||
### gen_server: handle_info
|
||||
Needs a cross-channel mailbox merge (call/cast inbox + out-of-band signals) —
|
||||
the still-unmade decision between a unified per-actor mailbox and per-channel
|
||||
`recv_match` composition.
|
||||
|
||||
### IO fd hygiene on actor death
|
||||
Pre-existing v0.2 TODO in `io.rs`: fds registered with epoll for a dead actor
|
||||
are not cleaned up. Audit and fix.
|
||||
|
||||
### 7. arm-port validation & merge
|
||||
### arm-port validation & merge
|
||||
`arm-port` branch carries an AAPCS64 context-switch backend, never run on
|
||||
hardware. Steps: build + run full test suite on an aarch64 device; check
|
||||
`chained_spawn` / `yield_many` bench medians for regressions vs x86 baseline;
|
||||
merge and update README module table to reflect multi-arch support.
|
||||
hardware. Build + run full test suite on an aarch64 device; check
|
||||
`chained_spawn` / `yield_many` bench medians; merge and update README.
|
||||
|
||||
---
|
||||
|
||||
|
||||
Reference in New Issue
Block a user