build-performance-analysis
Installation
SKILL.md
Build Performance Analysis with vcperf.exe
Execution order
A single workflow, always run in order.
Workflow — always run, in order
Treat each session as independent. Re-capture traces, JSON analysis, and baseline measurements fresh each session instead of reusing data from a previous session — the one-time trace-permission grant persists.
- Prerequisites: Trace Permission — grant ETW rights. Run before any workspace exploration (project enumeration, file listing, code search).
- Core Workflow + The /jsonAnalysis Flag
- Baseline Measurement — 5 uninstrumented clean rebuilds of the pre-change state; average for a stable baseline. Make no code or project edits during this step.
- Remediation Strategies — the first step where you edit anything; apply changes informed by Steps 2–3.
- Measuring Final Performance Improvement — 5 uninstrumented clean rebuilds of the post-change state; compare against the baseline. If a PCH or template change shows a neutral or regressed delta, also run Iterative Build Measurement.
Which vcperf.exe executable should I use?
The sessionStart hook installs vcperf.exe under %LOCALAPPDATA%\vcperf\build-perf-cpp (multiple versions may coexist). Resolve the newest version once and reuse it: