首页 | 官方网站   微博 | 高级检索  
     

结合模型和迭代编译优化矩阵相乘程序
引用本文:陆平静,王正华,车永刚.结合模型和迭代编译优化矩阵相乘程序[J].计算机工程与科学,2009,31(Z1).
作者姓名:陆平静  王正华  车永刚
作者单位:国防科技大学计算机学院,湖南,长沙,410073
基金项目:国家自然科学基金资助项目,国家863计划资助项目,国家973计划资助项目 
摘    要:高性能计算应用程序获得的持续性能与机器峰值性能的差距日益扩大,很大程度上制约着高性能计算的发展。程序变换通过对程序进行适应机器体系结构特征的优化变换,提高程序实际执行性能,是解决该问题的有效途径之一。很多高级程序变换均具有数值参数,为了获得最优性能,需要仔细选择参数的值。传统的编译器使用简单的模型选择这些参数,难以适应日趋复杂的硬件平台和应用程序。迭代编译通过生成不同的程序版本并在实际硬件评估上运行程序,来评估关键优化参数的值并决定能够产生最优性能的值,显著优于静态方法,但巨大的优化开销限制了其应用范围。本文针对矩阵相乘程序提出一种结合性能模型和迭代编译的优化方法,利用基于对机器体系结构和程序的经验知识构造性能模型约束优化空间,并使用遗传算法加速在优化空间中寻找优秀解的过程。实验结果表明,该方法可以较低的开销获得更优的性能优化效果。

关 键 词:程序变换  迭代编译  遗传算法

Using Model and Iterative Compilation to Optimize Matrix Multiplication Applications
LU Ping-jing,WANG Zheng-hua,CHE Yong-gang.Using Model and Iterative Compilation to Optimize Matrix Multiplication Applications[J].Computer Engineering & Science,2009,31(Z1).
Authors:LU Ping-jing  WANG Zheng-hua  CHE Yong-gang
Abstract:The performance gap for high performance applications has been widening over time. High level program transformations are critical to improve the applications' performance, many of which concern the determination of optimal values for transformation parameters. Traditional compilers select these parameters based on static analytical models. However, complex computer architectures and code behaviors greatly limit the strength of optimizing compilers. Iterative compilation approach determines these parameter values by executing the program with different parameter values and selects the one with the shortest runtime, outperforming static approaches significantly. But it's quite time consuming because of the huge optimization space. Aiming at matrix multiplication program, this paper presents a combinative method to solve this problem by investigating a constraint model on optimization parameters to limit the optimization space, and then applying genetic algorithms to search the optimal parameters. Experimental results indicate our approach can produce parameter values with better performance and lower cost.
Keywords:program transformation  iterative compilation  genetic algorithms
本文献已被 万方数据 等数据库收录!
设为首页 | 免责声明 | 关于勤云 | 加入收藏

Copyright©北京勤云科技发展有限公司    京ICP备09084417号-23

京公网安备 11010802026262号