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?
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.