Working on an Object-Oriented C++ library and I want to take advantage of my Intel Graphics GPU. I tried to learn some OpenCL only to find out it doesn't support C++ O.O programming style and classes. Any suggestions of libraries or frameworks that could make it easier to tap into the GPU would be really helpful.
Many thanks, Amine
-
Which kind of operations do you want to accelerate? Image Processing, Neural Networks, Data Structures?Sebastian– Sebastian2020年10月12日 19:50:01 +00:00Commented Oct 12, 2020 at 19:50
-
@Sebastian so far only data structures in C++, such as the ones in the STL.Amine– Amine2020年10月12日 19:56:05 +00:00Commented Oct 12, 2020 at 19:56
-
Then probably you should look into libraries like Thrust: thrust.github.ioSebastian– Sebastian2020年10月14日 02:15:38 +00:00Commented Oct 14, 2020 at 2:15
1 Answer 1
Yes, OpenCL (and CUDA) are specialized programming languages, because GPGPUs are very specialized heterogeneous computing devices.
You might perhaps be interested in semi-automatic translation of some subset of C code (or Fortran) to these, but there is No Silver Bullet. Either use a library (e.g. TensorFlow) ported to GPGPUs or accept the idea of difficult development efforts specific to your GPGPU hardware.
Look into OpenACC, TransPyle, Numba, VEXCL, etc.
Read also this about SYCL.