Repository navigation
Conversation
3784053 to
38210c8
Compare
…dmission-review # Conflicts: # docs/performance-analysis.md
|
Closing as rejected: the current four-millisecond directory admission gate and synchronous first-child probe. The post-clock-fix reassessment supports a definitive rejection of this policy. The 9,240 oracle-correct fresh-command invocations include warmed-pool and injected-latency controls. Representative paired results:
The small Linux startup saving does not justify these counterexamples, and retuning a millisecond constant to these hosts is not a portable remedy. The independent libpfm query-download repair was retained in merged #1035; rejecting the admission policy does not discard it. Useful bounded read-ahead was subsequently isolated on the existing pool and merged as #1039, without this policy or shared-executor integration: its distinct measurements and limitations. That result is not acceptance of this gate. Keep actual startup/queue overhead, heterogeneous/physical/network storage and worker-budget qualification tracked under JC05/JC06/JC07. Evidence and interpretation: complete cross-platform audit, raw samples, exact source patches and identities. Integration measurements use explicitly recorded synthetic ports onto clock-corrected main This closure does not delete the branch, rewrite any commit, merge experimental runtime code, or claim that all worker/queue research is finished. |
Post-clock-fix measurements show that this admission policy trades small startup savings for substantial slow-directory regressions. Keep this PR draft; the recommendation is to reject the current 4 ms gate and synchronous first-child sampling, and retain main's scheduling while a simpler replacement is evaluated.
AG;DR
Current state and scope
974d137026818bba1c1deaf6cfc4fffe676b314e, including bashtest Upgrade bashtest to 0.7.1 and remove launcher workaround #1033 and the Abseil steady-clock fix Avoid Abseil hardware-clock calibration during worker startup #1034. The synchronization was pushed before measuring.--config=clang_release. No threshold retuning or other runtime change was introduced for this reassessment.d5cffe57b957266dc14bb301643bfa4e0b05525a. The subsequent evidence commit changes only tracking, analysis and a compressed data bundle.docs/performance-analysis.mdwith the retention recommendation. Keep worker admission separate from CPU/worker-budget tuning and actual pool startup/reuse work.New paired measurements
Linux: Ryzen 9950X KVM guest on drogon via SSH, ten vCPUs, tmpfs fixtures, pinned 1/3/10 CPU budgets. macOS: Apple M5 Pro, 18 cores, macOS 26.6 arm64, warm APFS fixtures, worker budgets 1/3/10 without CPU pinning. Compare variants within each platform, not the operating systems or hardware against each other.
Each platform has 72 listing/metadata/content cases across eight shapes spanning 10 through 65,536 files. Linux adds ten uniform-delay, asymmetric-child-delay and warm-pool controls. All builds finish before timing. Each case uses discarded warmups, nine interleaved samples, the fastest-seven mean, and three differently ordered sessions. The native timer measures fork/exec/wait; Python startup, fixture creation and output checking are excluded. All 9,240 invocations pass independent output SHA256 oracles.
Negative is faster. Displayed times are medians of session estimates; changes are medians of paired session changes and can differ from the ratio of displayed medians.
The Linux small-scan benefit is now about 0.21 ms, versus roughly 3.4 ms in the earlier pre-clock-fix experiment. The slow-child sample still costs about 2 ms before parallel work starts. Its regression is reproducible across all three sessions. macOS's broad/nested 4,096-file metadata cases also regress by 6.6%/8.5%; large macOS listing and content workloads stay near main. Uniform delayed reads and existing-pool reuse stay near Linux main.
A separate Linux trace shows three worker creations on main and none under this policy for the small scan. Neither trace has the old 1 ms/2 ms calibration sleeps. Those sleeps were Abseil initialization, not unavoidable thread-start cost.
Decision and follow-up
Reject the current millisecond budget plus synchronous probe as the default. Its gains are confined mostly to cheap small scans, while the serial sample impedes precisely the small expensive frontiers that benefit from concurrency. Lowering the budget to fit one guest would not establish a general policy.
Investigate actual pool startup/queue overhead and bounded run-owned worker reuse, preserving concurrency without a synchronous sampling barrier. JC07 remains open for real slow storage, heterogeneous children, cold/warm behavior, cancellation, ordering, exactly-once effects and metadata behavior.
This branch also contains an independent libpfm source-query downloader repair and its tooling test/docs. Preserve or extract that maintenance fix if the admission implementation is discarded.
Evidence, validation and limitations
docs/benchmarks/directory-admission-post-clock-20261101.json.gz.docs/benchmarks/directory-admission-20261031.json.gz; it is historical analysis, not current performance acceptance.41247081300succeeds.