计算机工程与科学2023,Vol.45Issue(12):2121-2134,14.DOI:10.3969/j.issn.1007-130X.2023.12.004
多面体模型下的循环置换与自动调优
Loop permutation and auto-tuning under polyhedral model
摘要
Abstract
Aiming at improving the performance of the default loop scheduling and tile size of Pluto,a commonly used polyhedral compiler,this paper proposes a method to compute a variety of legal per-mutations for its default scheduling and auto-tune its performance according to the configuration space composed of permutations and tile sizes.Through the processing of scalar dimension that defines loop fusion,both intra and inter permutations for imperfect loop nest are realized.Four machine learning driven auto-tuning strategies are proposed to find the optimized combination of permutation order and tile size for a loop with a given problem size.Under the default tile size,the optimal permutation gene-rated by the extended Pluto compiler in a parallel environment achieves a maximum speedup of 4.02 and a geometric mean of 2.12 compared with the default scheduling of Pluto.By further searching for a bet-ter combination of permutation order and tile size,the best auto-tuning strategy achieves a maximum speedup of 5.48 and a geometric mean of 2.86 compared with Pluto's default optimization in a parallel environment.In addition,the best configuration and the learned model obtained by auto-tuning for a particular problem size,when being applied to similar problem sizes,also outperform the default opti-mization of Pluto in various degrees.关键词
循环置换/循环分块/多面体模型/自动调优/机器学习Key words
loop permutation/loop tiling/polyhedral model/auto-tuning/machine learning分类
信息技术与安全科学引用本文复制引用
彭畅,刘青枝,陈长波..多面体模型下的循环置换与自动调优[J].计算机工程与科学,2023,45(12):2121-2134,14.基金项目
国家重点研发计划(2020YFA0712300) (2020YFA0712300)
重庆英才计划青年拔尖项目(2021000263) (2021000263)
中国科学院"西部之光" ()
重庆市院士牵头科技创新引导专项(cstc2019yszx-jcyjX0003,cstc2020yszx-jcyjX0005,cstc2021yszx-jcyjX0005) (cstc2019yszx-jcyjX0003,cstc2020yszx-jcyjX0005,cstc2021yszx-jcyjX0005)