Programming CUDA and OpenCL: A Case Study Using Modern C++ Libraries

Denis Demidov, Karsten Ahnert, Karl Rupp, Peter Gottschling
Kazan Branch of Joint Supercomputer Center, Russian Academy of Sciences, Lobachevsky st. 2/31, 420111 Kazan, Russia
arXiv:1212.6326 [cs.MS], (27 Dec 2012)


   author={Demidov}, D. and {Ahnert}, K. and {Rupp}, K. and {Gottschling}, P.},

   title={"{Programming CUDA and OpenCL: A Case Study Using Modern C++ Libraries}"},

   journal={ArXiv e-prints},




   keywords={Computer Science – Mathematical Software, Computer Science – Distributed, Parallel, and Cluster Computing, Physics – Computational Physics},




   adsnote={Provided by the SAO/NASA Astrophysics Data System}


We present a comparison of several modern C++ libraries providing high-level interfaces for programming multi- and many-core architectures on top of CUDA or OpenCL. The comparison focuses on the solution of ordinary differential equations and is based on odeint, a framework for the solution of systems of ordinary differential equations. Odeint is designed in a very flexible way and may be easily adapted for effective use of libraries such as Thrust, MTL4, VexCL, or ViennaCL, using CUDA or OpenCL technologies. We found that CUDA and OpenCL work equally well for problems of large sizes, while OpenCL has higher overhead for smaller problems. Furthermore, we show that modern high-level libraries allow to effectively use the computational resources of many-core GPUs or multi-core CPUs without much knowledge of the underlying technologies.
Rating: 2.5. From 1 vote.
Please wait...

* * *

* * *

HGPU group © 2010-2017 hgpu.org

All rights belong to the respective authors

Contact us: