OpenCL* for CPU
Ask questions and share information on Intel® SDK for OpenCL™ Applications and OpenCL™ implementations for Intel® CPU
Announcements
This forum covers OpenCL* for CPU only. OpenCL* for GPU questions can be asked in the GPU Compute Software forum. Intel® FPGA SDK for OpenCL™ questions can be ask in the FPGA Intel® High Level Design forum.
1663 Discussions

OclCpuDebugging2.dll Exception when trying to hit breakpoint in OpenCL code

steve_w_2
Beginner
227 Views

I've tried to follow all the instructions for setting up Code-Builder to debug our OpenCL code in Visual Studio 2015 in x64 Windows (we currently debug our Linux code using the Ubuntu IDEs we use simply start working as soon as we add the Intel drivers and select the CPU device for processing). 

- I added the Windows Intel OpenCl platform. Once I did that I get both CPU and GPU devices enabled in our app and can indeed render our images in the Gpu and Cpu (I can tell given the 100x speed difference!)

- I installed the OpenCL SDK 

- I updated the OpenCL.dll in SYSWOW64 as instructed in another post

- I enabled Code-Builder->Debugger->Options->Enable...CPU device (although I have no idea how to set the 'Work Items'). It popped up a firewall warning the first time I attempted a run but after I told the firewall dialogue to ignore that, I got no more complaints.

- I made sure my path to the cl files was set to the full path when compiled and opened those files in VS to set the breakpoints

But even with all this I keep getting the following exception:

Exception thrown at 0x00007FFA49154AB3 (OclCpuDebugging2.dll) in XXX.exe: 0xC0000005: Access violation reading location 0x0000000000000010.

I think I've reviewed most of the commentary and advice on this blog. Any suggestions?

Steve

 

0 Kudos
6 Replies
Jeffrey_M_Intel1
Employee
227 Views

Thanks for this report.  Does this issue happen with all kernels or is it specific to yours?  Can you replicate the behavior with one of the code builder template projects or one of the Intel OpenCL samples?

 

steve_w_2
Beginner
227 Views

Hi Jeffrey

I haven't had an opportunity to poke around the samples - I was hoping to be able to focus on porting our existing product code. It runs fine on the GPU (and CPU, given Intel's drivers). I'll see if I can dig into them (assuming I can find them). Any ideas on what may be going on here in the meantime?

 

steve_w_2
Beginner
227 Views

Um... anyone know where the SDK hides the code samples?

 

Vladimir_L_Intel
Employee
227 Views

Intel OpenCL code samples can be downloaded separately from https://software.intel.com/en-us/intel-opencl-support/code-samples. ;

Could you please provide more details about OpenCL driver you are using? 

steve_w_2
Beginner
227 Views

Hi

Yes - I have the "OpenCL runtime for Intel Core and Xeon Processors 5.2.0.10002" installed, Like I mentioned, it runs fine when I select that device in OpenCL (although, naturally, slowly). It's only when I add enable Code-Builder debugging and have the -g -s compile switches set that I get these crashes (breakpoints or not) as soon as the first kernel is run.

I wouldn't be surprised if we're not setting up something correctly for the device (clContext or the like). I can dive into the thread stacks on the crash too. Any suggestions?

Vladimir_L_Intel
Employee
227 Views

hi,

Please use the latest CPU RT (16.1.1) published recently it contains fix for Debugging functionality: https://software.intel.com/en-us/articles/opencl-drivers#core_xeon

Reply