Handmade Network»Forums»Work-in-Progress
spx
148 posts / 1 project
codeclap: Introducing yet another debugger for Linux; ETA 2017-09-11
Edited by spx on
Greetings,

I've been working on this for some time now (probably since the start of this year) and I am quite excited to finally be able to introduce this project to you all.

In a sense it is "yet another" debugger project and I can only make assumptions in which way this project may differ from the other projects out there.
But i can give you a few bullet points which aspects are important to me (at least those that come to my mind right now):
  • Provide the best possible experience of understanding what is going on when the compiled code is executed, why it is doing what it is doing and how it reached the state you may observe at that time.
  • The actual machine (assembly+memory) as a first class citizen.
  • Eventually I would love to have the same debugging tools readily available on multiple platforms (though my own need at the moment is limited to Linux and Unix environments in general).
To give you a quick impression I will start with a screenshot today; followed by a few showcases of various features which are already there in the upcoming days.
Some parts are definitely subject to change, for example the expression view is far to clunky at the moment.


I expect the first (early) release to be available on September 11.

If you would like me to test the debugger with a specific open-source software or code that is available somewhere please don't hesitate to say so; implementing DWARF isn't the most pleasant task one can imagine and there may still be some cases left that could cause problems.
Mārtiņš Možeiko
2559 posts / 2 projects
codeclap: Introducing yet another debugger for Linux; ETA 2017-09-11
Edited by Mārtiņš Možeiko on
Very nice.

You screenshot looks very blurry and hard to read for me... Maybe its because you are using jpeg instead of png as image compression. Please use png for screenshots where there is a lot of small text.
spx
148 posts / 1 project
codeclap: Introducing yet another debugger for Linux; ETA 2017-09-11
Edited by spx on
Sorry for the image quality. I have replaced the image with the png version. The biggest issue however is probably that i've scaled the resolution from 1440 to 1080 (and I don't have the unscaled one anymore). For the showcases I will behave and do them natively in 1080. Thank you for the hint :).
spx
148 posts / 1 project
codeclap: Introducing yet another debugger for Linux; ETA 2017-09-11
Edited by spx on Reason: typo
I've changed the image in the first post with one that should provide better quality when viewed 1:1 without any scaling.

Also there is now a first video that shows basic features one would expect from every debugger. For some reason in the video red text on gray background gets blurry quite a bit, so for now I've changed the active line in the source view to have a red shadow instead.
Simon Anciaux
1337 posts
codeclap: Introducing yet another debugger for Linux; ETA 2017-09-11
I've never seen the "display values in the source" feature and I'm curious to try it. Could it be extended to show values at other places than the declaration ? Maybe choose what field to display from structs ? Display both decimal and hexadecimal (and binary ?) values ?

I'm looking forward to trying it out.
Mārtiņš Možeiko
2559 posts / 2 projects
codeclap: Introducing yet another debugger for Linux; ETA 2017-09-11
Many debuggers do that now. For example:
Chrome builtin JS debugger: https://developers.google.com/web...ipt-values-inline-while-debugging
IntelliJ IDEA: https://www.jetbrains.com/help/idea/inline-debugging.html
CLion: https://www.jetbrains.com/help/clion/inline-variables-view.html
spx
148 posts / 1 project
codeclap: Introducing yet another debugger for Linux; ETA 2017-09-11
very true, that is not something novel. PyCharm has it as well nowadays (well i guess at lot of jetbrains software).

The inline display is pretty basic at the moment. Showing the value at the point of declaration is easiest because this information is provided to you by DWARF for free.
spx
148 posts / 1 project
codeclap: Introducing yet another debugger for Linux; ETA 2017-09-11
I've created a second video basically showing the other half of the debugger window. There are a few nice things the watch window is capable of, but overall this part of the debugger is rather weak at the moment.
David Butler
81 posts / 1 project
I love pretty much anything technical, whether it be programming, networking, hacking or electronics.
codeclap: Introducing yet another debugger for Linux; ETA 2017-09-11
This looks very cool :) Your user interface feels very clean, is it from scratch?
spx
148 posts / 1 project
codeclap: Introducing yet another debugger for Linux; ETA 2017-09-11
Croepha
This looks very cool :) Your user interface feels very clean, is it from scratch?

yes, the interface stuff is mostly from scratch (mostly because I still use nanovg for the actual rendering, I barely use any features from it but so far I was just too lazy to correctly implement text rendering). From time to time this has its downsides as it is not a fully mature library (few misalignment in text rendering, no caret in text input, no copy and paste, probably very poor handling of keyboard layouts) but imo it is totally worth it and at some point those issues will be fixed as well.
spx
148 posts / 1 project
codeclap: Introducing yet another debugger for Linux; ETA 2017-09-11
Edited by spx on
Made another video of a neat little toy. I don't know if this will be actually useful some day but it is something that could be extended in interesting directions.
Josh Ayres
8 posts
High School student who likes programming
codeclap: Introducing yet another debugger for Linux; ETA 2017-09-11
This looks really cool, it's still coming out tomorrow right?
spx
148 posts / 1 project
codeclap: Introducing yet another debugger for Linux; ETA 2017-09-11
Edited by spx on
Jvac
This looks really cool, it's still coming out tomorrow right?

yes, the project is still on track.
It will be later in the day, partially because I was away for the last 3 days. But besides that this first pre-alpha build will be part of a patreon page which is in the process of being made. Also I will put the build together after doing all the work for today to get the best possible result.

I will write a bit more regarding why I call the current state "pre-alpha", the different stages and planning/goals regarding reaching "alpha" stage and further. From time to time there will probably builds available completely free without any kind of support or pledge but there is no definite schedule for this.

There was also a last video planned on currently existing minimal customization options, the way of starting the debugger using preconfigured paths (there is currently no UI for this) or the command line. I hope to get this done without any considerable delay.

// Update: Expect something around 11:30-12:00 PM PST, project management is hard when you also want to get things done at the same time..
spx
148 posts / 1 project
codeclap: Introducing yet another debugger for Linux; ETA 2017-09-11
Edited by spx on
well I missed the originally intended time by quite some hours but you gotta start somewhere. It is now available; I didn't quite manage to get everything I wanted in it and will have to make a second build later. The second one will include additional help content that will explain some of the customization files and keyboard shortcuts.

The current state is available as part of the following Patreon project:
https://www.patreon.com/codeclap

I'd love to encourage everyone who is interested in supporting the idea behind this project and all those who want to influence the direction this project is moving in to try out these builds and hopefully support the project.

Here is a copy & paste from the Patreon page of things that are currently on top of my priority list:
  • conditional and memory breakpoints
  • out-of-process debugging (also attach and remote debugging)
  • customizable keybindings (and more customization options)
  • casts and function calls in watch window
  • inlined functions are not handled very well in source view
  • better C++ support (inheritance, possibly pretty-printing of STL structures; because someone will ask for it at some point)
.. also memory usage is bad at the moment in order to speed up parsing of bigger DWARF sections

// Some more
Hard requirements at the moment are:
  • X11
  • OpenGL 2.1
x64 in the description is to be taken literally. Currently the debugger only has partial support for 32bit binaries, will not try to detect them and will not work.
44 posts
codeclap: Introducing yet another debugger for Linux; ETA 2017-09-11
Great to see a debugger for Linux being released! Just signed up, look forward to trying it this evening.