Launch-time Optimization of OpenCL Kernels
University of Toronto
University of Toronto, 2017
@phdthesis{lee2017launch,
title={Launch-time Optimization of OpenCL Kernels},
author={Lee, Andrew Siu Doug},
year={2017}
}
OpenCL kernels are compiled first before kernel arguments and launch geometry are provided later at launch time. Although some of these values remain constant during execution, the compiler is unable to optimize for them since it has no access to them. We propose and implement a novel approach that identifies such arguments, geometry, and optimizations at compile time using a series of annotations. At launch time the annotations, combined with the actual values of the arguments and geometry, are processed and used to optimize the code, thereby improving kernel performance. We measure the execution times of 16 benchmarks our approach. The results show that annotation processing is fast and that kernel performance is improved by a factor of up to 2.06X and on average by 1.22X. When considering the entire compilation flow, improvement can be up to 1.13X, but can also potentiality degrade to 0.44X, depending on the launch scenario.
November 16, 2017 by hgpu