4 ms·
This attitude is so toxic, it's like saying isn't assembler good enough for you? Good tools matter, there's nothing more painful then a platform where your onl
by vvanders 11y ago
This attitude is so toxic, it's like saying isn't assembler good enough for you?
Good tools matter, there's nothing more painful then a platform where your only debugging is printf.
- fit2rule 11y agoGood tools take time. Complaining about not having them is not very sporting behaviour. Fact is, if you don't have a tool, use printf-style debugging. It has worked for computers since before the very first debugger was ever made, and as a skill it should not be discounted in favour of more, shall we say .. consumer-ist .. attitudes about what 'should' and 'should not' be a normative in programming toolkits. No debugger? No problem. Debuggers are a luxury and a time-saver, but knowing your code-base well enough, because you printf-debug too, is also a time-saver.
- vvanders 11y agoIf you read carefully, you'll see that I was saying the "good enough" attitude is toxic. I was not complaining about not having the tools(I don't even write Go) and a contributor mentioned above that it just wasn't a priority(which I have some beef with) but is a fair statement. There are some problems that can't be solved by printf debugging. They include: -GPU Performance profiling: All your commands are async and appear immediate, teasing out performance characteristics takes a massive suite of tests and may not even reproduce your issue. -Thread concurrency issues: Adding a printf can actually make these bugs disappear as printf usually has some sort of memory fence or flush semantics that change behaviour. -Platforms that can't handle large amounts of trace logging: Sony PSP was one of these where each printf() required the tcp ack before the buffer would clear after a trivial amount of logs. One of the core tenants of comp sci and technology in general is building on what came before. That's where our productivity gains come from. Not taking that approach is a dangerous mentality that can have serious implications on your velocity and agility and is not a choice to be made lightly.
- threeseed 11y ago> Debuggers are a luxury and a time-saver You must have only worked on toy applications before. Because debuggers are essential on any non trivial application.
- sagichmal 11y agoOn the contrary: in my domain, highly parallel distributed applications, debuggers are near useless.
- _ak 11y agoThe funny thing is, in several years of using Go in production in what are certainly non-trivial applications, I was able to find any bug either through log-debugging, often with the help of isolating code in unit tests, or through pprof, in particular the net/pprof integration. Just looking at my own experience, I never _needed_ an interactive debugger, or deemed it essential, but then, that's just one data point.
- fit2rule 11y agoLeaning on debuggers is something newbies and guru's do, when they need it, if they need it, if they have it. If they don't, it doesn't stop the debugging.
- icedchai 11y agoI agree and was being sarcastic.
- fredkbloggs 11y ago> This attitude is so toxic, it's like saying isn't assembler good enough for you? Real programmers don't need an assembler; ed(1) is sufficient and if you can't write a program without anything else, you shouldn't be allowed near computers.