Quantcast
Channel: Intel® Software - OpenCL*
Viewing all articles
Browse latest Browse all 1182

clSetMemObjectDestructorCallback calls callback with invalid mem_obj

$
0
0

Hi everyone,

I wrote a little wrapper for clMemoryObjects in which I set a callback for buffer/memory destruction via clSetMemObjectDestructorCallback (actually it's the C++ wrapper equivalent).

When the callback is called, however, and I want to query the cl_mem, which is passed to the callback by the API, I sometimes get an error code Of "-38" -> CL_INVALID_MEM_OBJECT. The application is basically single threaded, so I don't see, where the object should have been destroyed elswhere.

I am also using other OpenCL platforms, in which the code workd properly, so I'm wondering where to look next for my bug.

Best regards

Matthias 


Viewing all articles
Browse latest Browse all 1182

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>