Profile-Guided Optimization in the Go Compiler
summary
Adds end-to-end Profile-Guided Optimization to the Go toolchain by ingesting pprof protobuf format profiles in the frontend, carrying weights through SSA, and applying profile-guided inlining, code specialization, basic-block layout and function reordering in the backend and linker. Benchmarks show concrete wins—about 10% improvement in microbenchmarks where previously-uninlined hot callees become inlineable—while LLVM-style gains are cited at 15–30%. The inlining patch is upstream at https://go-review.googlesource.com/c/go/+/429863.
AI-written summary · about
related talks
34mThe basics of Profile-Guided Optimization (PGO) in Rust
30mProfile-Guided Optimization (PGO) in Rust: unknown parts
29mEmpirical Observations about Profile-Guided Optimizations for Mainstream C/C++ Compilers
21mDiagnosing Compiler Performance by Comparing Optimization Decisions
22mProfile Inference Revisited
19mOptimization-Aware Compiler-Level Event Profiling
24mFunction Inlining
35mInlining: bright victories and hidden defeats
