OpenCL Coming Soon?

I’m trying to build PG_Strom, which is a Cuda plugin for Postgres, but it requires OpenCL to compile. Is there a timeframe for OpenCL on the Jetson?


I’m also interested. I’d like to try and get running.

I am also needing OpenCL support in order to actually use this for finished products. My group is standardizing on OpenCL and we will require a special exception and need to use CUDA.

Is there any info on this? How to we let Nvidia know we need this support? Thanks

If you have installed properly the cuda drivers you can find the OpenCL library in /usr/lib/arm-linux-gnueabihf

ubuntu@tegra-ubuntu:/usr/lib/arm-linux-gnueabihf$ ls -la libOpenCL*
lrwxrwxrwx 1 root root    18 Mar 15 18:04 ->
lrwxrwxrwx 1 root root    18 Mar 15 18:04 ->
-rw-r--r-- 1 root root 22120 Mar 15 18:04

I’m trying to use it. I will update you.


My first try to use OpenCL was very disappointing. I installed the DeviceQuery Sample, tried to compile it, received an " -m32" Error, removed the according lines from the makefiles, got a compile finally, but the devicequery returned an error while trying to handle an error oO

/Desktop/SDK2/OpenCL/bin/linux/release$ ./oclDeviceQuery
[oclDeviceQuery] starting…

./oclDeviceQuery Starting…

OpenCL SW Info:

Error -1001 in clGetPlatformIDs Call !!!

!!! Error # -1000 (Unspecified Error) at line 46 , in file oclDeviceQuery.cpp !!!


i most certainly overdid it by gambling with the makefiles in that way, i just want to let you know ;)

Keeping on hacking to understand the OpenCl implementation in the Jetson I read the list of symbols from /usr/lib/arm-linux-gnueabihf/

It seems to be OpenCL 1.2, as mentioned in the specs:

ubuntu@tegra-ubuntu:/usr/lib/arm-linux-gnueabihf$ nm -D 
00003050 T clBuildProgram
000034cc T clCompileProgram
00003664 T clCreateBuffer
00003644 T clCreateCommandQueue
00002c58 T clCreateContext
00002d38 T clCreateContextFromType
00003920 T clCreateEventFromGLsyncKHR
00003840 T clCreateFromGLBuffer
000038bc T clCreateFromGLRenderbuffer
000039c4 T clCreateFromGLTexture
00003864 T clCreateFromGLTexture2D
00003890 T clCreateFromGLTexture3D
0000393c T clCreateImage
0000368c T clCreateImage2D
000036c8 T clCreateImage3D
0000377c T clCreateKernel
00003098 T clCreateKernelsInProgram
00003754 T clCreateProgramWithBinary
00003968 T clCreateProgramWithBuiltInKernels
00003734 T clCreateProgramWithSource
00003714 T clCreateSampler
000038e0 T clCreateSubBuffer
00003494 T clCreateSubDevices
0000345c T clCreateSubDevicesEXT
00003908 T clCreateUserEvent
00003364 T clEnqueueAcquireGLObjects
0000332c T clEnqueueBarrier
00003570 T clEnqueueBarrierWithWaitList
000031c8 T clEnqueueCopyBuffer
00003434 T clEnqueueCopyBufferRect
00003278 T clEnqueueCopyBufferToImage
00003238 T clEnqueueCopyImage
00003258 T clEnqueueCopyImageToBuffer
00003504 T clEnqueueFillBuffer
00003524 T clEnqueueFillImage
00003798 T clEnqueueMapBuffer
000037e4 T clEnqueueMapImage
0000330c T clEnqueueMarker
00003558 T clEnqueueMarkerWithWaitList
00003540 T clEnqueueMigrateMemObjects
000032e8 T clEnqueueNativeKernel
000032b0 T clEnqueueNDRangeKernel
00003188 T clEnqueueReadBuffer
000033cc T clEnqueueReadBufferRect
000031e8 T clEnqueueReadImage
0000337c T clEnqueueReleaseGLObjects
000032d0 T clEnqueueTask
00003298 T clEnqueueUnmapMemObject
0000331c T clEnqueueWaitForEvents
000031a8 T clEnqueueWriteBuffer
00003400 T clEnqueueWriteBufferRect
00003210 T clEnqueueWriteImage
00003178 T clFinish
00003168 T clFlush
00002f68 T clGetCommandQueueInfo
00002f30 T clGetContextInfo
000035bc T clGetDeviceIDs
00002ef8 T clGetDeviceInfo
00003118 T clGetEventInfo
00003150 T clGetEventProfilingInfo
00002af0 T clGetExtensionFunctionAddress
00003618 T clGetExtensionFunctionAddressForPlatform
00002e34 T clGetGLContextInfoKHR
0000333c T clGetGLObjectInfo
0000334c T clGetGLTextureInfo
00002fe0 T clGetImageInfo
000034ec T clGetKernelArgInfo
000030e8 T clGetKernelInfo
00003100 T clGetKernelWorkGroupInfo
00002fc8 T clGetMemObjectInfo
00002bd4 T clGetPlatformIDs
00003588 T clGetPlatformInfo
00003080 T clGetProgramBuildInfo
00003068 T clGetProgramInfo
00003018 T clGetSamplerInfo
00002fb4 T clGetSupportedImageFormats
0000398c T clLinkProgram
00002f58 T clReleaseCommandQueue
00002f20 T clReleaseContext
000034bc T clReleaseDevice
00003484 T clReleaseDeviceEXT
00003140 T clReleaseEvent
000030c0 T clReleaseKernel
00002fa4 T clReleaseMemObject
00003040 T clReleaseProgram
00003008 T clReleaseSampler
00002f48 T clRetainCommandQueue
00002f10 T clRetainContext
000034ac T clRetainDevice
00003474 T clRetainDeviceEXT
00003130 T clRetainEvent
000030b0 T clRetainKernel
00002f94 T clRetainMemObject
00003030 T clRetainProgram
00002ff8 T clRetainSampler
00002f80 T clSetCommandQueueProperty
00003394 T clSetEventCallback
000030d0 T clSetKernelArg
000033ac T clSetMemObjectDestructorCallback
000033bc T clSetUserEventStatus
00002ef4 T clUnloadCompiler
000035f4 T clUnloadPlatformCompiler
00002ed4 T clWaitForEvents
         w __cxa_finalize
         U dlclose
         U dlopen
         U dlsym
         U fclose
         U fgets
         U fopen
         U free
         U fseek
         U ftell
         U getenv
         w __gmon_start__
         w _ITM_deregisterTMCloneTable
         w _ITM_registerTMCloneTable
         w _Jv_RegisterClasses
         U malloc
         U memcpy
00000000 A OPENCL_1.0
00000000 A OPENCL_1.1
00000000 A OPENCL_1.2
         U opendir
         U readdir
         U realloc
         U rewinddir
         U __sprintf_chk
         U __stack_chk_fail
         U __stack_chk_guard
         U strchr
         U strcmp
         U strcpy
         U strlen
         U strstr
         U strtol
         U __tls_get_addr
         U __xstat

HellMood: same error on clGetPlatformIDs using this simple example

and the header file of the OpenCL 1.2 implementation by kronos (I have put them in /usr/include/CL)…

The symbol of the function is in the list above (number 72).

Any idea?

I would also like to see OpenCL support. On my board I don’t even have

ls /usr/lib/arm-linux-gnueabihf/
ls: cannot access /usr/lib/arm-linux-gnueabihf/ No such file or directory

If somebody could tell me where to look for it I might be able to dig a bit further whether there is some way to enable it.

Have you installed the nvidia driver pack using /home/ubuntu/NVIDIA-INSTALLER/

Yes. It does not install the openCL libraries.




For me, even the most recent version of the NVidia installer (Tegra124_Linux_R19.3.0_armhf.tar) does not add or include the OpenCL libraries or headers. However, even after I obtained them from elsewhere, I still received the clGetPlatformIDs -1001 error. From what I can see, this error is caused by the lack of an NVidia ICD for the Jetson. I haven’t been able to find one, and the only reasonable place that I would have expected to find it is in the installer I mentioned before.

Do any of you have the nvidia.icd or even the set of directories /etc/OpenCL/…?

Same error:

clGetPlatformIDs -1001

I tried, without succees, to set /etc/OpenCL/nvidia.icd pointing to or libcuda.

No way. It doesn’t work. :/

I’m reasonably sure that it’s just completely unsupported at this point. If you look in the comments of this article, an NVidia employee outright states that OpenCL is unsupported, despite the promises that it would be:

…despite it exist a! :/

If you strace your program you’ll see it’s looking for /etc/OpenCL/vendors/nvidia.icd.

I tried putting some in there too but I think is the ICD, not the actual NVidia supplied OpenCL interface to their driver.

I think it showed up after I installed:
$ sudo apt-get install ocl-icd-libopencl1

Does anyone know if this time Jetson K1 supports OpenCL?


Afaik, there are no updates related to OpenCL support on Jetson TK1.

EDIT: Please don’t post same question to multiple threads.