Repository navigation
test(sql): time the confirmation gate's cost guards in alternating rounds sized to their bound - #2256
Merged
Merged
Conversation
…unds sized to their bound The cost guards divided the cheapest of five runs of one side by the cheapest of five of the other, timed one after the other. A 1 ms walk often escapes preemption whole while a 12 ms gate run cannot, so a busy macOS runner read a script of short statements at 34.8 walks against a bound of 24, for a gate that costs about 12; the growth guard shares the flaw. Each guard now times one gate run, or two of the long text, against 24 times as many yardstick runs, in nine rounds that alternate which side goes first, and reads the median round, so both sides of a round take the same load where the cost meets the bound, which stays 24. On one CPU shared with two other test processes the old guards failed every run of the file and these none, while the gate before #2249 still reads above 30 on every shape.
… were measured to do
|
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.



The macOS cross-platform job failed on a diff that touches no SQL code: the gate's walk-ratio guard read 34.8 walks of a script of short statements against its bound of 24, for a gate that costs about 12.
Both cost guards compared the cheapest of five runs of each side, timed one after the other; a busy runner preempts a 12 ms gate run but often misses a 1 ms walk.
Each guard now times one gate run, or two of the long text, against 24 times as many yardstick runs in nine alternating rounds and reads the median, so both sides share the load at the bound, still 24.
With one CPU shared by three test processes the old guards failed every run and the new ones none (at most 15.6); the gate before #2249 still fails every shape (35.5 or more), and a one-line reconstruction of its quadratic lock clause check still fails its own shape (about 55, idle and loaded).