A Code Selection Mechanism Using Deep Learning

A Code Selection Mechanism Using Deep Learning
复制标题

DOI:
10.1109/mcsoc.2016.46
复制
发表时间:
2016-09
期刊:
2016 IEEE 10th International Symposium on Embedded Multicore/Many-core Systems-on-Chip (MCSOC)
影响因子:
--
通讯作者:
Hang Cui;Shoichi Hirasawa;Hiroyuki Takizawa;Hiroaki Kobayashi
Hang Cui;Shoichi Hirasawa;Hiroyuki Takizawa;Hiroaki Kobayashi
中科院分区:
其他
文献类型:
--
作者:
Hang Cui;Shoichi Hirasawa;Hiroyuki Takizawa;Hiroaki Kobayashi

文献摘要

相似文献

稀疏矩阵向量乘法(SpMV)是一种广泛应用的计算内核。SpMV有许多不同的实现,使用不同的处理器和算法。不同的SpMV实现的性能差别很大,如果不进行性能分析,基本上很难在给定的稀疏矩阵和平台上选择具有最佳性能的实现。这项工作提出了一个有效的机器学习系统的原型实现,用于最适合给定矩阵的SpMV代码选择。代替使用矩阵的预定义特征进行性能预测,使用特征图像和深度学习网络在执行之前将每个稀疏矩阵映射到具有最佳性能的实现。通过使用机器学习方法预测最佳SpMV实现来评估该机制的性能增益。根据我们的评估,所提出的机制在大多数情况下可以选择最优或次优实现,尽管预测并不完美。这些结果表明,所提出的机器学习方法可以捕获对SpMV代码选择有用的输入稀疏矩阵的潜在特征。
Sparse Matrix-Vector multiplication (SpMV) is a computational kernel widely used in many applications. There are many different implementations using different processors and algorithms for SpMV. The performances of different SpMV implementations are quite different, and it is basically difficult to choose the implementation that has the best performance for a given sparse matrix and a given platform without performance profiling. This work presents a prototype implementation of an effective machine learning system for SpMV code selection best suited for a given matrix. Instead of using predefined features of a matrix for performance prediction, a feature image and a deep learning network are used to map each sparse matrix to the implementation that has the best performance in advance of the execution. The performance gain by the mechanism is evaluated by using a machine learning method for predicting the best SpMV implementation. According to our evaluation, the proposed mechanism can select an optimal or suboptimal implementation in most cases, though the prediction is not perfect. These results demonstrate the feasibility that the proposed machine learning approach can capture underlying features of an input sparse matrix useful for SpMV code selection.