GDB and debugging techniques

Jason jkenner@mindspring.com
Fri, 09 Feb 2001 16:00:23 +0000


"Wacks, David" wrote:
> 
> Hi,
> 
> I am training some new c coders (and other languages) on RH6.2 and FreeBSD.
> I use GDB as the primary debugging tool.  Are there better GPL ones out
> there (or easier to learn)?
> 
> Anyone know of good sites that teach debugging? One problem I am finding is
> that coders today do not know how to debug (this is an overgeneralization
> but one I stand by :) I say this in the same breath that ASP is MS way of
> keeping the VB coders employable. *DUCK*
> 
> Anyway,  I am trying to set consistent and thorough debugging methods and
> trying to train same.  Anyone know of courses, classes, sites, etc to help?

Ive found that if you understand the sourcecode, often *adding* lines
that output information to a file somewhere as the program runs beats
the snot out of any "after the fact" debugger. Doing it that way makes
it possible to spot verify any area of a program ...

Whats your opinion on this approach to debugging? (obviously you dont
want those code snippets showing up in a production release, however!)

-- 
jkenner @ mindspring . com__
I Support Linux:           _> _  _ |_  _  _     _|
Working Together To       <__(_||_)| )| `(_|(_)(_|
To Build A Better Future.       |                   <s>