docs: record the measured storage cost and the new crate boundary
Updates the ADR log, architecture, limitations, perf table and README to match what now exists, rather than what was expected. **The perf number was wrong and is now honest.** The M0 figure of 0.279 MB excluded SQLite entirely — the placeholder binary never referenced the crate, so dead-code elimination dropped it. With the daemon actually opening a database it is **1.364 MB**, of which bundled SQLite is ~1.1 MB. That is 1.1 MB of the 5 MB budget spoken for, leaving 3.8 MB for D-Bus, X11 and a UI toolkit. This is the first number that makes the section 5 budget feel like a budget rather than a formality, and it turns ADR-4's bundled-vs-system-linked choice into a real trade-off with a measured price on both sides. - ADR-4 marked accepted and implemented, with that trade-off left open. - ARCHITECTURE.md documents why `blocker-storage` is a sibling crate and not a submodule: the dependency direction is what keeps the zero-dependency purity proof automatic rather than a grep someone can route around. - LIMITATIONS.md drops the stale "storage has no I/O" shortfall and records the bundled-vs-system question instead, plus the fact that `LockState` still always evaluates to Normal. - README status table and layout updated. Co-Authored-By: Claude Code <noreply@anthropic.com>
This commit is contained in:
+14
-5
@@ -29,17 +29,26 @@ Measured on: Ubuntu 26.04 LTS, KDE Plasma 6.6.6, 6 CPUs. Toolchain: rustc 1.98.1
|
||||
|
||||
| Metric | Target | Measured | When |
|
||||
|---|---|---|---|
|
||||
| Daemon binary (stripped, release) | ≤ 5 MB | **0.279 MB** | 2026-10-01, M0 |
|
||||
| Daemon binary (stripped, release) | ≤ 5 MB | **1.364 MB** | 2026-10-01, M1 |
|
||||
| Block latency | ≤ 150 ms | not measured | — |
|
||||
| Idle CPU | ~0% | not measured | — |
|
||||
| Idle RAM (daemon) | ≤ 15 MB RSS | not measured | — |
|
||||
| Idle wakeups | ≤ 1/min | not measured | — |
|
||||
| APK size | ≤ 10 MB | not measured | — |
|
||||
|
||||
The binary figure is real but nearly meaningless right now: the daemon is two
|
||||
`println!` lines. The meaningful measurement comes in M2-Linux once enforcement
|
||||
exists, and the real risk is at that point — D-Bus, X11, and a UI toolkit are
|
||||
where 5 MB would actually be threatened.
|
||||
**What the 1.364 MB contains, and why it matters.** That figure is with bundled
|
||||
SQLite linked in and the daemon actually opening a database — not the 0.279 MB
|
||||
placeholder from M0, which was two `println!` lines and excluded SQLite entirely
|
||||
through dead-code elimination.
|
||||
|
||||
So the honest read is: **bundled SQLite costs roughly 1.1 MB of a 5 MB budget.**
|
||||
That leaves 3.8 MB for D-Bus, X11, and the UI toolkit. It is a real constraint
|
||||
rather than a comfortable margin, and it is the first number that makes the
|
||||
section 5 budget feel like a budget instead of a formality.
|
||||
|
||||
It also makes ADR-4 (rusqlite bundled vs system-linked) a genuine trade-off rather
|
||||
than a settled one: system-linking would recover most of that 1.1 MB at the cost
|
||||
of a runtime dependency on the host's libsqlite3. Recorded as an open question.
|
||||
|
||||
## How to measure
|
||||
|
||||
|
||||
Reference in New Issue
Block a user