Bridging Control-Centric and Data-Centric Optimization Article Swipe
YOU?
·
· 2023
· Open Access
·
· DOI: https://doi.org/10.1145/3579990.3580018
· OA: W4321496220
With the rise of specialized hardware and new programming languages, code\noptimization has shifted its focus towards promoting data locality. Most\nproduction-grade compilers adopt a control-centric mindset - instruction-driven\noptimization augmented with scalar-based dataflow - whereas other approaches\nprovide domain-specific and general purpose data movement minimization, which\ncan miss important control-flow optimizations. As the two representations are\nnot commutable, users must choose one over the other. In this paper, we explore\nhow both control- and data-centric approaches can work in tandem via the\nMulti-Level Intermediate Representation (MLIR) framework. Through a combination\nof an MLIR dialect and specialized passes, we recover parametric, symbolic\ndataflow that can be optimized within the DaCe framework. We combine the two\nviews into a single pipeline, called DCIR, showing that it is strictly more\npowerful than either view. On several benchmarks and a real-world application\nin C, we show that our proposed pipeline consistently outperforms MLIR and\nautomatically uncovers new optimization opportunities with no additional\neffort.\n