Skip to content

Walk: build each entry's path at its exact length - #1508

Merged
thekevinbot merged 4 commits into
mainfrom
bot/speed-gap-childpath-1011
Oct 13, 2026
Merged

thekevinbot merged 4 commits into
mainfrom
bot/speed-gap-childpath-1011

Conversation

@thekevinbot

@thekevinbot thekevinbot commented Oct 12, 2026 •

Copy link
Copy Markdown
Collaborator

Refs #1474, #1475, #1476

The walk built each entry's path with rel.join(name), a malloc plus a realloc per entry on every worker thread; the allocator's arena locks contended. It now allocates the exact length once.

Local, 400k files, load 6-9, same-machine A/B against origin/main (hyperfine, 25 runs, interleaved), output md5 identical:

Glob Before After
./**/{a,b}*.md 58.5 ms 41-44 ms
./**/[a-c]*.md 62-63 ms 46 ms
./**/*.md 82-83 ms 82-86 ms (no change)

No case crosses its FASTEST tolerance, so no bar flips.

Red run: 38200140376 (Rust CI; both child_path_* unit tests fail on capacity, 32 vs 25).

Changelog / Migrations

  • Changelog fragment under packages/rust/changelog.d/
  • Migration fragment with the same slug under packages/rust/migrations.d/

E2E Verification

  • Ran e2e suites locally for every affected SDK
  • Python SDK e2e: pass
  • TypeScript SDK e2e: pass
  • Rust core e2e: N/A beyond the above
  • Receipts: packages/python/e2e-attestations/bot-speed-gap-childpath-1011.json, packages/ts/e2e-attestations/bot-speed-gap-childpath-1011.json
  • Command(s) run: pytest tests/e2e/glob_speed_{depth_bound,one_level,recursive,symlink,matchers,dotfiles,gitignore}_test.py -x -q; pnpm test:e2e
  • Result summary: all pass

@thekevinbot
thekevinbot marked this pull request as ready for review October 12, 2026 04:08
@thekevinbot
thekevinbot merged commit 462b3c6 into main Oct 13, 2026
89 checks passed
@thekevinbot
thekevinbot deleted the bot/speed-gap-childpath-1011 branch October 13, 2026 21:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant