Download presentation
Presentation is loading. Please wait.
Published byJulian Hunter Modified over 9 years ago
1
The Whole and the Parts Chapter 13
2
Top-Down Design Top-Down design helps in the following ways. 1. Clarity of structure and representation makes the precise statement of requirements and functions of the modules easier 2. Partitioning and independence of modules avoids system bugs 3. Suppression of detail makes flaws in the structure more apparent 4. The design can be tested at each of its refinement steps, so testing can start earlier and focus on the proper level of detail for each step
3
Keeping the big picture in mind One wants to think about control structures of a system as control structures, not as individual branch statements One wants to think about control structures of a system as control structures, not as individual branch statements
4
!GOTO GO TO, produces structures that lend themselves to logical errors. – Dijkstra GO TO, produces structures that lend themselves to logical errors. – Dijkstra Just don’t do it Just don’t do it
5
Useful debugging tips (for large scale debugging) The prep work at your desk should usually take about as long as the debugging at the computer. The prep work at your desk should usually take about as long as the debugging at the computer. About half the time is typically updating the debugging log and filling updated program listings in the system notebook, explaining strange phenomena (documentation) About half the time is typically updating the debugging log and filling updated program listings in the system notebook, explaining strange phenomena (documentation)
6
Debugging Warning: Debugging takes a LONG TIME. Warning: Debugging takes a LONG TIME. Build Scaffolding Build Scaffolding Dummy Components –Faked data & small test cases Miniature File – ie. When search testing a file, use a small one to save time Auxilary Programs – Creates test data, shows special analysis. Note: It’s not uncommon for Scaffolding to take up 1/3 of the total code written.
7
Control Changes Appoint a dictator Appoint a dictator Playpen copies Playpen copies Backed up latest working version (used for testing) One copy under test, with fixes being installed Add one component at a time Add one component at a time Use common sense “To do it requires dummies and other scaffolding, and that takes work. And after all, perhaps all that work won’t be needed? Perhaps there are no bugs? No! Resist the temptation!”
8
Quantize Updates Testing updated components should take less time than testing new components, but still needs to be done. Testing updated components should take less time than testing new components, but still needs to be done. Changes should be done in the exact manner of anti-virus updates. Small changes all the time, or big changes every once and a while. Changes should be done in the exact manner of anti-virus updates. Small changes all the time, or big changes every once and a while.
9
Extra THINK ABOUT WHAT YOU WRITE THINK ABOUT WHAT YOU WRITE http://thedailywtf.com/Articles/If-Ive-Said-It-Once,-Ive-Said-It-Fifty-Times.aspx http://thedailywtf.com/Articles/If-Ive-Said-It-Once,-Ive-Said-It-Fifty-Times.aspx
10
Das Ende Fragen? Fragen? Goto: thedailywtf.com
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.