Repository navigation
Interleave baseline and new benchmark rounds - #173
Merged
Merged
Conversation
Sequential baseline and new phases on shared cloud VMs can shift every sample when VM speed changes between phases. Alternate shorter rounds in new/baseline, baseline/new order and merge them per side, so drift widens error bars instead of producing a false difference. Add ts-perf merge --iterations to record the per-side total, and mark scenarios cloned at the compiler commit so they are set up again when switching sides.
Interleaved jobs check for quiet eight times instead of twice, so rare timeouts from brief periodic I/O on otherwise idle VMs fail runs far more often. Retry each check up to three times before failing.
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.
Comparisons used to measure every new-compiler iteration and then every baseline iteration. On shared Azure VMs the VM's speed can change between those two phases, which shifts every sample on one side and produces false regressions/improvements (up to 7% in A/A runs).
This alternates the two sides in 4 pairs of shorter rounds (new/baseline, then baseline/new, ...) so drift hits both sides about equally, then merges the rounds back into one benchmark file per side.
ts-perf mergegains--iterationsto record the total, since merging files with different counts otherwise drops it.stradascenarios when comparing JS compilers) are set up again when switching sides.clone_strada_scenariomarks this withTSPERF_SCENARIO_COMMIT_DEPENDENT_FILE.INTERLEAVE_BENCHMARKS(default on) can turn this off to get the old sequential steps.Validation on the Azure Linux pool (preset
faster), 13 scenarios per run:On a real two-commit comparison, the sequential run reported a false +6.1% on vscode; the interleaved run kept every scenario within ±1.8%. Measurement takes about twice as long (warmups per round), but whole jobs take only about 5–10% longer.