@inproceedings{2c78a687f0c946d58d7efbdddbdc4dd7,
title = "Just-in-Time Compilation and Link-Time Optimization for OpenMP Target Offloading",
abstract = "Following the mass adoption of external accelerators for high performance computing, the overall performance of many applications has become increasingly dependent on relatively small accelerated kernels. As static analysis is fundamentally limited by dynamic values and external definitions, standard ahead-of-time compilation is not always sufficient to achieve the best performance. Furthermore, many users looking to port an existing application to run on an external accelerator will not want to fundamentally restructure their programs. These and other problems can be addressed through both link-time optimization (LTO) and just-in-time (JIT) compilation, but until now had sparse and inconsistent support from the compiler. In this work, we present a new compilation method that enables device-side LTO as well as a transparent JIT compilation tool-chain for OpenMP target offloading. Our contributions include an entirely new device linking and embedding scheme to enable LTO as well as a novel JIT engine to efficiently optimize OpenMP offloading regions at run-time. We also introduce a persistent caching system to improve end-to-end runtime using the JIT engine and minimize kernel launching overheads. We measure the performance of our LTO and JIT implementation via several real-world scientific applications. With our optimizations we observe significant improvements through LTO on large applications as well as significant end-to-end execution time improvement using JIT.",
keywords = "GPU, JIT, LTO, OpenMP",
author = "Shilei Tian and Joseph Huber and John Tramm and Barbara Chapman and Johannes Doerfert",
note = "Publisher Copyright: {\textcopyright} 2022, The Author(s), under exclusive license to Springer Nature Switzerland AG.; 18th International Workshop on OpenMP, IWOMP 2022 ; Conference date: 27-09-2022 Through 30-09-2022",
year = "2022",
doi = "10.1007/978-3-031-15922-0\_10",
language = "English",
isbn = "9783031159213",
series = "Lecture Notes in Computer Science (including subseries Lecture Notes in Artificial Intelligence and Lecture Notes in Bioinformatics)",
publisher = "Springer Science and Business Media Deutschland GmbH",
pages = "145--158",
editor = "Michael Klemm and \{de Supinski\}, \{Bronis R.\} and Jannis Klinkenberg and Brandon Neth",
booktitle = "OpenMP in a Modern World",
}