Debugging





Debugging

There are two major phases of debugging activities: Well-established fact: It is much more expensive (in terms of time and effort) to detect/locate existing bugs, than to prevent them in the first place.


Bug Location

The primary rule of debugging is:

Use the process of elimination!


Splitting Code Into Regions


Examine Intermediate Values


Use Intermediate Values To Narrow Scope


Once You've Found the Faulty Region

Once you've found the region:




Stephen Edwards <edwards@cs.vt.edu>
Last modified: Sun Mar 16 21:07:53 EST 1997