期刊文献+

基于多面体模型的矩阵乘法向量代码生成 被引量:2

Matrix Multiplication Vector Code Generation Based on Polyhedron Model
下载PDF
导出
摘要 矩阵乘法是众多科学计算的核心,而向量化编程是提升其性能的主要手段之一。针对现有的向量化优化往往存在需要手工进行调优以及与硬件结构映射的问题,基于多面体编译器PPCG,在多面体模型中引入向量代码生成框架,提出了基于多面体模型的矩阵乘法向量代码生成框架。通过对矩阵乘法的向量化方案进行收益分析来确定向量化方案,指导应用框架的代码生成,基于该代码生成框架,有利于矩阵乘法的向量化快速优化。选取13个规模在64×64×64到1 024×1 024×1 024之间的矩阵乘法用例进行实验,结果表明,该框架能够正确生成向量化代码,与基础编译器ICC的自动向量化功能相比,应用该框架生成的向量化代码最高获得了5.09倍的加速和3.39倍的平均加速。 Matrix multiplication is the core of many scientific calculations, and vectorized programming is one of the main means to improve its performance.In view of the existing vectorization optimization problems that often require manual tuning and need to be mapped to the hardware structure, based on the polyhedron compiler PPCG,a vector code generation framework is introduced into the polyhedron model, and a matrix multiplication vector code generation framework based on the polyhedron model is proposed.Through the profit analysis of the matrix multiplication vectorization program, the vectorization program is determined, and the code generation of the application framework is guided.Based on this framework, it is conducive to the rapid optimization of vectorization of matrix multiplication.Selecting 13 matrix multiplication cases with a scale between 64×64×64 and 1 024×1 024×1 024 for experiments.The results show that the framework can generate vectorized code correctly.Compared with the automatic vectorization of the basic compiler ICC,the vectorized code generated by the framework has a speedup of 5.09 times and an average speedup of 3.39 times.
作者 王博漾 庞建民 徐金龙 赵捷 陶小涵 朱雨 WANG Bo-yang;PANG Jian-min;XU Jin-long;ZHAO Jie;TAO Xiao-han;ZHU Yu(School of Cyber Science and Engineering,Zhengzhou University,Zhengzhou 450000,China;State Key Laboratory of Mathematical Engineering and Advanced Computing,PLA Information Engineering University,Zhengzhou 450000,China)
出处 《计算机科学》 CSCD 北大核心 2022年第10期44-51,共8页 Computer Science
基金 国家自然科学基金区域创新发展联合基金(U20A20226)。
关键词 矩阵乘法 多面体模型 向量化 调度变换 代码生成 Matrix multiplication Polyhedron model Vectorized Scheduling transformation Code generation
  • 相关文献

参考文献4

二级参考文献11

共引文献48

同被引文献21

引证文献2

相关作者

内容加载中请稍等...

相关机构

内容加载中请稍等...

相关主题

内容加载中请稍等...

浏览历史

内容加载中请稍等...
;
使用帮助 返回顶部