Detecting Hot Code from Partially Context-Sensitive Profiles

Maja Vukasović, Aleksandar Prokopec · 2024

In order to achieve the peek program performance, compilers employ numerous optimizations. Some of these optimizations, although highly effective, come with the high price in terms of compilation time, and the compiled code size. This is why it is beneficial to apply optimizations on only selected portions of the most frequently executed code – hot code. In JIT-compiled programs, information about the frequency of code execution is available during the compilation, however, AOT compilers must compensate through the profiling data collected from the previous program runs. In this paper, we use partially context-sensitive profiles, for efficient profile collection and managing, to identify and reconstruct significant hot-code fragments. We show that, with the proper identification of the hot code, significantly better program performance can be achieved with reasonable cost.

Read the paper · More papers on PaperTik