Re: cl_out_of_resources in loop
Posted by Wade Walker on May 23, 2014; 4:11pm
URL: https://forum.jogamp.org/cl-out-of-resources-in-loop-tp4032369p4032382.html
You need to check the return code of every single OpenCL function to see if there's some problem starting earlier. Also, how many loop iterations happen before it fails? There could just be a memory leak in the OpenCL driver that's exposed if you loop 10 million times.
I'd also suggest commenting out more and more of your code to see if it passes, starting from the middle of your loop. If you can create/release contexts OK with no other code present, maybe there's an interdependence with some other kernel or OpenCL resource that you're not deallocating properly.