OCL-ICD provides a free generic OpenCL implementation, should ubuntu policy be to build applications against this loader vs closed vendor implementation

Asked by Andrey Shmakov

Applications that wish to use OpenCL encounter a few problems when you attempt to distribute them.


Applications compiled against one implementation of OpenCL (libOpenCL.so) will not run on a system with another implementation installed. OpenCL loader library is supposed to be agnostic to the kernel loaded (nvidia libOpenCL.so will run amd kernels for example) but testing has shown significant performance differences when using OpenCL implementations from different vendors. System must have libOpenCL.so used at build time in order to run an application using OpenCL

As the number of OpenCL applications grows there will be packaging conflicts between those built against nvidia/ocl and potentially other vendor OpenCL implementations as they are added to ubuntu.


ocl-icd-libopencl1 (http://packages.ubuntu.com/trusty/ocl-icd-libopencl1) provides an open source implementation of libOpenCL.so that will work with vendor OpenCL kernels files provided by intel/nvidia/amd.

Policy for packages to use ocl-icd as the default implementation, allowing the use of other kernel loaders for alternative packages in the same source package(if desired)

Minor Problem:

Ubuntu does not have vendor provided OpenCL kernels for AMD/Intel in the repositories or ones compatible with cpu-only environments (fglrx should provide amd-opencl-icd, but as of trusty this is not true) - https://packages.debian.org/sid/amd-opencl-icd , can these be pushed in as trusty-updates in order to have a full and complete OpenCL system available through apt, allowing packaged distribution of OpenCL (and in turn other derivative compute libraries like Boost.Compute and ViennaCL) applications through ubuntu that can run on any supported hardware configuration.

Question information

English Edit question
Ubuntu ocl-icd Edit question
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Andrey Shmakov (akshmakov) said :

I have a working OpenCL dependency tree backported to precise (12.04( available on my PPA as well

I have tested it against vendor ICD's from intel, amd, and nvidia. Pulling those packages into a backport project to provide the previous LTS with a full and complete OpenCL implementation would be a secondary goal of mine

Revision history for this message
actionparsnip (andrew-woodhead666) said :

I suggest you report a bug

Can you help with this problem?

Provide an answer of your own, or ask Andrey Shmakov for more information if necessary.

To post a message you must log in.