What is the difference between POCL(Portable Computing Language) and OpenCL?

3.7k views Asked by At

What is the difference between POCL(Portable Computing Language) and OpenCL, and what are the advantages POCL? http://pocl.sourceforge.net/

Does POCL have a C-like language, which is different from OpenCL, a different compiler (Clang> = 3.2), different backend (llvm), better portability, or something else?

And when we need to use the (hard-linking) OCL, and when need to use the ICD? http://streamcomputing.eu/blog/2013-07-08/installing-and-using-pocl/

2

There are 2 answers

0
Krishnaraj On BEST ANSWER

Pocl is like any other opencl platform. It provides a opencl cpu device on x86/arm and many more systems. It is almost compliant to opencl 1.2 standards, except it doesn't have stuffs like cl_gl sharing etc. It uses clang/llvm to utilize all cpu cores and vector units in the cpu.

opencl is a spec and pocl implements this spec to give you a platform with cpu devices

coming to ICD, you link against ICD when you have more than one opencl platforms installed. Compile this icd code from khronos http://www.khronos.org/registry/cl/specs/opencl-icd-1.2.11.0.tgz and you will have an icd loader which can load any opencl platform. Hardlinking to a platform ".so" is possible say libpocl.so, but other installed platforms will not be visible in clGetPlatformIDs call. So ICD is better

2
Dithermaster On

OpenCL is a specification maintained by Khronos. There are many implementations, from vendors like AMD, NVIDIA, Intel, and Apple. In order to call itself an implementation of OpenCL a vendor must pass the conformance tests, be a member of Khronos, and probably some other things.

POCL (Portable Computing Language, formerly Portable OpenCL) is an open-source implementation of something very much like OpenCL but it is a work in progress and hasn't passed conformance tests so it's not really an implementation of OpenCL just yet. I gather they they aim to be one in the future, and wish them luck.

So there is your difference: one is a specification, the other aims to be an implementation of that specification.

I presume that POCL uses the same C99-based language for kernels, if they aim to be OpenCL compatible.

More on POCL at: http://pocl.sourceforge.net/