FADiff: Fusion-Aware Differentiable Optimization for DNN Scheduling on Tensor Accelerators

Shuao Jia, Zichao Ling, Chen Bai, Kang Zhao, Jianwang ZhaiarXiv 2025 · DOI

Abstract

Efficiently deploying Deep Neural Networks (DNNs) on specialized hardware like tensor accelerators presents a massive combinatorial challenge involving simultaneous decisions on intra-layer mapping and inter-layer fusion. Historically, these two domains have been optimized separately or via slow heuristic methods due to the discrete nature of fusion decisions. We present FADiff, the first optimization framework to unify these tasks into a single, fully differentiable problem. By employing mathematical relaxations such as Gumbel-Softmax reparameterization and continuous fusion variables, FADiff navigates the search space using gradient descent. Our results show that FADiff achieves up to an 18% reduction in Energy-Delay Product (EDP) and converges significantly faster than traditional search-based methods.

Introduction

The deployment of DNNs on hardware accelerators requires solving two tightly coupled problems: intra-layer mapping (tiling and scheduling data within a layer) and inter-layer fusion (deciding which layers to combine to minimize DRAM access). Traditional approaches often treat these as independent steps or rely on non-differentiable search methods like Genetic Algorithms (GA) or Bayesian Optimization (BO), which struggle with the vast design space. FADiff bridges this "Mapping-Fusion Gap" by transforming discrete scheduling decisions into a continuous, differentiable space, allowing for joint optimization of both mapping and fusion strategies.

Methodology

FADiff introduces several key innovations to enable gradient-based optimization across the mapping and fusion domains.

Continuous Relaxations

To handle discrete tiling factors, FADiff utilizes the Gumbel-Softmax reparameterization trick, allowing the model to "softly" select valid integer divisors. For fusion decisions, a continuous variable $\sigma \in [0, 1]$ is introduced, where 1 represents full on-chip reuse and 0 represents DRAM write-back. This allows the optimizer to smoothly transition between fusion strategies during the search process.

Differentiable Cost Model and Constraints

The framework incorporates an analytical model that predicts energy and latency as differentiable functions of the design variables. Hardware constraints, such as SRAM capacity and processing element counts, are enforced via quadratic penalties in the loss function. This approach ensures that the optimizer naturally gravitates toward valid hardware configurations without requiring explicit validity checks.

The FADiff framework unifies hardware architecture, workload characteristics, and design variables into a differentiable optimization engine.

Evaluation and Results

FADiff was evaluated using a variety of workloads, including Large Language Models (GPT-3) and Computer Vision models (VGG, ResNet, MobileNet), targeting the open-source Gemmini accelerator.

Optimization Performance

FADiff demonstrated significant improvements over the previous state-of-the-art gradient method, DOSA, reducing the EDP by an average of 18% on large accelerators and 13% on smaller configurations. The differentiable cost model itself proved highly accurate, achieving a 96% correlation with "gold standard" simulators like Timeloop and Accelergy.

Convergence Speed

A critical advantage of FADiff is its convergence efficiency. Compared to traditional search heuristics like GA and BO, FADiff identifies high-quality schedules one to two orders of magnitude faster. As shown in the convergence analysis, FADiff rapidly descends to a lower EDP while other methods remain trapped in local optima or require significantly more time to explore the design space.

FADiff achieves significantly lower EDP and faster convergence compared to Bayesian Optimization (BO) and Genetic Algorithms (GA).

Conclusion

FADiff represents a significant step forward in automated DNN hardware scheduling. By unifying intra-layer mapping and inter-layer fusion into a differentiable framework, it overcomes the limitations of isolated optimization and slow heuristic searches. Future work will focus on extending the framework to more complex Directed Acyclic Graph (DAG) structures and diverse NPU-style architectures.

Summary updated

BibTeX
@misc{jia2025fadiff,
  author = {Shuao Jia and Zichao Ling and Chen Bai and Kang Zhao and Jianwang Zhai},
  title = {{FADiff: Fusion-Aware Differentiable Optimization for DNN Scheduling on Tensor Accelerators}},
  year = {2025},
  eprint = {2511.22348},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2511.22348},
}
Figure