Optimize Windows on Arm C++ apps with profile-guided optimization
Introduction
Understand Profile-Guided Optimization
Understand Google Benchmark basics
Create a baseline benchmark
Apply Profile-Guided Optimization
Next Steps
Optimize Windows on Arm C++ apps with profile-guided optimization
Review frequently asked questions
These FAQs were drafted with an approved AI-assisted workflow and reviewed by Arm contributors before publication. Human technical review remains part of the process so the final page reflects engineering rigor, accuracy, and Arm editorial standards.
Open ARM64 Native Tools Command Prompt. Start PowerShell from there if needed, then navigate to your project directory before running build and benchmark steps.
Record the benchmark measurements for the division routine. You’ll compare the same benchmark after rebuilding with PGO.
Run the same division benchmark before and after rebuilding with the collected profile data. Keep the benchmark setup consistent, then compare the reported measurements to evaluate the impact of PGO.
Build an instrumented binary, run it to generate the execution profile, then rebuild using that profile. If you skip the run, the optimized build won’t use profile information, and your comparison won’t reflect PGO.
Division has higher latency and lower throughput than simple arithmetic on most CPU architectures, including Arm. The operation provides a clear baseline to observe the effect of PGO on a costlier operation.