I have some code that works fine in device emulation, but not on the device. I would like to debug it on the device using cuda-gdb. However, I have only a single GPU and cuda-gdb does not work when X11 is running. I tried switching to run level 3 and running my code, but it does not work, and exits with an error. I think it exits with an error because the appropriate nvidia / cuda drivers are not loaded in runlevel 3. I tried “modprobe nvidia” to load the drivers, and the drivers seem to be loaded, but my code doesn’t work without X11 being loaded.
Is there anyone that has had success using cuda-gdb provided with CUDA 2.3 under FC9 on a single GPU?
You don’t provide enough information, but I’d wager your nvidia devices don’t get created.
Try ls /dev/nv* to see if they’re there, if not
try modproding again, and then
mknod -m 666 /dev/nvidia0 c 195 0
mknod -m 666 /dev/nvidiactl c 195 255
Is it possible that the code does not run on the device because the kernel is too fat i.e. It is running out of memory? I am checking the return code, but I don’t see anything strange.
In addition, when I run the code compiled under device emulation mode under Valgrind, it points out errors saying “conditional move or jump depends on uninitialized values”. This is strange, because I copied data from the CPU into that particular GPU array. Could this also be because the kernel is possibly too large?
Sorry for the multiple replies to my own post, but it doesn’t seem to be running out of memory. I started the kernel with only one thread per block, and it still gives me NaNs in normal mode … works perfectly in Device Emulation.