What is a good unix alternative to DDD (Data Display Debugger)?
Solution 1
Solution 2
Well I tend to use either cgdb, kgdb or ddd. (and since you can't use ddd...)
cgdb is almost like the normal gdb but it shows the code in a split window above.
Solution 3
I use Eclipse CDT in my daily basis as well as Visual Studio and it is very good tool, as good as Visual Studio. It uses all the Eclipse infrastructure to create a very good gdb graphical interface. Is like debugging Java but with C++.
If you don't want to generate eclipse projects just for debugging because you still want to use vim as an editor you might want to know that Cmake has eclipse project generator. Some links that might help you regarding this issue: 1, 2, 3
Solution 4
Have you looked at the Emacs GDB integration? It's quite good, once you work out how to use it. Here's a screenshot: http://p.blog.csdn.net/images/p_blog_csdn_net/ariesjzj/pic3.jpg.
Alternatively, there's Eclipse. It's very pretty, and seems pretty comprehensive but I haven't used it much.
Failing that, I just use GDB in TUI mode (type 'layout next' lots of times until the display looks 'prettier').
I actually really miss Visual Studio now that I'm stuck developing for Linux and embedded systems.
Solution 5
gdbgui is a browser-based frontend to gdb, the gnu debugger. You can add breakpoints, view stack traces, and more in C, C++, Go, and Rust!
It's perfect for beginners and experts. Simply run gdbgui from the terminal to start the gdbgui server, and a new tab will open in your browser.
frankster
Updated on October 24, 2020Comments
-
frankster over 3 years
I am developing c on linux using vim and debugging using ddd. However I find that ddd performs very poorly at scrolling on this machine so its sometimes very frustrating to use.
I like the way that ddd maps fairly closely to the gdb command set as this means I am free to use gdb commands when I choose, but using gdb itself is not an option as it does not do a great job of displaying the source.
Can anybody suggest a decent alternative to ddd? I am not looking for an IDE, merely a reasonably well implemented gui facade to gdb that is free software.
-
Juan almost 15 yearsas an additional note, the old version of Sun Studio on Linux used the gcc compiler with gdb. I don't know if it is still compatible as they now ported their compilers to Linux.
-
frankster almost 15 yearsFirst impressions: The opensuse11 package is buggy and the icon it installs doesn't launch the app, but I can launch it myself from /opt/kde3/bin/kdbg. Attaching to a process forces you to type the process number instead of searching the process list for a process with the same name as the binary you just loaded
-
frankster almost 15 yearsThe variable display in KDbg is nice.
-
frankster almost 15 yearsthough on the other hand, it seems like a bit of a pain to view the values of expressions such as "Array[Index].Struct.Member"
-
frankster almost 15 yearsits a bit annoying having to break execution in order to disable a breakpoint
-
frankster almost 15 yearsand if you want to detach from a process it seems you have to force it by loading a different file
-
Johan almost 15 yearsThis is kind of not useful today (even thou I give you +1 for the fact that there is hope for ddd ;)
-
frankster almost 15 yearsdouble clicking on a breakpoint in the breakpoint list doesn't take you to the corresponding line of code
-
frankster almost 15 yearsInsight's attach to process window is buggy - the filter box does nothing. However at least it puts up a process list which is a slight improvement on kdbg.
-
frankster almost 15 yearsThe drop down box with a list of functions to browse to in the source is a nice touch.
-
frankster almost 15 yearstwice brought down my x server when I attached to a process, continued the process then attempted to pause the process. I can rule Insight out.
-
frankster almost 15 yearsFrom what I can see, the Intel Debugger is available with the Intel Compiler but you can only get a zero-cost license for non-commercial use.
-
frankster almost 15 yearsSun Studio debugger (dbxtool) is based on java so its startup is rather slow.
-
frankster almost 15 yearsStun Studio debugger successfully pops up a tooltip with the value when you mouseover variables of the form Array[Index].Struct.Member, which none of the other GUIs have been able to. (of course GDB can always do this with a print command but for some reason none of the GUIs have implemented support for this).
-
frankster almost 15 yearsOverall, I like a lot of things about dbxtool but the java-lagginess is such a shame.
-
frankster almost 15 yearsaha I didn't know about this TUI mode of gdb. Its not great but it certainly addresses to some extent my gripe about gdb not displaying the source very well.
-
frankster almost 15 yearshaving problems with dbxtool on a 64-bit environment - dbx itself will load a 64-bit executable, but when I load the executable via dbxtool, it gives an unsupported architecture error, presumably because its trying to load it into the 32-bit version of dbx
-
frankster over 14 yearsI just type layout - it gives an error but ends up with the layout most useful to me :D
-
matiu almost 11 years+1 because it works in the console. So I can record my sessions with ttyrec, and share them with byobu/screen.
-
ysap over 10 yearsActually, you can define a gdb session in Eclipse w/o a project. Just define the program in the "Debug Configurations..." dialog, possibly using the "C/C++ Application" configuration selection. After filling the "C/C++ Application:" entry, and possibly the "Arguments" tab, click on the "Apply" and "Debug" buttons to get to the debug perspective.
-
Brent Faust over 10 yearsNo need to give up vim when using Eclipse. I use the Vrapper Eclipse plugin which gives a reasonable amount of vi goodness.
-
tuket over 9 yearsInsight is dead. I even tried to build but I didn't succed.
-
Atif almost 8 yearsLooks like they may have been hope in 2009, but in 2016, a DDD overhaul looks rather hopeless..
-
EvertW over 4 yearsddd was built using ancient technology. Let it rest in peace. The effort of reviving it is probably greater than building a new one. And in its current form it can still be useful on very small systems.