FreeTensor: A Free-form DSL with Holistic Optimizations for Irregular Tensor Programs
summary
A Python-embedded DSL and compiler that compiles loop-based, irregular tensor code to native CPU/GPU kernels, using polyhedral analysis via isl to enable legal loop transforms, partial-evaluation of recursive dimension handling, and an AD strategy that recomputes only necessary intermediates. Evaluated on SubdivNet, LongForm, a differentiable renderer and GNNs against PyTorch/JAX/TVM/Julia/TGL, it reports up to 5.10× without AD, up to 12.7× with AD and an AD memory-reuse win of up to 6.83×, with far fewer GPU kernels and memory accesses.
AI-written summary · about
chapters (11)
- 0:00Intro
- 0:31Frameworks for Tensor Programs
- 1:24Tensor Operators vs. Irregularity
- 3:35Core Idea: Reintroducing Loops!
- 5:09Embedded Python DSL
- 6:05Optimizing Compiler
- 6:54Generic operations in Python DSL
- 8:24Dependence-aware Transformations
- 10:00Fine-grained Automatic Differentiation
- 12:37Performance Evaluation: End to End
- 13:20FreeTensor in a nutshell
related talks
24mVerified Tensor-Program Optimization Via High-Level Scheduling Rewrites
45mTensorly: A Flexible Python Framework for Machine Learning
28mFunctional Sparse Tensor Compilation
20mCompiling Structured Tensor Algebra
15mEnabling Tensor Language Model to Assist in Generating High-Performance Tensor...
15mCompiling and Compressing Structured Tensors
11mQiMeng-Xpiler: Transcompiling Tensor Programs for Deep Learning Systems with a...
22mTileLoom: Automatic Dataflow Planning for Tile-Based Languages on Spatial Dataflow Accel…
