没有合适的资源?快使用搜索试试~ 我知道了~
首页Debugging - The 9 Indispensable Rules for Finding Even the Most Elusive Problems.pdf
Debugging - The 9 Indispensable Rules for Finding Even the Most ...

Debugging - The 9 Indispensable Rules for Finding Even the Most Elusive Problems.pdf
资源详情
资源评论
资源推荐


Debugging

Table of Contents
Debugging—The Nine Indispensable Rules for Finding Even the Most Elusive Software
and Hardware Problems...................................................................................................................1
Chapter 1: Introduction.....................................................................................................................4
Overview..................................................................................................................................4
How Can That Work?...............................................................................................................4
Isn't It Obvious?.......................................................................................................................4
Anyone Can Use It...................................................................................................................5
It'll Debug Anything..................................................................................................................5
But It Won't Prevent, Certify, or Triage Anything.....................................................................6
More Than Just Troubleshooting.............................................................................................6
A Word About War Stories.......................................................................................................7
Stay Tuned...............................................................................................................................7
Chapter 2: The Rules−Suitable for Framing....................................................................................9
Chapter 3: Understand the System................................................................................................10
Overview................................................................................................................................10
Read the Manual....................................................................................................................11
Read Everything, Cover to Cover..........................................................................................12
Know What's Reasonable......................................................................................................13
Know the Road Map..............................................................................................................14
Know Your Tools....................................................................................................................14
Look It Up...............................................................................................................................15
Remember.............................................................................................................................16
Understand the System....................................................................................................16
Chapter 4: Make it Fail.....................................................................................................................17
Overview................................................................................................................................17
Do It Again.............................................................................................................................19
Start at the Beginning............................................................................................................19
Stimulate the Failure..............................................................................................................19
Don't Simulate the Failure......................................................................................................20
What If It's Intermittent?.........................................................................................................21
What If I've Tried Everything and It's Still Intermittent?..........................................................22
A Hard Look at Bad Luck.................................................................................................22
Lies, Damn Lies, and Statistics........................................................................................23
Did You Fix It, or Did You Get Lucky?.............................................................................23
"But That Can't Happen"........................................................................................................24
Never Throw Away a Debugging Tool...................................................................................25
Remember.............................................................................................................................26
Make It Fail.......................................................................................................................26
Chapter 5: Quit Thinking and Look................................................................................................27
Overview................................................................................................................................27
See the Failure.......................................................................................................................29
See the Details.......................................................................................................................31
Now You See It, Now You Don't............................................................................................33
Instrument the System...........................................................................................................33
Design Instrumentation In................................................................................................33
i

Table of Contents
Chapter 5: Quit Thinking and Look
Build Instrumentation In Later..........................................................................................35
Don't Be Afraid to Dive In.................................................................................................36
Add Instrumentation On...................................................................................................36
Instrumentation in Daily Life.............................................................................................37
The Heisenberg Uncertainty Principle...................................................................................37
Guess Only to Focus the Search...........................................................................................38
Remember.............................................................................................................................38
Quit Thinking and Look....................................................................................................38
Chapter 6: Divide and Conquer......................................................................................................40
Overview................................................................................................................................40
Narrow the Search.................................................................................................................42
In the Ballpark..................................................................................................................43
Which Side Are You On?.................................................................................................44
Inject Easy−to−Spot Patterns................................................................................................44
Start with the Bad...................................................................................................................45
Fix the Bugs You Know About...............................................................................................46
Fix the Noise First..................................................................................................................46
Remember.............................................................................................................................47
Divide and Conquer.........................................................................................................47
Chapter 7: Change One Thing at a Time.......................................................................................48
Overview................................................................................................................................48
Use a Rifle, Not a Shotgun....................................................................................................49
Grab the Brass Bar with Both Hands.....................................................................................50
Change One Test at a Time...................................................................................................51
Compare with a Good One....................................................................................................51
What Did You Change Since the Last Time It Worked?........................................................52
Remember.............................................................................................................................54
Change One Thing at a Time...........................................................................................54
Chapter 8: Keep an Audit Trail.......................................................................................................55
Overview................................................................................................................................55
Write Down What You Did, in What Order, and What Happened..........................................56
The Devil Is in the Details......................................................................................................57
Correlate................................................................................................................................58
Audit Trails for Design Are Also Good for Testing.................................................................58
The Shortest Pencil Is Longer Than the Longest Memory.....................................................59
Remember.............................................................................................................................59
Keep an Audit Trail...........................................................................................................59
Chapter 9: Check the Plug..............................................................................................................61
Overview................................................................................................................................61
Question Your Assumptions..................................................................................................62
Don't Start at Square Three...................................................................................................63
Test the Tool..........................................................................................................................63
Remember.............................................................................................................................65
Check the Plug.................................................................................................................65
ii

Table of Contents
Chapter 10: Get a Fresh View.........................................................................................................66
Overview................................................................................................................................66
Ask for Help...........................................................................................................................66
A Breath of Fresh Insight.................................................................................................66
Ask an Expert...................................................................................................................67
The Voice of Experience..................................................................................................67
Where to Get Help.................................................................................................................68
Don't Be Proud.......................................................................................................................69
Report Symptoms, Not Theories............................................................................................69
You Don't Have to Be Sure..............................................................................................70
Remember.............................................................................................................................70
Get a Fresh View.............................................................................................................70
Chapter 11: If You Didn't Fix it, It Ain't Fixed................................................................................71
Overview................................................................................................................................71
Check That It's Really Fixed..................................................................................................72
Check That It's Really Your Fix That Fixed It.........................................................................72
It Never Just Goes Away by Itself..........................................................................................73
Fix the Cause.........................................................................................................................73
Fix the Process......................................................................................................................74
Remember.............................................................................................................................75
If You Didn't Fix It, It Ain't Fixed.......................................................................................75
Chapter 12: All the Rules in One Story..........................................................................................76
Chapter 13: Easy Exercises for the Reader..................................................................................78
Overview................................................................................................................................78
A Light Vacuuming Job..........................................................................................................78
A Flock of Bugs......................................................................................................................79
A Loose Restriction................................................................................................................81
The Jig Is Up..........................................................................................................................85
Chapter 14: The View From the Help Desk....................................................................................88
Overview................................................................................................................................88
Help Desk Constraints...........................................................................................................89
The Rules, Help Desk Style...................................................................................................89
Understand the System....................................................................................................90
Make It Fail.......................................................................................................................91
Quit Thinking and Look....................................................................................................91
Divide and Conquer.........................................................................................................92
Change One Thing at a Time...........................................................................................92
Keep an Audit Trail...........................................................................................................92
Check the Plug.................................................................................................................93
Get a Fresh View.............................................................................................................93
If You Didn't Fix It, It Ain't Fixed.......................................................................................94
Remember.............................................................................................................................94
The View From the Help Desk Is Murky...........................................................................94
iii
剩余105页未读,继续阅读

















安全验证
文档复制为VIP权益,开通VIP直接复制

评论8