2

When program is run on GPGPU, how would it's execution differ if implemented with OpenMP vs OpenCL?

Does OpenMP utilizes GPGPUs through OpenCL? If not, what's the common GPGPU API for them I can use directly (without any OpenMP/OpenCL built on top of it)?

P.S. On Linux, OpenMP uses just pthread to manage threads. I couldn't find any other API to GPGPU besides OpenCL and CUDA, so it is obviously (but pretty painful) to admit that OpenMP, when it comes to GPGPU, utilizes OpenCL (or CUDA if GPGPU is by NVIDIA and OpenMP is that smart).

Slaus
  • 2,086
  • 4
  • 26
  • 41
  • The OpenMP compiler and runtime vendor decides how to implement the GPGPU offloading. Technologies and implementation APIs vary. – Hristo Iliev Mar 06 '16 at 20:40
  • @HristoIliev Thank you for your comment. The GPGPU development cycle understanding is messed up for me now: as I know, OpenCL exposes standards, which GPGPU developers (and Xeon Phi) should follow to be called _OpenCL compatible_. They're all called like that today, so it's possible to assume that such hardware developed towards OpenCL architecture. Fine, BUT! We have OpenMP present which also offers GPGPU interface differ from OpenCL. So, OpenMP utilizes GPGPUs through OpenCL, or there are two GPGPU development standards, which is very unlikely. – Slaus Mar 07 '16 at 05:08

1 Answers1

-1

As far as I concern, OpenMP is a set of compilers directives to provide a parallelism on shared memory architectures and GPGPU is in generally NOT such one. You can use them both together in order to archive better performance or you can use OpenACC, OpenHMPP or C++ AMP, which can quasi substitute them or you can use such libraries as AMD Bolt or ArrayFire - they can allow you to utilize GPGPU without lot of efforts.

Vlad
  • 39
  • 5