Simulation-based Code Duplication for Enhancing Compiler Optimizations

Simulation-based Code Duplication for Enhancing Compiler Optimizations

David Leopoldseder

17 July 2017

Compiler optimizations are often limited by control flow, which prohibits optimizations across basic block boundaries. Duplicating instructions from merge blocks to their prede- cessors enlarges basic blocks and can thus enable further optimizations. However, duplicating too many instructions leads to excessive code growth. Therefore, an approach is necessary that avoids code explosion and still finds beneficial duplication candidates. We present a novel approach to determine which code should be duplicated to improve peak performance. There- fore, we analyze duplication candidates for subsequent op- timizations by simulating a duplication and analyzing its impact on the compilation unit. This allows a compiler to find those duplication candidates that have the maximum optimization potential.


Venue : SPLASH'17 Student Research Competition

File Name : leopoldseder_splash_src2017.pdf