Nova: An End-to-End MLIR Compiler for Deep Learning
Nova is an automated end-to-end JIT compiler built on MLIR that captures eager executions and unifies forward/backward passes into a single value-semantic dialect for aggressive whole-graph optimization An Analytic Configurator derives optimal execution schedules deterministically based on arithmetic intensity, eliminating search time entirely A structural hashing runtime enables fine-grained kernel synthesis directly from computation structure, achieving up to 29% memory reduction versus PyTorc
Analysis
TL;DR
- Nova is an automated end-to-end JIT compiler built on MLIR that captures eager executions and unifies forward/backward passes into a single value-semantic dialect for aggressive whole-graph optimization
- An Analytic Configurator derives optimal execution schedules deterministically based on arithmetic intensity, eliminating search time entirely
- A structural hashing runtime enables fine-grained kernel synthesis directly from computation structure, achieving up to 29% memory reduction versus PyTorch
- On an RTX 3060, Nova matches or exceeds cuBLAS and XLA on TF32 matmuls with < 5e-4 relative error, and delivers up to 10.6% greater throughput than PyTorch and 4.4% greater than XLA on a 42M-parameter model
- Nova successfully trains a 144M-parameter model at 17,900 tokens/s on a 12 GB consumer GPU where PyTorch fails with OOM errors
Why It Matters
Nova addresses a critical bottleneck in deep learning: the gap between high-level framework abstractions and low-level hardware utilization. By providing whole-graph visibility and deterministic optimization without search overhead, it offers a practical path for practitioners to extract maximum performance from consumer-grade hardware, potentially democratizing access to efficient model training.
Technical Details
- Nova captures eager PyTorch-style executions and compiles them into a unified value-semantic MLIR dialect that encompasses both forward and backward passes, enabling cross-boundary operation fusion and memory hierarchy optimization
- The Analytic Configurator uses arithmetic intensity as a sole decision metric to deterministically derive optimal execution schedules, reducing compilation/search time to zero compared to traditional auto-tuning approaches
- A structural hashing runtime maps computation structures to synthesized fine-grained kernels, providing granular control over hardware mapping from operation fusion down to register-level tuning
- Evaluated on an RTX 3060 (12 GB VRAM), Nova was benchmarked against cuBLAS, XLA, and PyTorch on TF32 matmuls across various shapes, maintaining numerical fidelity with relative error below 5e-4
- At the model level, Nova achieved up to 10.6% throughput improvement over PyTorch and 4.4% over XLA on a 42M-parameter model, while reducing memory footprint by up to 29% relative to PyTorch
Industry Insight
- The deterministic Analytic Configurator approach challenges the prevailing auto-tuning paradigm, suggesting that arithmetic-intensity-based scheduling could eliminate compilation latency—a significant advantage for iterative development workflows and dynamic model architectures
- Nova's ability to train larger models on consumer hardware (144M params on 12 GB vs. PyTorch OOM) demonstrates that compiler-level memory optimization can materially extend the viability of affordable GPUs for research and production, reducing dependency on datacenter-class hardware
- The integration of forward/backward unification within a single MLIR dialect represents a compelling architectural pattern for future compilers, particularly as memory efficiency becomes increasingly critical with growing model sizes and the rise of on-device AI inference
Disclaimer: The above content is generated by AI and is for reference only.