Repository navigation
Time the dispatcher's bookkeeping as a ratio, not against a fixed limit - #73
Merged
Merged
Conversation
The 20,000-job test asserted under 15 s of wall clock, and CI's Windows PowerShell 5.1 runners take anywhere from about 4 to 14.5 s on the same code. It now times 20,000 jobs against the quicker of two 5,000-job runs in the same process and fails at 8 times as long: linear bookkeeping is about 4, and a PowerShell-level walk of the queue per job gives 9 to 10.6 while staying inside the old 15 s limit. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…an't see Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
What was wrong
The harness's 20,000-job bookkeeping test asserted that the run finished in under 15 s of wall clock. On the same code, CI's Windows PowerShell 5.1 runners take anywhere from about 4 to 14.5 s, so a slow runner could fail a required check with nothing wrong. A fixed limit also misses the regression the test is there for: a PowerShell-level walk of the pending queue per job (quadratic) took 20,000 jobs to 7.7 s locally on 5.1, inside the old limit.
What changed
The test times 20,000 jobs against the quicker of two 5,000-job runs, in the same process, and fails if the larger takes 8 times as long or more. Linear bookkeeping gives about 4. A 45 s ceiling on the 20,000-job run (about 3 times CI's slowest 5.1 time) stays for a slowdown that's the same for every job, which a ratio can't see. Harness only.
How it was tested
$null = @($pkPending).Countadded after each dequeue (a walk per job), the new assertion fails on both runtimes: 9.3 times on 5.1 (8.5 s for 20,000 jobs) and 10.6 on 7 (6.3 s). Both of those are under the old 15 s limit, which would have passed them.🤖 Generated with Claude Code