CUDA-gdb errors

Hi All,

I was trying to manually install cuda-gdb from the cuda-gdb source code on the Linux. I first grabbed the cuda-gdb 4.1 from the nvidia ftp server and configured it to target x86_64-unknown-linux-gnu. Everything is compiled but the executable cannot run due to a error of “Attempt to register a unknown architecture” and it was aborted. I then tried cuda-gdb 4.0, which was working. The problem with 4.0 is that although the cuda-gdb 4.0 executable could run with CUDA applications, it was not able to recognize the .cu file. I tried to make a breakpoint in the kernel file but it could not recognize the file. However the breakpoint worked with c/cpp files for this cuda-gdb 4.0.

I used Fedora and the CUDA version is 4.1. I cannot run “make install” on the machine because I do not have the privilege. I was wondering if that was the reason for the problem I have with cuda-gdb 4.0?

I am also interested in using the CUDA debugger API but I cannot find the interfaces to use those APIs. Does anyone have a clue of how to use them? maybe some examples?

Thank you very much in advance.

Hi Flyree,

You may have to configure cuda-gdb to support 2 targets using the following option:


Also, you might want to try the --prefix option to have cuda-gdb installed in a location that does not require administrator priviledges. For instance:


Finally, the best examples to use the CUDA Debugger API is the cuda-gdb source code itself. The header file for the API is cudadebugger.h and is distributed with cuda-gdb. You can also find it with the standard toolkit installation under extras/Debugger/include/cudadebugger.h. The documentation for it is also shipped with the toolkit and is located in cuda/extras/Debugger/doc/CudaDebuggerAPI.pdf.


Thank you Alban.

I add the option m68k-unknown-linux-gnu and it is not working. But my machine is actually in x86_64. Why do I need to add m68K option ?


The m68k architecture is a placeholder for the CUDA architecture. Without it, there is no CUDA support.

Just making sure, did you build cuda-gdb using all options mentioned in the README.NVIDIA file? In particular:

$ export CFLAGS='-O -I/usr/local/cuda/include'

$ export LDFLAGS='-lpthread'

$ ./configure --prefix=/usr/local/cuda \

              --program-prefix=cuda- \

              --enable-cuda \


If yes, can you post the exact output?

For reference, the solution proposed on April 17th fixed all the issues.