Skip to content

docs: walk-free STM32 plan (read-side freshness decision + migration batches)#514

Merged
w1ne merged 2 commits into
mainfrom
docs/walk-free-plan
Jul 11, 2026
Merged

docs: walk-free STM32 plan (read-side freshness decision + migration batches)#514
w1ne merged 2 commits into
mainfrom
docs/walk-free-plan

Conversation

@w1ne

@w1ne w1ne commented Jul 11, 2026

Copy link
Copy Markdown
Owner

Design doc for the walk-free campaign: make the per-cycle peripheral walk structurally unnecessary so ANY firmware gets interval-64 batching, not just curated demos with a hand walk_deleted flag.

Decision: batch-boundary read freshness via interior mutability (Arc published cycle clock; ≤ one-interval staleness on raw counter reads, event-observables byte-exact via absolute deadlines + batch clamps). The &mut-read alternative is rejected on measured blast radius (134 Peripheral impls, ~1800 read call sites) and, fatally, the fetch_slice/observer aliasing model. Includes a committed spike test proving the pattern compiles and holds its bounds against the real trait.

Inventory: 49 walkers = 28 inert Class-A instances (needs_legacy_walk=false assertions only) + 21 real-work instances across 8 model types (systick, timers, dma, i2c, adc, exti, scb, bxcan), each mapped to an existing migration exemplar. Batches B0-B8 with per-batch differential gates (walk-on@interval-1 vs scheduler@64, armed-peripheral firmware).

Endgame: derive_walk_deletable flips true per-board as batches land; walk_deleted becomes a deprecated escape hatch.

Design doc for making the per-cycle peripheral walk structurally
unnecessary so derive_walk_deletable() flips on user-compiled firmware,
not just curated demos with a hand walk_deleted flag.

Part 1 recommends batch-boundary read freshness (< one-interval
staleness) implemented via interior-mutability sync-on-read against a
bus-published Arc<AtomicU64> clock; rejects the &mut read choke point on
blast radius. Includes a SPIKE integration test proving the mechanism
compiles against the real Peripheral trait and is byte-exact at batch
boundaries, bounded by < interval mid-batch.

Part 2 inventories the 49 invaders-bus walkers (28 inert Class-A +
21 real-tick Class-B across 8 model types) with per-class exemplars,
migration order, and PR batches B0-B8 each with a walk-on@1 vs
scheduler@64 differential gate.

Part 3 gives the walk_deleted deprecation path.
@w1ne w1ne merged commit f28f57d into main Jul 11, 2026
2 checks passed
@w1ne w1ne deleted the docs/walk-free-plan branch July 11, 2026 15:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant