PredComp: Predicting Compiler Optimization Options with Multi-stage Learning
Open Access
- 25 June 2026
- journal article
- Published by Association for Computing Machinery (ACM) in ACM Transactions on Architecture and Code Optimization
- Vol. 23 (2) , 1-25
Abstract
Standard compiler optimization levels, such as -O3 , which provides a fixed optimization strategy for all programs, often fail to deliver the optimal performance. Compiler auto-tuning techniques can deliver substantial speedups, but existing methods present a difficult tradeoff. While dynamic iterative approaches are effective, their requirement for repeated compilation and execution incurs high overhead, which limits their practicality. Conversely, static prediction methods offer a low-overhead alternative. However, they face a vast search space and must comprehensively learn both option-option interactions and option-program feature relationships. To overcome the challenge, we propose PredComp , a novel static framework that leverages the divide and conquer paradigm to predict desired option sets. PredComp decomposes the search space by partitioning options into distinct subspaces based on their relationships, making the prediction problem tractable. It first predicts promising option sub-sets within each subspace, focusing only on intra-subspace option interactions and their preferred program features. Then, it adopts a combination model that aggregates these top-ranked sub-sets, prioritizes inter-subspace option interactions and corresponding features to construct globally desired sets. Experiments on three widely used benchmark suites and one real-world application show that PredComp achieves average speedups of 1.1011× over -O3 with a single prediction. Notably, it achieves performance comparable to dynamic iterative methods while reducing tuning time from hours or days to seconds, thereby making static prediction a practical solution for large-scale and frequently evolving software.Keywords
Funding Information
- Beijing Natural Science Foundation (L243010)
- ZTE Corporation
This publication has 29 references indexed in Scilit:
- Compiler Auto-Tuning via Critical Flag Selection2023
- Hierarchical Gating Networks for Sequential Recommendation2019
- A Survey on Compiler Autotuning using Machine LearningACM Computing Surveys, 2018
- Machine Learning in Compiler OptimizationProceedings of the IEEE, 2018
- SPEC CPU20172018
- MiCOMPACM Transactions on Architecture and Code Optimization, 2017
- Deep Neural Networks for YouTube Recommendations2016
- OpenTuner2014
- Evaluating iterative optimization across 1000 datasets2010
- Using Machine Learning to Focus Iterative Optimization2006