[Paper Review] DaCe - Data-Centric Parallel Programming Framework
This paper introduces Stateful DataFlow Multigraphs (SDFG), a data-centric intermediate representation that decouples scientific code from low-level optimizations, enabling performance portability across CPUs, GPUs, and FPGAs. By applying extensible graph transformations—such as tiling and double-buffering—on the SDFG, domain scientists can achieve near-peak hardware performance without modifying their original code.
DaCe compiles code in various programming languages and paradigms (Python/Numpy, MATLAB, TensorFlow) and maps it efficiently to CPUs, GPUs, and FPGAs with high utilization, on par with the state-of-the-art. The key feature driving DaCe is its Stateful DataFlow multiGraph (SDFG) <em>data-centric intermediate representation</em>: A transformable, interactive representation of code based on data movement. With data-centric parallel programming, we enable direct knowledge transfer of performance optimization, regardless of the scientific application or the target processor. DaCe can be written inline in Python and transformed in the command-line, or SDFGs can be interactively modified using the Data-centric Interactive Optimization Development Environment (DIODE). The latest version of the code can be found at https://github.com/spcl/dace<br>
Motivation & Objective
- To address the growing complexity of writing performant, portable code for heterogeneous architectures like GPUs and FPGAs.
- To decouple domain scientists' high-level code from low-level performance optimizations, reducing maintenance burden.
- To enable performance engineers to optimize code via transformations on an intermediate representation without altering the original scientific logic.
- To achieve performance portability such that the same code achieves high performance across diverse hardware platforms.
Proposed method
- Represents scientific code as a Stateful DataFlow Multigraph (SDFG), capturing fine-grained data dependencies and high-level control flow.
- Uses graph rewriting and pattern matching to apply program transformations such as tiling, double-buffering, and loop fusion.
- Employs a graphical user interface and extensible API for interactive, incremental optimization of SDFGs.
- Compiles SDFGs to optimized binaries for CPUs, GPUs, and FPGAs using a thin runtime and architecture-specific code generation.
- Separates domain code (in Python/MATLAB) from performance tuning, which is performed exclusively on the SDFG representation.
- Leverages dataflow tracking and memlet-based data movement modeling to enable precise optimization of data locality and movement.
Experimental results
Research questions
- RQ1Can a data-centric intermediate representation enable performance portability across CPUs, GPUs, and FPGAs without modifying the original scientific code?
- RQ2How effective are SDFG-based transformations—such as tiling and double-buffering—in improving performance on heterogeneous architectures?
- RQ3To what extent can performance engineers optimize code through SDFG transformations without deep knowledge of the domain-specific mathematics?
- RQ4Can SDFGs express and optimize a broad range of computational motifs, from kernels to graph analytics, with competitive performance?
Key findings
- SDFGs enable performance portability: the same scientific code achieves competitive performance on CPUs, GPUs, and FPGAs without modification.
- The SDFG framework allows performance engineers to achieve near-peak performance on all three target architectures through graph-based transformations.
- Tiling and double-buffering transformations applied to SDFGs significantly improve data locality and hide memory latency across diverse hardware.
- The approach maintains code understandability for domain scientists while enabling high-performance compilation via a separate, optimized SDFG representation.
- The framework supports a wide range of computational motifs, including fundamental kernels and graph analytics, demonstrating broad applicability.
- The separation of concerns between domain scientists and performance engineers reduces code maintenance overhead and avoids the need for full re-implementation on new architectures.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.