Recommended for any and all troubleshooters, no matter what your field. Useful and applicable methods for debugging. Jan 03, Frank rated it it was amazing. May 25, Michael rated it really liked it. No better book that breaks down the concept. No trivia or quizzes yet.

Author:Kile Manos
Language:English (Spanish)
Published (Last):26 November 2005
PDF File Size:10.21 Mb
ePub File Size:15.47 Mb
Price:Free* [*Free Regsitration Required]

Understand the System Never guess or assume — Look it up! Always check for previously suspected bugs e. Know your debugging tools — what to choose, how to interpret, their limitations: Stepping-thru reveals logic flaws, but says nothing about timing issues; Profiling reveals timing bottlenecks, but says nothing about logic.

Know how compiler and linker work too — how data is handled and how memory is allocated. Make It Fail There are three reasons for making the system fail: i. Start at the beginning. View the bug at its lowest level, so you fix that, not something else. If multiple manual steps are required, consider automating them. To focus on the cause: Knowing means of failure will assist in revealing causes. In hardware: Noise, vibration, temperature, moisture and parts variation.

Be sure to capture maximum information with each run, then compare when failure occurs. Derive theories from facts. Derive theories to fit facts. View the low-level bug. See it in detail. Always hard, this involves breakpoints, debug statements, watching values, examining memory.

Divide and Conquer This is the only rule here that actually finds the problem. All others support this step. Successive approximation depends on two things: 1. Range of search must be confined 2. Position of a point in the range must be identifiable w.

Determining range is easiest if whole system is included. Proximity to bug is assisted by using constantly varying outputs that emphasize presence of anomaly but be careful, special outputs may change the bug.

Start search at obviously bad outputs and chase the bug upstream. If you find multiple bugs during the search, fix them en-route cleans system, clarifying other bugs. Problems that grow worse over time are likely to be hardware related. Assess the effect of changing each one, being sure to control all others.

The ideal is to understand how the variables are inter-related. Isolate the failure. If one change fails to fix the problem, back it out immediately. Brass bar on nuclear subs: Crew trained to grab it in crisis, to pause and think and study the dials, allowing auto-recovery systems to cut in without deluging original fault beneath a panicky flurry of new conditions.

Compare error logs. Debug logs: Keep and annotate with conditions not captured in log. Logs should have time-stamps too, esp. Question every single little tiny wheeny possible assumption you may have made. Share reports of symptoms, but not theories — let others formulate their own. Just organizing and sharing your own knowledge may be enough to find lateral perspective. Check that it really was the fix you thought, not some other tweak you overlooked.

Boring bugs are best on the back-boiler! If progress is slow and solo, go do something else instead: Save thinking about the solution for later, in a less-stress moment, maybe while walking the dog.


Summary of “Debugging” by David Agans

David A. This book explains the fundamentals of finding and fixing bugs once a bug has been detected , rather than any particular technology. This is a book I expect to find useful many, many, years from now. The entire book revolves around the "nine rules.


Debugging: 9 Indispensable Rules

Even veteran debuggers will likely learn a thing or two. Debuggers who naturally use these rules are hard to find. The easy way and the artistic way do not find problems quickly. Buy the Book If you are interested in purchasing this book, you can support Embedded Artistry by using our Amazon affiliate link: By David J Agans My Highlights When it took us a long time to find a bug, it was because we had neglected some essential, fundamental rule; once we applied the rule, we quickly found the problem.



I had some issues following all the explanation debugginf. Debugging Rules! A solid book on general timeless debugging principles. Victor Grigoriu rated it it was amazing Jun 13, Very light and lots and lots of war stories but aimed to be amusing and was at least somewhat amusing and fairly short. To ask other readers questions about Debuggingplease sign aagans.



Related Articles