AscSpMM: Efficient SpMM on Ascend NPUs via Pipelined Vector-Cube Collaboration
Fei Li, Haoxin Li, Kehong Liu, Yanzi Zhou, Weiguo Wu, Shiqiang Nie, Jinyu Wang, Song Liu
Abstract
Neural processing units (NPUs) provide high compute density and energy efficiency through specialized matrix engines and software-managed on-chip memory. However, their libraries primarily target dense computation. Sparse matrix-dense matrix multiplication (SpMM), a key kernel in graph analytics, sparse neural networks, and scientific computing, requires index-driven operand selection, indirect addressing, scattered memory accesses, and load balancing. These requirements conflict with the fixed shapes and contiguous layouts preferred by NPU matrix engines. GPU Tensor Core SpMM methods cannot be directly transferred to NPUs with decoupled vector and matrix engines. We present AscSpMM, which separates irregular operand preparation from regular matrix computation through a parameterized Vector-CSR representation. The vector engine decodes indices and gathers and reorganizes dense operands, while the Cube engine performs matrix multiply-accumulate operations. A double-slot ring buffer enables dependency-aware asynchronous pipelining, while operand reuse and runtime-adaptive tiling reduce cross-engine stalls. On an Ascend 910B3, AscSpMM achieves geometric-mean speedups of 2.36x over GEMM, 19.92x over an existing SpMM implementation, and 5.82x over cuSPARSE on an A100. It reduces matrix-input storage and peak HBM footprint by 48.24% and 22.98% on average, while remaining competitive with specialized GPU Tensor Core SpMM kernels. The code is available at https://github.com/LfLab-AI/Ascend-NPU-SpMM.
Create a lesson
Metadata
- Comments
- 13 pages, 11 figures
Related papers
ExitLUT: Boolean Early Exits for Efficient FPGA-Based Neural Network Inference
Shared title terminologycs.AROliver Cassidy, Marta Andronic, George A. Constantinides
EdgeALM: An Efficient and Unified Edge Accelerator for Large Audio Language Models via Full-Stack Hardware-Software Co-Design and Agent-Driven Recursive Optimization
Shared title terminologycs.ARChenglin Yang, Feifan Xu, Xingyuan Li et al.
Resource-Aware VLA-MPC Co-Location for Efficient Embodied AI
Shared title terminologycs.ARZeyu Guo, Hao Lou, Yuhui Hao et al.
Synapse: An HBM-Coordinated HBF Near-Memory Computing Architecture for Pipelined Agentic AI Execution
Shared title terminologycs.ARJuhyeong Jin, Hyunjun Cho, Joo-Young Kim
LLM-Assisted Verilog Code Refinement for Efficient RTL Clock Gating
Shared title terminologycs.ARGeuna Chang, Seohyun Kim, Youngsoo Shin
Motivo: A Motif-Based Algorithm-Architecture Co-Design for Fast and Energy-Efficient Graph-Based Genome Analysis
Shared title terminologycs.AREirini Maria Tzermpou, Konstantina Koliogeorgi, Konstantinos Kanellopoulos et al.