PGO doesn't make your workload fast — it tells the compiler which code is hot and reshapes the entire binary
PGO or not PGO this is the dilemma. Step 2
Percona's deep dive into Profile-Guided Optimization explains how a two-pass build uses edge-level counters from a training run to drive inlining, branch layout, hot/cold splitting, function reordering, and indirect-call promotion. The key insight: PGO optimizes for control-flow shape, not data values, so broad coverage like MTR can transfer well to production even with different data.
Crucially, PGO is not 'make the trained workload fast' it's 'tell the compiler which code is hot and which is cold, and let it reshape the whole binary accordingly.'