LOOPer:一种基于学习的自动代码优化器用于多面体编译器
LOOPer: A Learned Automatic Code Optimizer For Polyhedral Compilers
AI总结:
LOOPer是首个基于深度学习的多面体自动调度器,能高效优化广泛程序并实现复杂转换序列,其在基准测试中表现优异。
摘要:
尽管多面体编译器在实现高级代码转换方面已取得成功,但它们在选择导致最大加速的转换方面仍面临挑战。这促使了基于机器学习的成本模型用于指导多面体优化搜索的使用。最先进的多面体编译器已展示了这种方法的可行证明。尽管有希望,但这种方法仍面临显著限制。最先进的多面体编译器使用深度学习成本模型只支持少量的仿射转换,限制了它们探索复杂代码转换的能力。此外,其适用性无法扩展到简单的程序之外,因此排除了许多程序类别,如具有非矩形迭代域或多个循环嵌套的程序。这些限制显著影响此类编译器和自动调度器的通用性,并对整个方法提出质疑。在本文中,我们介绍了LOOPer,这是首个使用基于深度学习的成本模型的多面体自动调度器,能够覆盖大量的仿射转换和程序。LOOPer允许对广泛的程序集进行优化,同时在应用复杂的多面体转换序列时表现出色。我们实现了并评估了LOOPer,并证明其在最先进的方法上实现了具有竞争力的加速。在PolyBench基准测试中,LOOPer在Tiramisu上实现了1.84倍的几何平均加速,在Pluto上实现了1.42倍的加速,这两个都是最先进的多面体自动调度器。
英文摘要:
While polyhedral compilers have shown success in implementing advanced code transformations, they still face challenges in selecting the ones that lead to the most profitable speedups. This has motivated the use of machine learning based cost models to guide the search for polyhedral optimizations. State-of-the-art polyhedral compilers have demonstrated a viable proof-of-concept of such an approach. While promising, this approach still faces significant limitations. State-of-the-art polyhedral compilers that use a deep learning cost model only support a small subset of affine transformations, limiting their ability to explore complex code transformations. Furthermore, their applicability does not scale beyond simple programs, thus excluding many program classes from their scope, such as those with non-rectangular iteration domains or multiple loop nests. These limitations significantly impact the generality of such compilers and autoschedulers and put into question the whole approach. In this paper, we introduce LOOPer, the first polyhedral autoscheduler that uses a deep learning based cost model and covers a large space of affine transformations and programs. LOOPer allows the optimization of an extensive set of programs while being effective at applying complex sequences of polyhedral transformations. We implement and evaluate LOOPer and show that it achieves competitive speedups over the state-of-the-art. On the PolyBench benchmarks, LOOPer achieves a geometric mean speedup of 1.84x over Tiramisu and 1.42x over Pluto, two state-of-the-art polyhedral autoschedulers.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。