Skip to content

docs(audits): retained checksum pipeline already double-buffered#4033

Merged
oferchen merged 1 commit into
masterfrom
docs/audit-double-buffered-checksum-pipeline-1759
May 14, 2026
Merged

docs(audits): retained checksum pipeline already double-buffered#4033
oferchen merged 1 commit into
masterfrom
docs/audit-double-buffered-checksum-pipeline-1759

Conversation

@oferchen
Copy link
Copy Markdown
Owner

Summary

  • Records that the retained checksum pipeline already overlaps I/O with computation through a strict two-buffer producer-consumer arrangement in crates/checksums/src/pipelined/.
  • Documents the two-buffer invariant: constructor allocates buffer A, seeds buffer B into the recycle channel, and a bounded sync_channel(1) keeps in-flight data to one block.
  • Catalogs the synchronous fallback for small files, the call sites (signature::pipelined_gen, benches, comprehensive tests), and the existing functional-parity coverage so future contributors extend the primitive instead of duplicating it.

Test plan

  • Docs-only change; no code touched.
  • cargo fmt --all (no-op, no Rust files modified).

…e-buffered

Task #1759 asked for double-buffering in the retained checksum pipeline.
The work is already done in `crates/checksums/src/pipelined/`: the reader
pre-allocates two buffers, seeds one into a recycle channel, and uses a
bounded `sync_channel(1)` so the I/O thread reads block N+1 while the
caller hashes block N. Functional parity with the serialized hasher is
covered by unit and proptest cases. This audit documents where the
implementation lives, the two-buffer invariant, the sync fallback, and
the existing test coverage so future contributors do not reintroduce a
parallel primitive.
@github-actions github-actions Bot added the documentation Improvements or additions to documentation label May 14, 2026
@oferchen oferchen merged commit 832e492 into master May 14, 2026
8 checks passed
@oferchen oferchen deleted the docs/audit-double-buffered-checksum-pipeline-1759 branch May 14, 2026 14:57
oferchen added a commit that referenced this pull request May 18, 2026
…e-buffered (#4033)

Task #1759 asked for double-buffering in the retained checksum pipeline.
The work is already done in `crates/checksums/src/pipelined/`: the reader
pre-allocates two buffers, seeds one into a recycle channel, and uses a
bounded `sync_channel(1)` so the I/O thread reads block N+1 while the
caller hashes block N. Functional parity with the serialized hasher is
covered by unit and proptest cases. This audit documents where the
implementation lives, the two-buffer invariant, the sync fallback, and
the existing test coverage so future contributors do not reintroduce a
parallel primitive.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant