Part of the V&V coverage initiative.
Problem
kiln's async runtime (component-model threading, async-runtime-error handling) is the scheduling substrate for everything running on top. Kani covers bounded invariants; Verus covers functional contracts. What's missing: every-interleaving concurrency checking of the scheduler and its synchronization primitives.
tokio-rs/loom is the Rust-native tool for this. Note: this is the crate loom = "..." — not the sibling pulseengine/loom (WASM optimizer).
Acceptance
Notes
- Kani + Verus cover functional correctness; loom covers concurrency
- Pair harnesses with the
safe_managed_alloc! capability system to verify memory-budget allocation is thread-safe
- Reference:
thrum/crates/thrum-db/tests/loom_claims.rs
Part of the V&V coverage initiative.
Problem
kiln's async runtime (component-model threading, async-runtime-error handling) is the scheduling substrate for everything running on top. Kani covers bounded invariants; Verus covers functional contracts. What's missing: every-interleaving concurrency checking of the scheduler and its synchronization primitives.
tokio-rs/loom is the Rust-native tool for this. Note: this is the crate
loom = "..."— not the sibling pulseengine/loom (WASM optimizer).Acceptance
loomdev-dep with#[cfg(loom)]import patternkiln-component/tests/loom_*.rsor wherever the scheduler livesRUSTFLAGS="--cfg loom"cargo-kilnsubcommandcargo-kiln loom-verifyto drive harnesses (optional but consistent withkani-verify)Notes
safe_managed_alloc!capability system to verify memory-budget allocation is thread-safethrum/crates/thrum-db/tests/loom_claims.rs