arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2505.08598cs.SE
收藏

GroupTuner:高效的组感知编译器自动调优

GroupTuner: Efficient Group-Aware Compiler Auto-Tuning

Bingyu Gao, Mengyu Yao, Ziming Wang, Dong Liu, Ding Li, Xiangqun Chen, Yao Guo

AI总结:

针对编译器自动调优中关键选项识别困难导致易陷入局部最优的问题,提出组感知的 GroupTuner 方法,直接对历史最优组合进行局部变异,平均性能提升 12.39%,时间仅为随机搜索的 77.21%。

摘要:

现代编译器通常提供数百个用于优化程序性能的选项,但由于选项数量庞大,用户往往无法充分利用它们。虽然标准优化组合(如 -O3)提供了合理的默认设置,但它们往往无法在多样化的程序和架构上提供接近峰值性能。为了应对这一挑战,编译器自动调优技术应运而生,以自动化发现改进的选项组合。现有技术通常侧重于识别关键选项并在搜索过程中优先处理它们以提高效率。然而,由于调优迭代次数有限,产生的数据往往稀疏且带有噪声,这使得准确识别关键选项极具挑战性。因此,这些算法容易陷入局部最优解。为了解决这一局限性,我们提出了 GroupTuner,一种组感知的自动调优技术,它直接基于历史最佳性能组合对连贯的选项组进行局部变异,从而避免显式识别关键选项。通过放弃精确了解哪些选项最重要的需求,GroupTuner 最大化了对现有性能数据的利用,确保了更有针对性的探索。大量实验表明,GroupTuner 能够高效地发现具有竞争力的选项组合,与 -O3 相比实现了平均 12.39% 的性能提升,同时仅需随机搜索算法 77.21% 的时间,显著优于最先进的方法。

英文摘要:

Modern compilers typically provide hundreds of options to optimize program performance, but users often cannot fully leverage them due to the huge number of options. While standard optimization combinations (e.g., -O3) provide reasonable defaults, they often fail to deliver near-peak performance across diverse programs and architectures. To address this challenge, compiler auto-tuning techniques have emerged to automate the discovery of improved option combinations. Existing techniques typically focus on identifying critical options and prioritizing them during the search to improve efficiency. However, due to limited tuning iterations, the resulting data is often sparse and noisy, making it highly challenging to accurately identify critical options. As a result, these algorithms are prone to being trapped in local optima. To address this limitation, we propose GroupTuner, a group-aware auto-tuning technique that directly applies localized mutation to coherent option groups based on historically best-performing combinations, thus avoiding explicitly identifying critical options. By forgoing the need to know precisely which options are most important, GroupTuner maximizes the use of existing performance data, ensuring more targeted exploration. Extensive experiments demonstrate that GroupTuner can efficiently discover competitive option combinations, achieving an average performance improvement of 12.39% over -O3 while requiring only 77.21% of the time compared to the random search algorithm, significantly outperforming state-of-the-art methods.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑