AnsweredAssumed Answered

Bugs of linux APU driver?

Question asked by Biaowang on Apr 29, 2013
Latest reply on Apr 30, 2013 by Biaowang

Hi all:

I run my OpenCL code to process some videos frames, so I created a buffer up to 8M on the GPU. However, when I allocate buffer with  clCreateBuffer it report me that the  error CL_INVALID_BUFFER_SIZE, so I dig into the error, find out that only two case will lead to this error according to OpenCL Spec


CL_INVALID_BUFFER_SIZE if size is 0 or is greater than CL_DEVICE_MAX_MEM_ALLOC_SIZE value specified in table of OpenCL Device Queries for clGetDeviceInfo for all devices in context.


To check how much the CL_DEVICE_MAX_MEM_ALLOC_SIZE is I call the clGetDeviceInfo and get the value

CL_DEVICE_MAX_MEM_ALLOC_SIZE is 128*1024*1024 which is consistent to the description of CL_DEVICE_MAX_MEM_ALLOC_SIZE in OpenCL spec:



Return type: cl_ulong

Max size of memory object allocation in bytes. The minimum value is max (1/4th of CL_DEVICE_GLOBAL_MEM_SIZE, 128*1024*1024)


So my question is the size I allocated for GPU is definitely smaller than CL_DEVICE_MAX_MEM_ALLOC_SIZE and bigger than zero, why the API complain to a right size.

My GPU is integrated with CPU (A6-4455M APU), kubuntu 12.10, the latest catalyst driver for linux

the Interesting point is that I port my code to windows+MingW, then it works, so I suspect there is a bug for OpenCL linux catalyst driver