Showing posts with label Taxonomy of Bugs. Show all posts
Showing posts with label Taxonomy of Bugs. Show all posts

Saturday, July 10, 2010

The Taxonomy of Bugs

The Importance of bugs:

The importance of bug depends on frequency, correction cost, installation cost, and consequences.

A reasonable metric for bug importance is

Importance($) = frequency * (correction_cost + installation_cost + consequential_cost)

Structural Bugs:

Control and Sequence Bugs

Control and sequence include paths left out, unreachable code, improper nesting of loops, loop-back or loop termination criteria incorrect missing process steps, duplicate processing, unnecessary processing, rampaging GOTO's, ill-conceived switches, spaghetti code and worst of all, pachinko code.

Logic Bugs:

Bugs in logic, especially those related to misunderstanding how case statements and logic operators behave singly and in combinations, include nonexistent cases, improper layout of cases.

Processing bugs:

Processing bugs include arithmetic bugs, algebraic, mathematical function evaluation, algorithm selection, and general processing. Many problems in this area are related to incorrect conversion from one data representation to another.

Initialization bugs:

Initialization bugs are common, and experienced programmers and testers muck look for them.

Typical Initialization bugs are as follows : forgetting to initialize working space, registers, or data areas before first use or assuming that they are initialized elsewhere; a bug in the first value of a loop-control parameter; accepting an initial value without a validation check.

Data bugs:

Data bugs include all bugs that arise from the specification of data objects, their formats, the number of such objects, and their initial values.

Contents, Structure, and Attributes:

Data specification consists of three pars:

Contents: - The actual bit pattern character string, or number put into a data structure. Content is a pure bit pattern and has no meaning unless it is being interpreted by a hardware or software processor.

Structure: - The size and shape and numbers that describe the data object, that is, the memory locations used to store the content.

Attributes: - The specification of meaning, that is, the semantics associated with the contents of data object.