A Perspective on D from game industry

Kapps via Digitalmars-d digitalmars-d at puremagic.com
Wed Jun 18 22:51:51 PDT 2014


On Thursday, 19 June 2014 at 05:35:06 UTC, Nick Sabalausky wrote:
> That's why I inadvertently learned to love printf debugging. I 
> get to see the whole "chart" at one. Granted, it's in a bit of 
> a "The Matrix"-style "only comprehensible if you know what 
> you're looking at" kind of way. Actual GUI graphs would 
> certainly be nice. But all the data's there at once,  so no 
> need for constant fast-fowarding and rewindi...oh wait, that's 
> right, debuggers can't rewind either. ;)
>
> Honestly, I *have* used and loved debuggers, and I still 
> appreciate them. I do think they're great tools. But...I rarely 
> use them anymore: After several years of being forced into 
> printf-debugging (or worse!!) for various reasons, every time I 
> go back to a debugger I feel like I'm debugging with my hands 
> tied behind my back. Or rather, finding a needle in a haystack 
> using only a microscope that's stuck on max magnification and 
> can only ever move to the right. And it's exactly because of 
> the debugger's "temporal blinders" - the inability to ever see 
> more than one *instant* at a time.

There's a time for both. Being able to step into each method with 
a debugger, execute code, inspect variables, etc, is very very 
useful in certain situations. However in some situations 
(particularly multi-threaded ones I find), printf debugging is 
simply easier as you don't have to stop your program to examine 
state and can easily interact with the program still. C# / Visual 
Studio 2012 has IntelliTrace, which in theory could be promising 
for these situations, but in reality I've never even tried.


More information about the Digitalmars-d mailing list