Image2D not working correctly on GPU

Image2D not working correctly on GPU


I encountered that strange behavior on geforce gt540m (openCL 1.1). I am using c++ api and everything is working correctly on i3 2310m (also tried on i7 and Nvidia Quadro 4000m). But when I want to use GPU it crashes on Image2D costructor (it gets through #if defined(CL_VERSION_1_2) in cl.hpp). I tried to make a workaround by using C API's both clCreateImage2D and clCreateImage and then using Image2D constructor but still no luck. Again when I use CPU everything is working. Any ideas what could be wrong?

3 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

Not sure if I understood you correctly. Is it failing both on NVidia GPU and Intel's? But works on the CPU? Can you provide a reproducer?

It works on Intel platform (with CL_DEVICE_TYPE_CPU passed while creating context using Intel platform), but it doesn't work on Nvidia platform (with CL_DEVICE_TYPE_GPU passed while creating context using Nvidia platform). Everything works with C api so I will switch to that but it still bugs me why it doesn't work with C++ api.

Leave a Comment

Please sign in to add a comment. Not a member? Join today