Hi,
Is there a way I can run OpenCL programs in emulation mode on CPU itself without having to install driver or graphics card.
If there is such a mode, is the code genearted by the OpenCL compiler in emulation mode diffirent.
If there is a way to generate assembly without having the graphics card installed it is fine with me. I don’t really need to run the code.
It is possible to run OpenCL programs on the CPU, however you’ll have to install an OpenCL CPU backend / driver, like those from Intel or AMD. NVIDIA does not currently offer a way to run OpenCL kernels on the CPU. That said, running your program on the CPU will not allow you to debug any issues you might currently have with running the OpenCL kernel on the GPU in particular, simply because the OpenCL runtime / compiler is a completely different one then, with completely different bugs :-)
When you say assembly, for which architecture? PTX or x86 assembly? In the latter case, the Intel OpenCL SDK comes with an offline compiler tool. Regarding PTX / NVIDIA GPU assembly, I guess there is no way to generate it without a GPU unless you have a Tesla card and a headless driver.
Hi,
I am looking to generate PTX assembly. Please correct me if I am wrong. NVIDIA cuda compiler (atleast on linux) does have a -deviceemu option which allows you to build and run your code on CPU.
I was looking for a similar option which if not allow me to run my code will atleast allow me to build my source code.
Rightnow my program fails in clGetDeviceIDs call itself.
Hi,
The issue is I dont possess the NVIDIA card and I just wished to compile my code and check the assembly generated. So I cannot use clGetProgramInfo. I have a windows development enviornement and gpuocelot i think is only avaialaible for linux (specifically Ubuntu).