错误:搜索内容不能为空,请输入英文关键词
错误:关键词超出字数限制,请精简
高级检索

Compiler Tuning Method Based on Program Feature Extraction and Model Prediction

  • Chenghua Xu,
  • Jingwei Sun,
  • Mengna Sai,
  • Dian Chen,
  • Guangzhong Sun,
  • Weiwu Hu

摘要

The optimization of compiler options has become increasingly crucial for improving the performance of programs. This paper proposes a compiler option optimization method based on feature extraction and model prediction, aiming to guide the optimal selection of compiler options by predicting the programs’ speedup. In this study, we utilized various program feature extraction methods, including traditional approaches, BERT-based methods, and large language model-based techniques, to extract program features. An experimental design was used to build a quantitative model of the relationship between compiler options and program’s speedups. Using the extracted program features and experimental data, we trained a regression model to predict programs’ speedup. Furthermore, a genetic algorithm was applied to optimize the selection of compiler options, with the aim of achieving optimal programs’ performance. Experimental results demonstrate that this method effectively optimizes compiler options, significantly improving programs’ runtime efficiency. This research offers a new perspective on the automated optimization of compiler options and establishes a foundation for future research.