mic_head
mic_head

Reputation: 21

Breakpoints not working in OpenCL kernel using Cloo(C# wrapper for OpenCL) and Intel SDK

I'm developing an OpenCL application in C# with Cloo. I'm getting strange values back from my device (Intel CPU), so I decided to use an OpenCL debugger to set some breakpoints in the kernel. They are ignored, even though I've enabled the Intel Debugger in Visual Studio 2012. Maybe I should build the program using the path of the kernel and not a string containing the source, but I cannot find a way to do it using Cloo.

Here's the way i build the program:

program = new ComputeProgram(context, kernelSource);
program.Build(devices, "-g", null, IntPtr.Zero);

where kernelSource is the string containing the OpenCL source. Thanks in advance!

Upvotes: 2

Views: 736

Answers (1)

Raghu
Raghu

Reputation: 21

You need to build your program with "-g -s ", where should include the .cl file you are trying to build. Also make sure there are no #include files in your kernel. If nothing works please set the environment variables:

INTEL_OCL_DBG_LOG=1 INTEL_OCL_DBG_LOG_FILE=c:\temp\debugger.txt

and restart Visual Studio. Continue debugging. This will generate a log file which will let us determine why the debugging is not working. You can submit this log at http://software.intel.com/en-us/forums/intel-opencl-sdk. This is the place you can also submit issues/ask questions regarding Intel OpenCL SDK.

Thanks.

Upvotes: 2

Related Questions