Mining temporal specifications from object usage

  • Authors:
  • Andrzej Wasylkowski;Andreas Zeller

  • Affiliations:
  • Department of Computer Science, Saarland University, Saarbrücken, Germany;Department of Computer Science, Saarland University, Saarbrücken, Germany

  • Venue:
  • Automated Software Engineering
  • Year:
  • 2011

Quantified Score

Hi-index 0.00

Visualization

Abstract

A caller must satisfy the callee's precondition--that is, reach a state in which the callee may be called. Preconditions describe the state that needs to be reached, but not how to reach it. We combine static analysis with model checking to mine Fair Computation Tree Logic (CTL F ) formulas that describe the operations a parameter goes through: "In parseProperties(String xml), the parameter xml normally stems from getProperties()." Such operational preconditions can be learned from program code, and the code can be checked for their violations. Applied to AspectJ, our Tikanga prototype found 169 violations of operational preconditions, uncovering 7 unique defects and 27 unique code smells--with 52% true positives in the 25% top-ranked violations.