8.8 Recall a similar problem


8.8 Recall a similar problem

Recalling a similar problem is much easier if you keep a log of bugs you have worked on. Two problems can be similar along a number of dimensions. Similarity is a relative concept, and along each dimension are degrees of similarity.

Here is a list of dimensions of similarity:

  • Symptom and symptom family

  • Input type, volume, structure

  • Output type, volume, structure

  • Programming language used

  • Data structures used

  • Algorithms used

  • Development environment

  • Deployment platform

  • Application architecture

  • Auxiliary components

Symptoms and symptom families are described in Chapter 11. Symptoms are more similar if they belong to the same family.

Input and output type include file type, user actions, and so forth. A text file is more similar to a socket, with respect to access, than to a mouse action. Input and output volume are measured in bytes, records, and so forth. A relational database input is more similar with respect to structure to a spreadsheet than to an ASCII file containing embedded newlines.

The similarity of programming languages is measured by their level of abstraction and size of runtime library, rather than by syntax. C is more similar to assembly language than it is to Java, for example, even though C and Java have some similar syntax.

Data structures used include both those data structures that are built into the language as primitives, as well as those that are implemented using these built-ins. Data structures are similar both due to the features they provide and the methods used to implement them.

Algorithms used are similar in complexity and approach. Two algorithms are similar, for example, if they both use a divide-and-conquer approach.

Development environment includes compilers, debuggers, source control systems, and so forth. The development environment is more similar when it shares components that have common designs and shared components. Deployment platform is hardware and operating system. Linux is more similar to UNIX, for example, than it’s to Windows.

Application architecture includes multiprocessing, multithreading, design patterns, and so forth. Two applications are similar in architecture if they use the same design patterns to address common problems.

Auxiliary components include statically and dynamically linked libraries, subordinate processes, and so forth. Two applications are similar, for example, if they use some of the same functionality from the same libraries.

The more dimensions along which two problems are similar, the more similar the problems are as a whole. Two problems aren’t similar if they’re similar along just a single dimension.

Once you have recalled a problem that has a good deal of similarity, the obvious hypothesis is that the current problem has the same root cause as the problem you have recalled.




Debugging by Thinking. A Multidisciplinary Approach
Debugging by Thinking: A Multidisciplinary Approach (HP Technologies)
ISBN: 1555583075
EAN: 2147483647
Year: 2002
Pages: 172

Similar book on Amazon

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net