Program analysis at Google faces several challenges:
- Google applications are large, complicated, distributed, and irregular
- The compiler is an important tool for performance but many optimizations fail
- Google's approach combines static interprocedural analysis with runtime information to create advanced analysis and performance tools that use the compiler as a powerful analysis tool.
2024: Domino Containers - The Next Step. News from the Domino Container commu...
Open64 cgo07-google 01
1. Program Analysis @ Google
Robert Hundt, Platforms
rhundt@google.com
Open64 Workshop, CGO, 3/11/2007
2. Challenges
Google Applications Typical Profile
6
• Large and complicated
5
• Distributed and irregular
4
• Max out gcc FE space %3 % execution
• Well tuned, manually 2
1
Machines 0
1 2 3 4 5 6 7 8 9 10
• Fast evolving Function
Program Analysis
• Many dimensions
• Compiler is an important one
• Phase 1: Single machine performance, correctness
2/32
Open64 Tutorial,
3. (My) Background
Manual Performance Tuning
Only vague idea of how compilers work - experimental.
Work in Performance Tools
Runtime analysis/measurements - no insight into application
Work in Compiler
Strong static analysis - no runtime information
PBO (FDO) improves the situation
Many optimizations fail
(Almost) no information to the user
3/32
Open64 Tutorial,
4. Approach
Combine
• Static Inter-Procedural Analysis
• Runtime Information
Create
• Advanced Analysis Tools
• Performance Tools (Raman, CGO 2007)
• Correctness Tools (Engler, Stanford)
• High Performance Compiler
“Use the compiler as an awkward, but powerful performance analysis tool”
4/32
Open64 Tutorial,
5. Strategy
Infrastructure: Open64
• Mature, scalable, strong IR, strong research community
• LLVM is an option
Leverage external
• Work with Universities ($)
• Leverage cutting edge developments
• Push Google specific research
• Data Layout Analysis, GVL (Jianian Yan, Paul Yuan)
Leverage internal, 20%
• Dynamic memory analysis (PIN + static analysis)
• Interns (correctness tools)
5/32
Open64 Tutorial,
6. Risks
Robustness = Critical
• Small staff - can’t be eaten by bugs
• FE: gcc community
• Middle-end: Universities, Osprey, HP, Google
• x86 back-end: PathScale, Google
• Community effort (!)
• Suggestions WELCOME!
gcc vs. Open64 vs. LLVM
• Clash of civilizations…
6/32
Open64 Tutorial,
7. Future
A lot of fun !
• Exploring cutting edge developments
• Google specific optimizations
• Benchmarks soon to be released, please sign up!
• Phase 2: Tiered applications
• Wild ideas…
We are hiring !!!
7/32
Open64 Tutorial,