Skip to content

ci: remeasure unstable Windows lifecycle benchmarks - #117

Merged
Pedro Henrique Penna (ppenna) merged 1 commit into
devfrom
copilot/fix-pooled-benchmark-retry
Sep 18, 2026
Merged

Pedro Henrique Penna (ppenna) merged 1 commit into
devfrom
copilot/fix-pooled-benchmark-retry

Conversation

@ppenna

Copy link
Copy Markdown
Contributor

Summary

  • add a validation-only performance command that distinguishes unstable lifecycle samples from malformed benchmark data
  • validate Windows lifecycle results immediately and remeasure the e2e benchmark once only for typed snapshot-generation instability
  • preserve the existing 25% p50-over-p25 stability guard and 50% historical regression threshold
  • add regression coverage from the failed pooled-runner artifact and document the CI behavior

Root cause

Workflow run 35382585623, attempt 1, failed in Platform / Windows / WHP / Virtual machine on azure-windows-2 while publishing performance results.

The snapshot-generation samples split into five normal 736-781 ms measurements and five slow 1233-1297 ms measurements. The split was isolated to mapped_memory_flush, which alternated between 674-723 ms and 1172-1222 ms. That produced p50 1006.945 ms versus p25 753.063 ms, exceeding the deliberate 25% stability limit.

This was not the 50% historical regression gate. Across the adjacent successful Windows runner artifacts inspected, stable cross-runner median differences peaked at 20.4%, while snapshot generation remained around 754-760 ms. The pooled scheduler exposed a transient WHP host-storage condition, but CI previously required a manual workflow rerun after detecting it.

Validation

  • failed lifecycle artifact returns temporary-failure status 75
  • stable lifecycle artifact returns status 0
  • simulated Windows remeasurement succeeds on the second result
  • 204 runnable CLI tests and 4 host-inventory tests pass
  • python -m compileall -q scripts
  • python -m ruff check scripts
  • Linux and Windows Pyright checks
  • python -m ruff format --check scripts
  • embedded PowerShell acceptance script parsing
  • git diff --check

Local Python 3.14 still fails the pre-existing Windows curl-shim resolution test identically on unchanged dev; all other tests pass, and the full CI runner validation remains authoritative.

Classify bimodal OpenVMM lifecycle results as a retryable validation outcome without weakening the existing 25% p50-over-p25 stability guard.

Validate Windows e2e results immediately and rerun the acceptance benchmark once only for that typed instability. Preserve normal failure behavior for malformed results and fail if the second measurement remains unstable.

Add regression coverage from workflow run 35382585623 and document the pooled-runner behavior.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: cf6bb716-116d-4646-8228-1177e711a06d
Copilot AI balanced review requested due to automatic review settings September 18, 2026 20:11

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟡 Changes recommended

Instability is classified before later malformed-data checks, allowing invalid results to trigger remeasurement.

Get a fresh assessment by requesting another Copilot review.

Review effort: Balanced
Findings: 1 Medium severity

Open (1)
What changed in this PR

Adds selective Windows lifecycle benchmark remeasurement for transient snapshot-generation instability.

Changes:

  • Introduces validation with exit status 75 for unstable samples.
  • Retries Windows lifecycle measurement once.
  • Adds tests and CI behavior documentation.
File Description
.github/​actions/​run-benchmark/​action.yml Adds selective lifecycle retry logic.
scripts/​nvx_tools/​performance.py Adds typed instability validation.
scripts/​test_performance.py Tests validation exit statuses.
scripts/​test_nvx_tools.py Checks workflow retry configuration.
doc/​usage.md Documents the validation command.
doc/​benchmarks.md Documents Windows retry behavior.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

ratio = p50 / p25
if ratio > LIFECYCLE_SNAPSHOT_MAX_P50_OVER_P25:
raise PerformanceError(
raise UnstablePerformanceError(
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants