this is an issue that bugs me for quite some time now. I’m using VS 2005 as an IDE to write CUDA programs. However, when debugging, I can’t step into cu files for information, and setting breakpoints in cu files can’t work too. Everytime I try to step into a cu file, it ends up stepped into the end of the last included header file in cu file.
For instance in cu file:
#include “a.h” #include “b.h”
then debugging will enter the end line of b.h. If you reverse the header files, then you will end up in the end of a.h.
I noticed that someone are having the similar issues in VS2008, but is CUDA also having this bug for VS2005? What’s the solution then?
Are you debugging in which mode? EmuDebug/Debug/EmuRelease/Release? You have to be in emulation mode(EmuDebug or EmuRelease) if you want to debug kernel code. You cant debug when the kernel is actually running on the GPU.
Yeah, I am aware of debugging mode. Although it’s not the case here.
When I attempt to step into any function in a cu file, VS2005 will show me the end of my last included header file instead of pointing to the right function position in cu file. So technically, I can’t be sure when I’m debugging what anyhow.