arrow
Return

Optimizing General Sparse Matrix-Matrix Multiplication on the GPU

delete2025-12-01
delete0
PRE
AI
王
王一拙 (Yizhuo Wang) *
H
H. Lin
B
Bingxin Wei
J
Jianhua Gao
W
Weixing Ji
DOI:10.1145/3774654delete
deleteOriginal
deleteOriginal request for help
deleteShare
deleteSave
Abstract

Abstract

En 中文
General Sparse Matrix-Matrix Multiplication (SpGEMM) is a crucial computational kernel in the field of scientific and engineering computing. Due to the irregular distribution of nonzero elements in sparse matrices, SpGEMM computation faces challenges such as non-contiguous memory access and workload imbalance. This article focuses on optimizing SpGEMM for GPU platforms. First, a lightweight machine learning model is trained to predict the optimal method for estimating the size of result matrix. Next, different kernels are launched in groups to maximize GPU shared memory utilization and achieve load balancing. For the hash-based sparse accumulator, heuristic methods are used to select the optimal hash load factors and hash multiplier factors, thereby reducing the number of hash collisions. In addition, thread reduction is applied in the symbolic phase to enhance intra-block parallelism. Combining these optimization strategies, we implemented an adaptive SpGEMM algorithm for GPUs and compared its performance with current state-of-the-art algorithms. The results show that our algorithm achieves significant performance improvements.
Keywords:
Sparse matrix multiplication
GPU
parallel computing
SpGEMM

Journal

A
ACM Transactions on Architecture and Code Optimization
IF:
1.8
Papers:
96
Citations:
1.1K

Organization

B
Beijing Normal University
Scholars:
3.3W
Papers: 2.7W
Citations: 4.2W
B
Beijing Institute of Technology
Scholars:
5.2K
Papers: 2.1K
Citations: 6.0W
Cited Papers

Cited Papers

errShare
errSave
spECK
err2020-02-19
err0
PREAI
errMathias Parger; Martin Winter; Daniel Mlakar; Markus Steinberger
errShare
errSave
OpSparse: A Highly Optimized Framework for Sparse General Matrix Multiplication on GPUs
err2022-01-01
err3
errOAAI
errDu, Zhaoyang; Guan, Yijin; Guan, Tianchan; Niu, Dimin; Huang, Linyong; Zheng, Hongzhong; Xie, Yuan
errShare
errSave
A Systematic Survey of General Sparse Matrix-matrix Multiplication
err2023-03-02
err13
errOAAI
errGao, Jianhua; Ji, Weixing; Chang, Fangli; Han, Shiyu; Wei, Bingxin; Liu, Zeming; Wang, Yizhuo
errShare
errSave
An Open-Source Tool for Classification Models in Resource-Constrained Hardware
err2022-01-01
err4
errOAAI
errda Silva, Lucas Tsutsui; Souza, Vinicius M. A.; Batista, Gustavo E. A. P. A.; TsutsuidaSilva, Lucas
errShare
errSave
researcher View more