Domain-Specific Multi-Level IR Rewriting for GPU

Tobias Gysi, Christoph Müller, Oleksandr Zinenko, Stephan Herhut, Eddie Davis +4 more
5/26/2020
cs.PL

Official code: spcl/open-earth-compiler (83 stars, MLIR, last commit 2021-02-19).

Abstract

Traditional compilers operate on a single generic intermediate representation (IR). These IRs are usually low-level and close to machine instructions.

Show full abstract

As a result, optimizations relying on domain-specific information are either not possible or require complex analysis to recover the missing information. In contrast, multi-level rewriting instantiates a hierarchy of dialects (IRs), lowers programs level-by-level, and performs code transformations at the most suitable level. We demonstrate the effectiveness of this approach for the weather and climate domain. In particular, we develop a prototype compiler and design stencil- and GPU-specific dialects based on a set of newly introduced design principles. We find that two domain-specific optimizations (500 lines of code) realized on top of LLVM's extensible MLIR compiler infrastructure suffice to outperform state-of-the-art solutions. In essence, multi-level rewriting promises to herald the age of specialized compilers composed from domain- and target-specific dialects implemented on top of a shared infrastructure.

View on arXivView PDF

Code Implementations(1)

development repository for the open earth compiler

8315MLIR, C++Dec 14, 20195 years agoNOASSERTION
climatecompilerhigh-performance-computingmlirstencil+1 more

Similar Papers

Cite this paper

@article{gysi2020domainspecific,
  title  = {Domain-Specific Multi-Level IR Rewriting for GPU},
  author = {Tobias Gysi and Christoph Müller and Oleksandr Zinenko and Stephan Herhut and Eddie Davis and Tobias Wicky and Oliver Fuhrer and Torsten Hoefler and Tobias Grosser},
  year   = {2020},
  eprint = {2005.13014},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/2005.13014}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2005.13014.svg)](https://codeofpaper.com/paper/2005.13014)

Discussion