Code Generation for In-Place Stencils

Code Generation for In-Place Stencils
复制标题

就地模板的代码生成

DOI:
--
复制
发表时间:
2023
期刊:
IEEE/ACM International Symposium on Code Generation and Optimization
影响因子:
--
通讯作者:
Albert Cohen
Albert Cohen
中科院分区:
--
文献类型:
--
作者:
M. Essadki;B. Michel;B. Maugars;O. Zinenko;Nicolas Vasilache;Albert Cohen

文献摘要

参考文献

被引文献

相似文献

数值模拟通常采用迭代原地展开法,如高斯-赛德尔法或逐次超松弛法(SOR)。编写这种模板的高性能实现需要大量的精力和时间;它还涉及到模板内核本身之外的非局部转换。虽然自动化代码生成是一种成熟的图像处理扩展、卷积和不适当迭代扩展(例如Jacobi方法)技术,但适当扩展的优化需要手工技巧。基于张量编译器构建的最新进展,我们提出了第一个用于迭代就地stenchmark的特定于域的代码生成器。从MLIR框架中实现的通用张量编译器开始,张量抽象被逐步细化并降低到并行,平铺,融合和矢量化代码。我们使用我们的发电机实现了一个现实的,隐式求解器的结构网格,并证明结果与工业计算流体动力学框架的竞争力。我们还比较了密集张量的独立模板内核。
Numerical simulation often resorts to iterative in-place stencils such as the Gauss-Seidel or Successive Overrelaxation (SOR) methods. Writing high performance implementations of such stencils requires significant effort and time; it also involves non-local transformations beyond the stencil kernel itself. While automated code generation is a mature technology for image processing stencils, convolutions and out-of-place iterative stencils (such as the Jacobi method), the optimization of in-place stencils requires manual craftsmanship. Building on recent advances in tensor compiler construction, we propose the first domain-specific code generator for iterative in-place stencils. Starting from a generic tensor compiler implemented in the MLIR framework, tensor abstractions are incrementally refined and lowered down to parallel, tiled, fused and vectorized code. We used our generator to implement a realistic, implicit solver for structured meshes, and demonstrate results competitive with an industrial computational fluid dynamics framework. We also compare with stand-alone stencil kernels for dense tensors.
DOI: 10.1145/3445814.3446692
发表时间: 2021-04
期刊: Proceedings of the 26th ACM International Conference on Architectural Support for Programming Languages and Operating Systems
影响因子: --
作者:
Yishen Chen;Charith Mendis;Michael Carbin;Saman P. Amarasinghe
通讯作者: Yishen Chen;Charith Mendis;Michael Carbin;Saman P. Amarasinghe