SpArch: Efficient Architecture for Sparse Matrix Multiplication
arXiv:2002.08947 · doi:10.1109/HPCA47549.2020.00030
Abstract
Generalized Sparse Matrix-Matrix Multiplication (SpGEMM) is a ubiquitous task in various engineering and scientific applications. However, inner product based SpGENN introduces redundant input fetches for mismatched nonzero operands, while outer product based approach suffers from poor output locality due to numerous partial product matrices. Inefficiency in the reuse of either inputs or outputs data leads to extensive and expensive DRAM access. To address this problem, this paper proposes an efficient sparse matrix multiplication accelerator architecture, SpArch, which jointly optimizes the data locality for both input and output matrices. We first design a highly parallelized streaming-based merger to pipeline the multiply and merge stage of partial matrices so that partial matrices are merged on chip immediately after produced. We then propose a condensed matrix representation that reduces the number of partial matrices by three orders of magnitude and thus reduces DRAM access by 5.4x. We further develop a Huffman tree scheduler to improve the scalability of the merger for larger sparse matrices, which reduces the DRAM access by another 1.8x. We also resolve the increased input matrix read induced by the new representation using a row prefetcher with near-optimal buffer replacement policy, further reducing the DRAM access by 1.5x. Evaluated on 20 benchmarks, SpArch reduces the total DRAM access by 2.8x over previous state-of-the-art. On average, SpArch achieves 4x, 19x, 18x, 17x, 1285x speedup and 6x, 164x, 435x, 307x, 62x energy savings over OuterSPACE, MKL, cuSPARSE, CUSP, and ARM Armadillo, respectively.
The first two authors have equal contributions; 15 pages, 18 figures; Published as a conference paper in HPCA 2020
Cited by in corpus (26)
- SpAtten: Efficient Sparse Attention Architecture with Cascade Token and Head Pruning
- GCN-RL Circuit Designer: Transferable Transistor Sizing with Graph Neural Networks and Reinforcement Learning
- HAT: Hardware-Aware Transformers for Efficient Natural Language Processing
- QuantumNAS: Noise-Adaptive Search for Robust Quantum Circuits
- A Systematic Survey of General Sparse Matrix-Matrix Multiplication
- The Sparse Abstract Machine
- Capstan: A Vector RDA for Sparsity
- HighLight: Efficient and Flexible DNN Acceleration with Hierarchical Structured Sparsity
- First-Generation Inference Accelerator Deployment at Facebook
- Keep the Gradients Flowing: Using Gradient Flow to Study Sparse Network Optimization
- Oaken: Fast and Efficient LLM Serving with Online-Offline Hybrid KV Cache Quantization
- Copernicus: Characterizing the Performance Implications of Compression Formats Used in Sparse Workloads
- Tailors: Accelerating Sparse Tensor Algebra by Overbooking Buffer Capacity
- Secure and Efficient General Matrix Multiplication On Cloud Using Homomorphic Encryption
- Sparse Systolic Tensor Array for Efficient CNN Hardware Acceleration
- SMASH: Sparse Matrix Atomic Scratchpad Hashing
- Scalable-Complexity Steered Response Power Mapping based on Low-Rank and Sparse Interpolation
- Dual-side Sparse Tensor Core
- SAGE: A Storage-Based Approach for Scalable and Efficient Sparse Generalized Matrix-Matrix Multiplication
- Non-Blocking Simultaneous Multithreading: Embracing the Resiliency of Deep Neural Networks
- Phantom: A High-Performance Computational Core for Sparse Convolutional Neural Networks
- SPOTS: An Accelerator for Sparse Convolutional Networks Leveraging Systolic General Matrix-Matrix Multiplication
- Extending Sparse Tensor Accelerators to Support Multiple Compression Formats
- GPTPU: Accelerating Applications using Edge Tensor Processing Units
- MicroNet for Efficient Language Modeling
- Accelerating PageRank Algorithmic Tasks with a new Programmable Hardware Architecture