Repository navigation
CHORE: Improve PR performance sensitivity and measurement reliability - #845
Gaurav Sharma (bewithgaurav) wants to merge 1 commit into
Conversation
Detect consistent small and large changes without promoting isolated jitter into performance signals. Warm steady-state workloads in each measurement process and amortize short timings with fixed, comparable repetition blocks while retaining per-workload impact and diagnostic units. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
PR Performance Report✅ No regression detectedNo consistent slowdowns detected across all 2 environments. 0 SMALL IMPROVEMENTS 0 SMALL SLOWDOWNS 0 LARGE IMPROVEMENTS 0 LARGE SLOWDOWNS 2/2 ENVIRONMENTS Coverage: 2 of 2 environments completed. Advisory result; does not block merging. Performance diagnosticsPhase times are inclusive diagnostics and must not be added together. They identify where measured time changed, not why it changed. No affected phases or call-count changes were recorded. All database tasks and timingsUnix / SQL Server 2022
Unix / SQL Server 2025
Build and measurement detailsPR head:
Tentative small impact requires more than 10% median paired movement; large impact requires more than 20%. Both require at least 1 ms between the median per-workload runtimes and at least 80% of pairs exceeding that tier's threshold in the same direction. Large impact is evaluated first. Unconfirmed movement remains no signal. The displayed change is the median of paired before-and-after ratios. It is not recalculated from the two displayed median runtimes. Repeated blocks use the mean time per original workload; phase timings and call counts are normalized per repetition. Inner repetitions are not additional independent pairs. Both revisions use profiling-enabled builds on the same agent and database, with alternating order and discarded warmups. Results are diagnostic and do not represent production-wheel latency. Raw samples and logs are attached to the ADO run as |
There was a problem hiding this comment.
🔵 Needs a closer look
Hosted Linux behavior and timing reliability remain dependent on CI evidence beyond the supplied local macOS control.
0 open findings
What changed in this PR
Improves profiler sensitivity and reliability through tiered signals, warmups, repeated short workloads, and stricter artifact validation.
Changes:
- Adds 10% tentative-small and 20% large impact tiers.
- Warms steady-state scenarios and repeats short workloads.
- Normalizes diagnostics and expands tests/documentation.
| File | Description |
|---|---|
tests/test_036_profiler_ci.py |
Covers tiers, repetition validation, warmups, and reporting. |
eng/profiler_benchmarks/workloads.py |
Defines fixed short-workload repetition counts. |
eng/profiler_benchmarks/report.py |
Validates, classifies, normalizes, and renders results. |
eng/profiler_benchmarks/README.md |
Documents updated measurement semantics. |
eng/profiler_benchmarks/controller.py |
Implements per-process warmup and repeated measurement. |
🧠 Review effort: Balanced
💡 Configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
📊 Code Coverage Report
Diff CoverageDiff: main...HEAD, staged and unstaged changesNo lines with coverage information in this diff. 📋 Files Needing Attention📉 Files with overall lowest coverage (click to expand)mssql_python.pybind.performance_counter.hpp: 0.7%
mssql_python.pybind.logger_bridge.cpp: 57.9%
mssql_python.pybind.ddbc_bindings.h: 62.6%
mssql_python.pybind.logger_bridge.hpp: 70.8%
mssql_python.pybind.connection.connection_pool.cpp: 82.3%
mssql_python.pybind.connection.connection.cpp: 83.1%
mssql_python.logging.py: 86.2%
mssql_python.pooling.py: 90.1%
mssql_python.pybind.fetch_temporal.hpp: 92.1%
mssql_python.cursor.py: 92.5%🔗 Quick Links
|
Work Item / Issue Reference
Summary
Make PR Performance Reports more sensitive to consistent changes while reducing first-use and short-measurement noise.
Validation
164 profiler CI contract tests passed. Pinned formatting and changed-file lint checks passed.
Five fresh-process same-build pairs against local SQL Server 2022 covered all 22 tasks with zero signals, 0.63% median absolute paired movement, and 3.40% maximum movement. This is a local macOS control, not a claim that hosted Linux variance has been eliminated.
No runtime driver changes, additional dependencies, dedicated-runner configuration, or CI matrix expansion.