rfc: 0012 channels, mutex, select and cancellation points (Proposed)

features cancellation, channels, sync; bounded/rendezvous channels with
separate linear endpoints and a drain-then-close receiver protocol;
waiting-operation rule with ok/closed/cancelled edges; shields with
innermost-first nesting (E4305); mutex with function-bound guard and the
no-wait-while-locked rule (E4304); select over channel operations with
seeded choice among ready arms and per-edge ownership (Q-013); rwlock,
channel_transfer, guard_transfer reserved; owner decisions D1-D3
This commit is contained in:
dev committed 2026-10-04 16:17:59 +03:00
1 parent ab5814a7bb
commit 4230c78dd1
3 files changed
+415 -1

No files matched your search

+1 -1
View File
@@ -22,7 +22,7 @@ Non-normative. Part of the [implementation plan](README.md).
| ID | Status | Task | Depends | Output | Done when |
|---|---|---|---|---|---|
| P3-1 | doing | Resolve Q-013, Q-014; propose RFC 0002 for acceptance (Q-014 resolved by RFC 0011; Q-013 with RFC 0012) | — | spec 04, 11 | questions resolved |
| P3-1 | doing | Resolve Q-013, Q-014; propose RFC 0002 for acceptance (Q-014 resolved by RFC 0011; Q-013 proposed in RFC 0012) | — | spec 04, 11 | questions resolved |
| P3-2 | doing | Contract tables: `task.*` (RFC 0011, done), `channel.*`, `mutex.*`, `rwlock.*`, select (RFC 0012); `thread.*` deferred to native backends | P3-1 | spec 07 appendix | all spec 07 §4 fields including synchronization effects |
| P3-2a | doing | Publish features `tasks` (done), `channels`, `sync` | P3-2 | `reference/air-features.md`, `src/air/features.zig` | feature_not_declared / missing_dependency tests |
| P3-3 | done | Deterministic scheduler: seeds, choice points, choice log; global fuel across tasks and a separate `quantum` (spec 11 §7.2) | P3-2 | `src/interp/sched.zig` | same seed ⇒ identical trace; choice log replays a run; fuel is the sum over all tasks |