perf(ios): skip the readiness preflight for foreground probe reads
Summary
Skip the uptime preflight for each foreground-probe appState read when the ready runner matches the pinned session ID. The two parallel reads keep their one-second deadlines, connection wait, read-only resend, and queued charge rules. A replacement runner receives neither read. Ordinary reads keep their preflight.
Before / after
Warm Settings snapshot -i --debug on Limrun iOS, 30 timed calls per checkout. The base and earlier skip measurements came from the original comparison. The current head used a fresh simulator lease.
| Per snapshot | Base 12fe72efec | Earlier skip 58b647f4c8 | Current head 90f369471f |
|---|---|---|---|
Foreground appState sends | 2 | 2 | 2 |
Foreground uptime preflights | 2 | 0 | 0 |
| Median wall time | 591.0 ms | 468.7 ms | 463.4 ms |
| p90 wall time | 597.5 ms | 503.6 ms | 499.3 ms |
Validation
At 90f369471ffc479035209ac8a8c8ebb50f5b561d, all 944 tests passed across the two foreground-probe test files and eager-closure-budgets.test.ts. After two warmups, the proof snapshot and all 30 timed snapshots each recorded two skipped preflights with reason foreground_probe_read and two matching sends. The lease was released, the isolated daemon stopped, and Limrun reported zero active instances. CI checks and review pending. Debug trace