what is debugging in computer programming:Csmates.com

Debugging and it's types


Software testing is a process that can be systematically planed and specified. Test design can be conducted, a strategy can be defined, and results can be evaluated against prescribed expectations.

Debugging occurs as a consequence of successful testing. When a test case monitors an error, debugging is the process that used to remove such types of errors.

Debugging is not an testing but it always occurs as a consequence of testing. The debugging process begins with the execution of test case. Debugging is also treated an art (Bradly 1985). The debugging process is illustrated in that figure.

The debugging process attempts to match symptoms with cause, thereby leading to error correction. There are two outcomes of this debugging.

Debugging Techniques

Here are 7 types of debugging techniques 
  • Brute Force Testing
  • Backtracking Testing
  • Debugging by Induction
  • Debugging by Deduction
  • Cause Elimination Debugging
  • Debugging by Testing
  • Debugging by Program Slicing

Brute Force Debugging

Brute Force Debugging  methods are applied when all else fails, Brute force debugging is debugging with a storage dump.

Brute Force Debugging is the most and common using debugging technique but also the least efficient one. In this technique, the program is loaded with print statement to print the intermediate values with the hope that some of the printed value will help to identify the statement with error. 

Peoples who use thinking rather than a set of helps, exhibit superior performance. This approach becomes more systematic with the user of a symbolic debugger because values of different variables can be easily examined.

Backtracking Debugging

It is an fairly using debugging technique. This involves backtracking the incorrect results through the logic of the program. In this technique the source code is traced backwards until the error is discovered. 
This technique becomes unfit when the number of source lines to be traced back increases and the number of potential backward paths becomes unmanageable.

Debugging by Induction

This is the process that locates the data, organizes it and devices a hypothesis. This hypothesis must be proved. A clue structure may be used for what, where,  when and to what extent for categories for Is and Is not

Debugging by Deduction

Deduction may also be used as a debugging technique. Determine the possible causes and use data to eliminate cause. Refine the remaining cause into a hypothesis and prove it.

Cause Elimination Debugging 

In this technique, a list of causes that could have contributed to the error symptom is prepared and test are carried out to eliminate each cause. Software fault tree analysis technique may be used to identify the errors and these error symptom. 

Debugging by Testing

This debugging type involves using test cases. There are two type of test cases.
  • Cause that expose a previously undetected error.
  • And cause that provide useful information in debugging to locate an error.
For an undetected error cases tend to cover many conditions per test case. But these test cases for locating a specific error cover a single condition for each test case.

Debugging by Program Slicing

This debugging technique is mostly similar to backtracking . In this the overall search space is first divided in the program slices so that the search is confined to the program slice only.

A program slice is an particular variable at a particular statement is a set of source code lines preceding the statement that can influence the value of that variable.

Post a comment