docs(audits): Vec<FileEntry> vs upstream pool allocator (#1050)#3833
Merged
Conversation
Document the container-level RSS gap between oc-rsync's Vec<FileEntry> + segmented file lists and upstream rsync's pool_alloc.c slab arena. Quantify Vec doubling slack, per-segment fragmentation, and pointer-array overhead at 100K and 1M file scales, then propose five remediation paths ranked by effort/payoff: pre-size from getdents count, bumpalo arena, typed-arena, custom slab pool, and inline-string path collapse. Recommend stacking the cheapest two for an estimated 40-50 MiB win at 1M entries.
oferchen
added a commit
that referenced
this pull request
May 18, 2026
Document the container-level RSS gap between oc-rsync's Vec<FileEntry> + segmented file lists and upstream rsync's pool_alloc.c slab arena. Quantify Vec doubling slack, per-segment fragmentation, and pointer-array overhead at 100K and 1M file scales, then propose five remediation paths ranked by effort/payoff: pre-size from getdents count, bumpalo arena, typed-arena, custom slab pool, and inline-string path collapse. Recommend stacking the cheapest two for an estimated 40-50 MiB win at 1M entries.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Vec<FileEntry>(plus segmented per-directory vectors) and upstream rsync'spool_alloc.cslab arena.Vecdoubling slack, per-segment fragmentation, and pointer-array overhead at 100K and 1M file scales; cross-check against the empirical 42.6 vs 7.9 MiB Mode-B baseline.getdentscount,bumpaloarena,typed-arena, custom slab pool, and inline-stringname+dirnamecollapse. Recommend stacking pre-size + path collapse for ~40-50 MiB win at 1M entries with no API breakage.Task: #1050. Companion to #1048 (path-heap), #966 (overall RSS), #971 (1M-file scaling).
Test plan
crates/protocol/src/flist/*andtarget/interop/upstream-src/rsync-3.4.1/{flist.c,rsync.h,lib/pool_alloc.c}.