2

I am running open cl on a linux machine with ARM processor and Mali GPU remotely. But it is giving an error something like "Unknown error: cannot retrieve platform id" at clGetPlatformIDs().

I tried both

cl_uint numPlatforms;   //the NO. of platforms
cl_platform_id platform = NULL; //the chosen platform
cl_int  status = clGetPlatformIDs(0, NULL, &numPlatforms);

and

cl_int  status = clGetPlatformIDs(1, &platform, &numPlatforms);

but for both, I am getting the same error. The same code is working for me on my personal windows laptop with AMD graphics.

What could be the reason for this error?

User1234321232
  • 517
  • 10
  • 25

2 Answers2

0

Reason can be simple - OpenCL driver isn't working well. That's why you can't load platforms list. Did you test that ARM machine with OpenCL code before?

Roman Arzumanyan
  • 1,784
  • 10
  • 10
0

By arm linux machine you mean arm chromebook? libOpenCL.so in your machine is only a stub driver. Actual platform implementations are listed in /etc/OpenCL/vendors. You could also have libOpenCL.so without icd support exposing only 1 platform

In any case if its samsung arm chromebook, arm has a detailed setup guide for mali opencl & opengl-es http://malideveloper.arm.com/develop-for-mali/features/graphics-and-compute-development-on-samsung-chromebook/

Krishnaraj
  • 421
  • 1
  • 3
  • 10