• 中国计算机学会会刊
  • 中国科技核心期刊
  • 中文核心期刊

计算机工程与科学 ›› 2023, Vol. 45 ›› Issue (05): 782-789.

• 高性能计算 • 上一篇    下一篇

基于监督学习的稀疏矩阵自动任务分配

李小玲,方建滨,马俊,谭霜,谭郁松   

  1. (国防科技大学计算机学院,湖南 长沙 410073) 
  • 收稿日期:2022-06-16 修回日期:2022-08-17 接受日期:2023-05-25 出版日期:2023-05-25 发布日期:2023-05-16
  • 基金资助:
    国家自然科学基金(61972408,U19A2060)

Automated task allocation of sparse matrix computation based on supervised learning

LI Xiao-ling,FANG Jian-bin,MA Jun,TAN Shuang,TAN Yu-song   

  1. (College of Computer Science and Technology,National University of Defense Technology,Changsha 410073,China)
  • Received:2022-06-16 Revised:2022-08-17 Accepted:2023-05-25 Online:2023-05-25 Published:2023-05-16

摘要: 针对稀疏矩阵与稠密向量乘运算探讨了不同的任务分配策略对性能的影响,观察到任务分配策略的选择会显著地影响稀疏矩阵的运算性能,且不存在一种固定的任务分配策略针对所有的稀疏矩阵都能获得最佳性能。为此,提出了一种基于机器学习的最优任务分配策略选择模型,其训练过程仅使用稀疏矩阵的特征来刻画输入数据集,且能够针对给定的数据集和目标平台自动地训练模型。实验结果表明,相对于默认的块分配方法,使用该模型选择的任务分配方式能够获得平均约35%的性能提升。

关键词: 稀疏矩阵向量乘, 任务分配, 机器学习

Abstract: In this paper, the effects of different task allocation strategies on the performance of sparse matrix and dense vector multiplication are discussed. It is observed that the selection of task allocation strategy can significantly affect the performance of sparse matrix, and there is no fixed task allocation strategy that can obtain the best performance for all sparse matrices. Therefore, this paper proposes an optimal task allocation strategy selection method based on machine learning. Its training process only uses sparse matrix features to characterize the input data set, and can automatically train the model for a given data set and target platform. Experiments show that, compared with the default block allocation method, the task allocation method selected by this model can achieve an average performance improvement of about 35%.

Key words: sparse matrix-vector multiplication, task allocation, machine learning