Repository navigation
Fix CUDA scaling timing stability gate - #31
Merged
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
This PR stabilizes the CUDA performance “scaling timing” gate by requiring both a relative (ratio) and absolute (seconds) drift threshold before repeated-fit timings are considered unstable, preventing subsecond scheduler jitter from failing CI.
Changes:
- Update the repeated-fit timing instability check to require
>2xand>1sspread before failing. - Add a regression test that covers the observed subsecond timing spread scenario.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
scripts/ci/check_performance.py |
Tightens the instability condition by combining ratio and absolute timing-spread thresholds. |
tests/test_release_candidate.py |
Adds a test ensuring subsecond timing jitter does not trip the performance checker. |
Suppressed comments (1)
scripts/ci/check_performance.py:52
- The timing-range assertion message no longer reflects the actual gate condition. The check now requires both exceeding the ratio and exceeding the absolute allowance, but the error only mentions the ratio, which can mislead debugging when this fails in CI.
raise AssertionError(
f"{name} fit timing range exceeded {MAX_TIMING_RANGE}x: {fit_times}"
)
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
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 changed
Root cause
The repeated-performance checker used only a relative ratio once a sample reached 100 ms. A short scheduler pause changed SDF timings from roughly 0.12-0.24 seconds to 0.50-0.68 seconds, which failed the ratio despite exact replay and passing within-run scaling checks.
Impact
Subsecond CUDA measurements no longer fail because of normal scheduling jitter. Material timing drift remains blocking: the existing 1-to-3 second regression still fails.
Validation