Live data from Hacker News

Show HN: Uscope, a new Linux debugger written from scratch

github.com

11–20 of 133 posts

Re: Show HN: Uscope, a new Linux debugger written from scratch

#11
post #8

It's not clear to me why we'd need a new debugger instead of GDB enhancements. GDB has an extensible, modern C++ codebase with literal decades of hard earned knowledge baked into it. How are we better off rewriting it, especially if the rewrite isn't memory safe?

Consider this part of the post: > I've been building a debugger on my nights and weeks because it's fun

I'm considering the part that says "GDB and LLDB pain me greatly". This project both says "I'm doing this for fun" and "the state of the art is bad, and I'm trying to fix it", so this is a fair question.

GDB is great. He says it crashes a lot, and cannot interpret some of his types. Maybe that's his experience, but I haven't had those issues after literally decades of using gdb. Some bug reports would be nice.

Re: Show HN: Uscope, a new Linux debugger written from scratch

#12
post #2

To clarify “from scratch” as in from basic materials and not “in scratch” as in the MIT graphical programming g system[0]. It appears to be written in Zig[1], which I find interesting for analysis. 0. https://scratch.mit.edu/ 1. https://github.com/jcalabro/uscope

"written from scratch" is one of those phrases that seems to cause any submission to instantly hit HN frontpage, along with "for fun and profit", "considered harmful", and a couple others.

Re: Show HN: Uscope, a new Linux debugger written from scratch

#13

  > Build as a library so other people can build other interesting things as well 
I LOVE this!

I firmly believe so much tech has gone to shit because things are no longer hackable. We say "move fast and break things" but we try so hard to prevent that that when we do break things we just create bigger messes and debt, so no one cleans it up. It seems slower to write hackable code but that's in the moment. In the long run it is much faster. Not to mention you get added benefits of others being able to contribute more easily with a lower likelihood of actually breaking shit.

Re: Show HN: Uscope, a new Linux debugger written from scratch

#14

It's not clear to me why we'd need a new debugger instead of GDB enhancements. GDB has an extensible, modern C++ codebase with literal decades of hard earned knowledge baked into it. How are we better off rewriting it, especially if the rewrite isn't memory safe?

> GDB has an extensible, modern C++ codebase with literal decades of hard earned knowledge baked into it.

I literally laughed outloud at this. Have you ever actually opened a GDB source file? It is, as a whole, extremely poor quality code. Almost all of it is doing C string manipulation and raw pointer arithmetic; almost none of it uses C++ smart pointers, nevermind the rest of "modern C++"; the vast majority is completely uncommented, and "literal decades of hard earned knowledge" can be better translated as "literal decades of historical baggage, cruft, and hacks". I regularly cause GDB to segfault in normal, mundane operations.

Re: Show HN: Uscope, a new Linux debugger written from scratch

#15

It's not clear to me why we'd need a new debugger instead of GDB enhancements. GDB has an extensible, modern C++ codebase with literal decades of hard earned knowledge baked into it. How are we better off rewriting it, especially if the rewrite isn't memory safe?

  > It's not clear to me why we'd need a new debugger
People build things for fun. Stop asking "why" and ask "why not?"

No one can really predict what's needed and where we need to go, so let people just explore. Sometimes they won't find things, but sometimes they do. And if they don't, they still gain useful knowledge that pays dividends later on anyways.

It's Hacker News, let people hack.

Re: Show HN: Uscope, a new Linux debugger written from scratch

#18
post #3
post #2

To clarify “from scratch” as in from basic materials and not “in scratch” as in the MIT graphical programming g system[0]. It appears to be written in Zig[1], which I find interesting for analysis. 0. https://scratch.mit.edu/ 1. https://github.com/jcalabro/uscope

lol, I think no one expected a linux debugger to be written in the visual programming language for kids.

I'd be very impressed if it were, though.
Post reply on HN