Explaining inconsistent code

Martin Schäf, Daniel Schwartz-Narbonne, Thomas Wies

Research output: Chapter in Book/Report/Conference proceedingConference contribution

Abstract

A code fragment is inconsistent if it is not part of any normally terminating execution. Examples of such inconsistencies include code that is unreachable, code that always fails due to a run-time error, and code that makes conflicting assumptions about the program state. In this paper, we consider the problem of automatically explaining inconsistent code. This problem is difficult because traditional fault localization techniques do not apply. Our solution relies on a novel algorithm that takes an infeasible code fragment as input and generates a so-called error invariant automaton. The error invariant automaton is an abstraction of the input code fragment that only mentions program statements and facts that are relevant for understanding the cause of the inconsistency. We conducted a preliminary usability study which demonstrated that error invariant automata can help programmers better understand inconsistencies in code taken from real-world programs. In particular, access to an error invariant automata tripled the speed at which programmers could diagnose the cause of a code inconsistency.

Original languageEnglish (US)
Title of host publication2013 9th Joint Meeting of the European Software Engineering Conference and the ACM SIGSOFT Symposium on the Foundations of Software Engineering, ESEC/FSE 2013 - Proceedings
Pages521-531
Number of pages11
DOIs
StatePublished - 2013
Event2013 9th Joint Meeting of the European Software Engineering Conference and the ACM SIGSOFT Symposium on the Foundations of Software Engineering, ESEC/FSE 2013 - Saint Petersburg, Russian Federation
Duration: Aug 18 2013Aug 26 2013

Other

Other2013 9th Joint Meeting of the European Software Engineering Conference and the ACM SIGSOFT Symposium on the Foundations of Software Engineering, ESEC/FSE 2013
CountryRussian Federation
CitySaint Petersburg
Period8/18/138/26/13

Keywords

  • Craig interpolation
  • Error detection
  • Fault localization
  • Inconsistent code
  • Static analysis

ASJC Scopus subject areas

  • Software

Cite this

Schäf, M., Schwartz-Narbonne, D., & Wies, T. (2013). Explaining inconsistent code. In 2013 9th Joint Meeting of the European Software Engineering Conference and the ACM SIGSOFT Symposium on the Foundations of Software Engineering, ESEC/FSE 2013 - Proceedings (pp. 521-531) https://doi.org/10.1145/2491411.2491448

Explaining inconsistent code. / Schäf, Martin; Schwartz-Narbonne, Daniel; Wies, Thomas.

2013 9th Joint Meeting of the European Software Engineering Conference and the ACM SIGSOFT Symposium on the Foundations of Software Engineering, ESEC/FSE 2013 - Proceedings. 2013. p. 521-531.

Research output: Chapter in Book/Report/Conference proceedingConference contribution

Schäf, M, Schwartz-Narbonne, D & Wies, T 2013, Explaining inconsistent code. in 2013 9th Joint Meeting of the European Software Engineering Conference and the ACM SIGSOFT Symposium on the Foundations of Software Engineering, ESEC/FSE 2013 - Proceedings. pp. 521-531, 2013 9th Joint Meeting of the European Software Engineering Conference and the ACM SIGSOFT Symposium on the Foundations of Software Engineering, ESEC/FSE 2013, Saint Petersburg, Russian Federation, 8/18/13. https://doi.org/10.1145/2491411.2491448
Schäf M, Schwartz-Narbonne D, Wies T. Explaining inconsistent code. In 2013 9th Joint Meeting of the European Software Engineering Conference and the ACM SIGSOFT Symposium on the Foundations of Software Engineering, ESEC/FSE 2013 - Proceedings. 2013. p. 521-531 https://doi.org/10.1145/2491411.2491448
Schäf, Martin ; Schwartz-Narbonne, Daniel ; Wies, Thomas. / Explaining inconsistent code. 2013 9th Joint Meeting of the European Software Engineering Conference and the ACM SIGSOFT Symposium on the Foundations of Software Engineering, ESEC/FSE 2013 - Proceedings. 2013. pp. 521-531
@inproceedings{bca30bb80eec4c66a840fbd2842e4975,
title = "Explaining inconsistent code",
abstract = "A code fragment is inconsistent if it is not part of any normally terminating execution. Examples of such inconsistencies include code that is unreachable, code that always fails due to a run-time error, and code that makes conflicting assumptions about the program state. In this paper, we consider the problem of automatically explaining inconsistent code. This problem is difficult because traditional fault localization techniques do not apply. Our solution relies on a novel algorithm that takes an infeasible code fragment as input and generates a so-called error invariant automaton. The error invariant automaton is an abstraction of the input code fragment that only mentions program statements and facts that are relevant for understanding the cause of the inconsistency. We conducted a preliminary usability study which demonstrated that error invariant automata can help programmers better understand inconsistencies in code taken from real-world programs. In particular, access to an error invariant automata tripled the speed at which programmers could diagnose the cause of a code inconsistency.",
keywords = "Craig interpolation, Error detection, Fault localization, Inconsistent code, Static analysis",
author = "Martin Sch{\"a}f and Daniel Schwartz-Narbonne and Thomas Wies",
year = "2013",
doi = "10.1145/2491411.2491448",
language = "English (US)",
isbn = "9781450322379",
pages = "521--531",
booktitle = "2013 9th Joint Meeting of the European Software Engineering Conference and the ACM SIGSOFT Symposium on the Foundations of Software Engineering, ESEC/FSE 2013 - Proceedings",

}

TY - GEN

T1 - Explaining inconsistent code

AU - Schäf, Martin

AU - Schwartz-Narbonne, Daniel

AU - Wies, Thomas

PY - 2013

Y1 - 2013

N2 - A code fragment is inconsistent if it is not part of any normally terminating execution. Examples of such inconsistencies include code that is unreachable, code that always fails due to a run-time error, and code that makes conflicting assumptions about the program state. In this paper, we consider the problem of automatically explaining inconsistent code. This problem is difficult because traditional fault localization techniques do not apply. Our solution relies on a novel algorithm that takes an infeasible code fragment as input and generates a so-called error invariant automaton. The error invariant automaton is an abstraction of the input code fragment that only mentions program statements and facts that are relevant for understanding the cause of the inconsistency. We conducted a preliminary usability study which demonstrated that error invariant automata can help programmers better understand inconsistencies in code taken from real-world programs. In particular, access to an error invariant automata tripled the speed at which programmers could diagnose the cause of a code inconsistency.

AB - A code fragment is inconsistent if it is not part of any normally terminating execution. Examples of such inconsistencies include code that is unreachable, code that always fails due to a run-time error, and code that makes conflicting assumptions about the program state. In this paper, we consider the problem of automatically explaining inconsistent code. This problem is difficult because traditional fault localization techniques do not apply. Our solution relies on a novel algorithm that takes an infeasible code fragment as input and generates a so-called error invariant automaton. The error invariant automaton is an abstraction of the input code fragment that only mentions program statements and facts that are relevant for understanding the cause of the inconsistency. We conducted a preliminary usability study which demonstrated that error invariant automata can help programmers better understand inconsistencies in code taken from real-world programs. In particular, access to an error invariant automata tripled the speed at which programmers could diagnose the cause of a code inconsistency.

KW - Craig interpolation

KW - Error detection

KW - Fault localization

KW - Inconsistent code

KW - Static analysis

UR - http://www.scopus.com/inward/record.url?scp=84883733530&partnerID=8YFLogxK

UR - http://www.scopus.com/inward/citedby.url?scp=84883733530&partnerID=8YFLogxK

U2 - 10.1145/2491411.2491448

DO - 10.1145/2491411.2491448

M3 - Conference contribution

AN - SCOPUS:84883733530

SN - 9781450322379

SP - 521

EP - 531

BT - 2013 9th Joint Meeting of the European Software Engineering Conference and the ACM SIGSOFT Symposium on the Foundations of Software Engineering, ESEC/FSE 2013 - Proceedings

ER -