Artifact 123ee72db0b7ba660a11594b54b4e11410b3cb1df4ca4e8c3e29cfcb7ceb48b3:
- File
src/storage_benchmark.zig
-
2026-07-19 18:46:43
— part of check-in
[7c2262c837]
on branch iss4
— Add `zit stat`: the store's own byte accounting and artifact roll
The store could not be interrogated about its contents: no way to ask how many artifacts it holds, which ones, or how many of its bytes are artifact content rather than framing. `zit stat` answers that from the frames themselves, emitting `field value` lines: store-bytes, header-bytes, content-bytes, frame-overhead-bytes, config-bytes, artifacts, full-form, deltas. The byte fields account for the file exactly.
content-bytes and store-bytes stay separate on purpose. Content is measured by summing each artifact frame's payload length; it is never derived from the `.zit` size, which also carries the store header, a header per frame, and alignment padding. A size-derived figure would look like a result and be a fabrication, so the overhead separating the two is reported alongside and stays checkable.
`--artifacts` lists the stored hashes one per line in ascending order, so two stores' rolls compare with `comm`; `--type=full|delta` narrows by storage form, read from the index the open already built.
The frame walk and its accounting live in `storestat`, shared with the storage benchmark, so the two cannot drift. (user: dmestas, size: 32744) [annotate] [blame] [check-ins using]
-
2026-07-19 20:43:40
— part of check-in
[921678c019]
on branch trunk
— Merge iss4: zit stat, the store's own byte accounting and artifact roll
The store could not be interrogated from outside a checkout: no way to ask how many artifacts it holds, which ones, or how many of its bytes are content rather than framing. zit stat answers from one pass over the frames -- store-bytes, content-bytes, frame overhead, artifact and delta counts. Content is summed from each frame's payload during the walk, never derived from the .zit file size, which also carries the store header, a per-frame header and padding; a size-derived figure would look like a result and be a fabrication, so the two stay separate fields and the overhead between them stays checkable. --artifacts lists the stored hashes for comparison across stores. The frame walk and its accounting live in storestat, shared with the storage benchmark, so the verb inherits the benchmark's exact-accounting test and the two cannot drift. (user: dmestas, size: 32744) [annotate] [blame] [check-ins using]
-
2026-07-19 18:46:43
— part of check-in
[7c2262c837]
on branch iss4
— Add `zit stat`: the store's own byte accounting and artifact roll