29938

Enabling Profile Guided Optimizations (PGO) for Graphics

Emma Jansson
Department of Computer Science, Lund University
Lund University Libraries, 2025
BibTeX

Download Download (PDF)   View View   Source Source   

311

views

This master thesis presents an implementation for enabling profile-guided optimizations (PGO) for mobile phone GPUs. PGO is an optimization technique that uses runtime profiling data, like block frequency and function call frequency, to guide compiler optimizations. The implementation is done by adapting the existing PGO infrastructure in LLVM to serve the architectural differences between CPUs and GPUs. Analyzing how PGO functions in LLVM/Clang for CPUs, necessary adaptations were identified to fit the GPU architecture. A major difference includes GPUs not being able to allocate their own memory, requiring modifications to where profile counters and necessary profile information about each function are stored. For this, a new compiler pass has been developed to collect the important profile information for each function, while the storing of profile counters has been outsourced to the GPU driver, which also manages writing the final profile data file that is later given back to the compiler. Evaluation of exposing the collected PGO data to existing compiler passes shows valuable performance improvements, with up to 3.74% fewer clock cycles and 6.32% fewer message instructions between threads. This proves that enabling PGO for graphics can lead to more efficient execution of workloads on GPUs.
No votes yet.
Please wait...

* * *

* * *

HGPU group © 2010-2025 hgpu.org

All rights belong to the respective authors

Contact us:

contact@hpgu.org