Automated debugging based on a constraint model of the program and a test case

Abstract Debugging, i.e., fault localization, in case of a detected failure is a time consuming and intricate task. The automation or at least partial automation of debugging is therefore highly desired. In this paper, we discuss some of the most recent approaches for debugging namely spectrum-based, slicing-based, and model-based debugging. We focus on the latter, and introduce the underlying theory as well as discuss empirical results obtained from our implementation. The model-based approach we present in this paper relies on a constraint representation of a program that is equivalent to the original program in terms of the input-output behavior under some reasonable assumptions. By using constraints for representing programs and subsequently test cases we are able to state the debugging problem as a constraint satisfaction problem that can be effectively solved using a todays constraint solver. The given empirical results indicate that the approach can be used for debugging smaller programs in less than 1 s. Moreover, we briefly compare the three approaches and suggest a combination of them in order to improve the results and the overall necessary running time.

[1]  Markus Stumptner,et al.  Towards an Integrated Debugging Environment , 2002, ECAI.

[2]  Shinji Kusumoto,et al.  Experimental Evaluation of Program Slicing for Fault Localization , 2002, Empirical Software Engineering.

[3]  H. Cleve,et al.  Locating causes of program failures , 2005, Proceedings. 27th International Conference on Software Engineering, 2005. ICSE 2005..

[4]  Daniel Jackson,et al.  Software Abstractions - Logic, Language, and Analysis , 2006 .

[5]  A.J.C. van Gemund,et al.  On the Accuracy of Spectrum-based Fault Localization , 2007, Testing: Academic and Industrial Conference Practice and Research Techniques - MUTATION (TAICPART-MUTATION 2007).

[6]  Mariam Kamkar,et al.  An overview and comparative classification of program slicing techniques , 1995, J. Syst. Softw..

[7]  Ehud Shapiro,et al.  Algorithmic Program Debugging , 1983 .

[8]  Gregg Rothermel,et al.  Empirical Studies of a Safe Regression Test Selection Technique , 1998, IEEE Trans. Software Eng..

[9]  Claire Le Goues,et al.  Automatically finding patches using genetic programming , 2009, 2009 IEEE 31st International Conference on Software Engineering.

[10]  Mary Jean Harrold,et al.  Empirical evaluation of the tarantula automatic fault-localization technique , 2005, ASE.

[11]  Arnaud Gotlieb,et al.  Automatic test data generation using constraint solving techniques , 1998, ISSTA '98.

[12]  Raymond Reiter,et al.  A Theory of Diagnosis from First Principles , 1986, Artif. Intell..

[13]  Xiangyu Zhang,et al.  Locating faulty code using failure-inducing chops , 2005, ASE.

[14]  Mark Weiser,et al.  Programmers use slices when debugging , 1982, CACM.

[15]  Mark N. Wegman,et al.  Efficiently computing static single assignment form and the control dependence graph , 1991, TOPL.

[16]  Markus Stumptner,et al.  Model-Based Diagnosis of Hardware Designs , 1999, Artif. Intell..

[17]  Matthew B. Dwyer,et al.  Evaluating the Effectiveness of Slicing for Model Reduction of Concurrent Object-Oriented Programs , 2006, TACAS.

[18]  Andreas Zeller,et al.  Simplifying and Isolating Failure-Inducing Input , 2002, IEEE Trans. Software Eng..

[19]  Frank Tip,et al.  A survey of program slicing techniques , 1994, J. Program. Lang..

[20]  Daniele Theseider Dupré,et al.  Model-Based Diagnosis Meets Error Diagnosis in Logic Programs (Extended Abstract) , 1993, AADEBUG.

[21]  Franz Wotawa,et al.  Bridging the Gap Between Slicing and Model-based Diagnosis , 2008, SEKE.

[22]  Franz Wotawa,et al.  How to debug sequential code by means of constraint representation , 2008 .

[23]  Ian P. Gent,et al.  Minion: A Fast Scalable Constraint Solver , 2006, ECAI.

[24]  Peter Zoeteweij,et al.  Spectrum-Based Multiple Fault Localization , 2009, 2009 IEEE/ACM International Conference on Automated Software Engineering.

[25]  Hélène Collavizza,et al.  Exploring Different Constraint-Based Modelings for Program Verification , 2007, CP.

[26]  Markus Stumptner,et al.  Model-Based Debugging using Multiple Abstract Models , 2003, ArXiv.

[27]  Peter Zoeteweij,et al.  An observation-based model for fault localization , 2008, WODA.

[28]  Gregory William Bond Logic programs for consistency-based diagnosis , 1994 .

[29]  W. Mayer,et al.  Prioritising Model-Based Debugging Diagnostic Reports , 2008 .

[30]  Eugene H. Spafford,et al.  Critical slicing for software fault localization , 1996, ISSTA '96.

[31]  Franz Wotawa,et al.  On the relationship between model-based debugging and program slicing , 2002, Artif. Intell..

[32]  Rafael M. Gasca,et al.  Diagnosing Errors in DbC Programs Using Constraint Programming , 2005, CAEPIA.

[33]  Mariam Kamkar Application of program slicing in algorithmic debugging , 1998, Inf. Softw. Technol..

[34]  Jens Krinke,et al.  Advanced slicing of sequential and concurrent programs , 2003, 20th IEEE International Conference on Software Maintenance, 2004. Proceedings..

[35]  Jan Tretmans,et al.  Test Generation with Inputs, Outputs and Repetitive Quiescence , 1996, Softw. Concepts Tools.

[36]  Andy Podgurski,et al.  The Probabilistic Program Dependence Graph and Its Application to Fault Diagnosis , 2008, IEEE Transactions on Software Engineering.

[37]  Mark Harman,et al.  A survey of empirical results on program slicing , 2004, Adv. Comput..

[38]  Hanspeter Mössenböck,et al.  Single-pass generation of static single-assignment form for structured languages , 1994, TOPL.

[39]  Rina Dechter,et al.  Constraint Processing , 1995, Lecture Notes in Computer Science.

[40]  Franz Wotawa Debugging Hardware Designs Using a Value-Based Model , 2004, Applied Intelligence.

[41]  Andreas Zeller,et al.  Isolating cause-effect chains from computer programs , 2002, SIGSOFT FSE.

[42]  Mark Weiser,et al.  Program Slicing , 1981, IEEE Transactions on Software Engineering.

[43]  Markus Stumptner,et al.  Debugging Functional Programs , 1999, IJCAI.

[44]  Gregor Snelting,et al.  Validation of measurement software as an application of slicing and constraint solving , 1998, Inf. Softw. Technol..

[45]  Xiangyu Zhang,et al.  Experimental evaluation of using dynamic slices for fault location , 2005, AADEBUG'05.

[46]  Janusz W. Laski,et al.  Dynamic Program Slicing , 1988, Inf. Process. Lett..

[47]  Franz Wotawa,et al.  On the Compilation of Programs into their Equivalent Constraint Representation , 2008, Informatica.

[48]  Daniele Theseider Dupré,et al.  Model-Based Diagnosis Meets Error Diagnosis in Logic Programs , 1993, IJCAI.

[49]  Franz Wotawa,et al.  Debugging VHDL designs using model-based reasoning , 2000, Artif. Intell. Eng..