mirror of
https://github.com/kvcache-ai/AgentENV.git
synced 2026-11-05 01:17:36 +00:00
[PR #13] [MERGED] feat(overlaybd): concurrent coalesced zfile read path with read-path metrics #117
Labels
No labels
bug
documentation
enhancement
enhancement
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
kvcache-ai/AgentENV#117
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/kvcache-ai/AgentENV/pull/13
Author: @huajq
Created: 7/27/2026
Status: ✅ Merged
Merged: 7/27/2026
Merged by: @huajq
Base:
main← Head:zfile📝 Commits (1)
a3318e3feat(overlaybd): concurrent coalesced zfile read path with read-path metrics📊 Changes
8 files changed (+2244 additions, -326 deletions)
View changed files
📝
Cargo.lock(+14 -1)📝
crates/observability/src/lib.rs(+25 -1)📝
storage/overlaybd/Cargo.toml(+8 -1)➕
storage/overlaybd/benches/zfile_read_benchmark.rs(+778 -0)📝
storage/overlaybd/src/backend/cache/meta.rs(+2 -5)📝
storage/overlaybd/src/compression/zfile.rs(+1097 -309)📝
storage/overlaybd/src/metrics.rs(+314 -1)📝
storage/overlaybd/src/prefetch.rs(+6 -8)📄 Description
Summary
ZFileROreads no longer serialize on a whole-request mutex:preadtakes&selfwith aSynccompressor, so reads on one shared handle overlap in the backing file.crctocrc32c(SSE4.2) in zfile, cache meta, and prefetch traces.zfile_readcriterion benchmark (read throughput, block size, compression throughput), using the rand 0.10 API (RngExt) to match this repo's dev-dependency.Benchmark
Xeon Platinum 8269CY, kernel 6.8, in-memory instrumented backing, criterion mean.
Read throughput
lz4_random4k_qd1zstd_random4k_qd1lz4_compressible_random4k_qd1zstd_compressible_random4k_qd1lz4_seq128k_qd1zstd_seq128k_qd1lz4_random4k_qd16_sharedzstd_random4k_qd16_sharedQD16 on one shared handle costs the same per page as QD1 (1.29 vs 1.25 µs), i.e. 16 concurrent reads overlap in the backing file instead of serializing.
Block size (4 KiB random read)
lz4_random4k_qd1_bs4klz4_random4k_qd1_bs64kMemory compression ratio
Compressed memory image size relative to the original (lower is better):
Verification
cargo test -p overlaybd --lib: 302 passed, 0 failedcargo clippy -p overlaybd --all-targets -- -D warnings: clean🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.