This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

opencl issue with Hikey970 (Mali G72)

Currently I run Ubuntu on Huawei Hikey 970 board, and try to run gnuradio with gr-fosphor on it, but failed.

At first, it failed with these lines:

[!] CL Error (-1001, /build/gr-fosphor-9QC8j4/gr-fosphor-3.7.0.2.7b6b996/lib/fosphor/cl.c:272): Unable to fetch platform IDs
[!] No suitable OpenCL device found

So I tried this driver ""mali-G71_r9p0-01rel0_linux_1fbdev.tar.gz" downloaded from https://developer.arm.com/products/software/mali-drivers/user-space

I extracted it under /opt, and compile gr-fosphor with is command:

cmake .. -DOpenCL_LIBRARY=/opt/fbdev/libOpenCL.so.1 -DOpenCL_INCLUDE_DIR=/opt/fbdev --prefix=/usr

It compiles all right. But when I try to run it, i got this error:

undefined reference to `clCreateFromGLBuffer'

So looks like this driver doesn't implemented these "clCreateFromGL*" functions? If so, is there any way to fix this? Thanks.

Parents
  • The clCreateFromGLBuffer() function is part of the cl_khr_gl_sharing extension, which the Mali OpenCL drivers do not support, so the symbol is correctly not available. Note that applications should never statically link against extension entrypoints because they cannot guarantee that they are available; typically you will need to load function pointers dynamically at runtime using clGetExtensionFunctionAddressForPlatform() if the appropriate extension is listed as supported.

    The drivers from our download portal for the Hikey 960 (Mali-G71) won't work on the Hikey 970 (Mali-G72) - it's a different GPU - so even if you resolve the symbol it will fail once you try to create a context. We don't provide Hikey 970 drivers directly, so you'd need to contact the platform manufacturer for a driver release here.

Reply
  • The clCreateFromGLBuffer() function is part of the cl_khr_gl_sharing extension, which the Mali OpenCL drivers do not support, so the symbol is correctly not available. Note that applications should never statically link against extension entrypoints because they cannot guarantee that they are available; typically you will need to load function pointers dynamically at runtime using clGetExtensionFunctionAddressForPlatform() if the appropriate extension is listed as supported.

    The drivers from our download portal for the Hikey 960 (Mali-G71) won't work on the Hikey 970 (Mali-G72) - it's a different GPU - so even if you resolve the symbol it will fail once you try to create a context. We don't provide Hikey 970 drivers directly, so you'd need to contact the platform manufacturer for a driver release here.

Children