I have a weird behavior in my code.
I need to allocate very large amount of memory (splitted in many buffers (aroud 20)) and the alloc failed.
First strange thing: when alloc failed, i am able to see it and to get a wrong return code only on the first kernel (which returns CL_OUT_OF_RESSOURCES) code not at allocation with an (CL_OUT_OF_MEMORY)
Second strange thing: the amount of allocated memory whiche makes my cde to crash is far under the card’s limitation.
I test it on a Tesla C1060 with CL_DRIVER_VERSION=256.35 / CL_DEVICE_GLOBAL_MEM_SIZE=4294770688 / CL_DEVICE_MAX_MEM_ALLOC_SIZE=1073692672 and everything is fine (i succeed in allocate my 2.6 Go of memory)
On a GeForce GTX 480 with CL_DRIVER_VERSION = 256.44 / CL_DEVICE_GLOBAL_MEM_SIZE=1610285056 / CL_DEVICE_MAX_MEM_ALLOC_SIZE=402571264 , i crash whith a total amount of memory allocated close to the CL_DEVICE_MAX_MEM_ALLOC_SIZE’s 400Mo which prevent me to use the 1.2Go leaving on this card…
Has anybody seen such behavior and found a way to get rid of theses problems?