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

Computer Engineering & Science

Previous Articles     Next Articles

A BLAS library optimization method
based on genetic algorithm

SUN Cheng-guo1,LAN Jing2,JIANG Hao1   

  1. (1.College of Computer,National University of Defense Technology,Changsha 410073;
    2.Rongzhi College,Chongqing Technology and Business University,Chongqing 404100,China)
  • Received:2017-11-23 Revised:2018-02-23 Online:2018-05-25 Published:2018-05-25

Abstract:

Based on OpenBLAS and BLIS,  the two open source linear algebra libraries, the performance optimization of dense matrix multiplication (GEMM) operation is studied. Aiming at how to select the key block parameters of GEMM, a performance optimization model is established. An improved genetic algorithm is used to solve the above performance optimization model. The performance value of the GEMM corresponding to a certain parameter combination (individual) is taken as the fitness of the individual. The optimal combination of block parameters is found through continuous iterative selection, crossover and mutation operations in order to make the performance of GEMM optimal. Numerical experiments show that the performance of GEMM based on genetic algorithm is better than the performance under the initial block parameters, and hence the optimization is achieved.
 

Key words: BLAS, GEMM, genetic algorithm, autotuning