A Graph-Based Algorithm for Optimizing GCC Compiler Flag Settings

Compiler tuning through external mechanisms such as source code modifications, e.g., with pragmas, and adjusting compiler flags - is well-explored. Many researchers have shown significant performance improvement through different approaches, including heuristics and machine learning. Most of these a...

Full description

Saved in:
Bibliographic Details
Published inIEEE Conference on High Performance Extreme Computing (Online) pp. 1 - 8
Main Authors Sajjadinasab, Reza, Arora, Sanjay, Drepper, Ulrich, Sanaullah, Ahmed, Herbordt, Martin
Format Conference Proceeding
LanguageEnglish
Published IEEE 23.09.2024
Subjects
Online AccessGet full text
ISSN2643-1971
DOI10.1109/HPEC62836.2024.10938458

Cover

More Information
Summary:Compiler tuning through external mechanisms such as source code modifications, e.g., with pragmas, and adjusting compiler flags - is well-explored. Many researchers have shown significant performance improvement through different approaches, including heuristics and machine learning. Most of these approaches, however, require a few hundred iterations to converge towards an optimal answer. A number of studies have addressed this problem by reducing the number of iterations required, but we find that further improvements are still possible. In this work, we explore the optimization of GCC compiler flag settings with the goal of faster convergence. We find as an ancillary result that the effectiveness of the compilation itself is sometimes improved with respect to both code size reduction and application program execution time. The proposed graph-based approach can reduce the code size to 90 % of the convergence point with 15 compilations fewer on average, i.e., the solution found after running Opentuner for many compilations. It also can reduce the execution time over the -O3 level for different versions of the Smith-Waterman and Bubble Sort by 1.2 \times and 5 \times , respectively.
ISSN:2643-1971
DOI:10.1109/HPEC62836.2024.10938458