1 Perracotta: Mining Temporal API Rules from Imperfect Traces Jinlin Yang David Evans Deepali Bhardwaj Thirumalesh Bhat Manuvir Das.

Slides:



Advertisements
Similar presentations
Testing Relational Database
Advertisements

ARCHITECTURES FOR ARTIFICIAL INTELLIGENCE SYSTEMS
Analysis of : Operator Scheduling in a Data Stream Manager CS561 – Advanced Database Systems By Eric Bloom.
ECE 720T5 Fall 2012 Cyber-Physical Systems Rodolfo Pellizzoni.
Learning Objectives Explain similarities and differences among algorithms, programs, and heuristic solutions List the five essential properties of an algorithm.
Chapter 6: Design of Expert Systems
Algorithms and Problem Solving-1 Algorithms and Problem Solving.
Turning Eclipse Against Itself: Finding Errors in Eclipse Sources Benjamin Livshits Stanford University.
Algorithms and Problem Solving. Learn about problem solving skills Explore the algorithmic approach for problem solving Learn about algorithm development.
1 Lecture 7 Halting Problem –Fundamental program behavior problem –A specific unsolvable problem –Diagonalization technique revisited Proof more complex.
Chapter 3 Deadlocks 3.1. Resource 3.2. Introduction to deadlocks
1 Lecture 7 Halting Problem –Fundamental program behavior problem –A specific unsolvable problem –Diagonalization technique revisited Proof more complex.
Automatically Extracting and Verifying Design Patterns in Java Code James Norris Ruchika Agrawal Computer Science Department Stanford University {jcn,
Creating Architectural Descriptions. Outline Standardizing architectural descriptions: The IEEE has published, “Recommended Practice for Architectural.
Validating and Improving Test-Case Effectiveness Author: Yuri Chernak Presenter: Lam, Man Tat.
CS350/550 Software Engineering Lecture 1. Class Work The main part of the class is a practical software engineering project, in teams of 3-5 people There.
Ken Bayer, Josh Snyder, and Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln A Constraint-Based Approach to Solving Minesweeper.
CSC 395 – Software Engineering Lecture 21: Overview of the Term & What Goes in a Data Dictionary.
University of California San Diego Locality Phase Prediction Xipeng Shen, Yutao Zhong, Chen Ding Computer Science Department, University of Rochester Class.
1 Inferring Specifications A kind of review. 2 The Problem Most programs do not have specifications Those that do often fail to preserve the consistency.
/* iComment: Bugs or Bad Comments? */
C++ fundamentals.
Template for the Storyboard stage. General Instructions: The template shown is an example. You can add more slides if required. Include images for explaining.
FLOWFOX A WEB BROWSER WITH FLEXIBLE AND PRECISE INFORMATION CONTROL.
Impact Analysis of Database Schema Changes Andy Maule, Wolfgang Emmerich and David S. Rosenblum London Software Systems Dept. of Computer Science, University.
Design Patterns Discussion of pages: xi-11 Sections: Preface, Forward, Chapter
Systems Analysis – Analyzing Requirements.  Analyzing requirement stage identifies user information needs and new systems requirements  IS dev team.
C++ Object Oriented 1. Class and Object The main purpose of C++ programming is to add object orientation to the C programming language and classes are.
ECE 720T5 Winter 2014 Cyber-Physical Systems Rodolfo Pellizzoni.
Mining Windows Kernel API Rules Jinlin Yang 09/28/2005CS696.
Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University 1 Refactoring.
SOFTWARE ENGINEERING1 Introduction. Software Software (IEEE): collection of programs, procedures, rules, and associated documentation and data SOFTWARE.
Automatically Inferring Temporal Properties for Program Evolution Jinlin Yang and David Evans 15 th IEEE International Symposium on Software Reliability.
5.1 Advanced Operating Systems Operating Systems Bugs Linux's code has been significantly growing during last years. Is this code bugs free? Obviously.
CSC-682 Cryptography & Computer Security Sound and Precise Analysis of Web Applications for Injection Vulnerabilities Pompi Rotaru Based on an article.
CNIT 133 Interactive Web Pags – JavaScript and AJAX Advanced topic - variable.
Lecturer: Gareth Jones. How does a relational database organise data? What are the principles of a database management system? What are the principal.
Reliable Communication in the Presence of Failures Based on the paper by: Kenneth Birman and Thomas A. Joseph Cesar Talledo COEN 317 Fall 05.
The Daikon system for dynamic detection of likely invariants MIT Computer Science and Artificial Intelligence Lab. 16 January 2007 Presented by Chervet.
Today’s Agenda  HW #1  Finish Introduction  Input Space Partitioning Software Testing and Maintenance 1.
1 Deadlocks Chapter Resource 3.2. Introduction to deadlocks 3.3. The ostrich algorithm 3.4. Deadlock detection and recovery 3.5. Deadlock avoidance.
GUI Design Spreadsheet-Based Decision Support Systems Chapter 23: Aslı Sencer MIS 463.
Presented by: Ashgan Fararooy Referenced Papers and Related Work on:
Overview Concept Learning Representation Inductive Learning Hypothesis
Mining Version Histories to Guide Software Changes Thomas Zimmerman Peter Weisgerber Stephan Diehl Andreas Zeller.
1 Test Selection for Result Inspection via Mining Predicate Rules Wujie Zheng
Glenn Ammons Ras Bodík Jim Larus Univ. of Wisconsin Univ. of Wisconsin Microsoft Research Mining Specifications (lots of) code  specifications.
Implementing Subprograms What actions must take place when subprograms are called and when they terminate? –calling a subprogram has several associated.
Basic Principles of Economics Rögnvaldur J. Sæmundsson January
Design - programming Cmpe 450 Fall Dynamic Analysis Software quality Design carefully from the start Simple and clean Fewer errors Finding errors.
Chapter 1: Fundamental of Testing Systems Testing & Evaluation (MNN1063)
© 2006 Pearson Addison-Wesley. All rights reserved 2-1 Chapter 2 Principles of Programming & Software Engineering.
Chapter 8 Testing. Principles of Object-Oriented Testing Å Object-oriented systems are built out of two or more interrelated objects Å Determining the.
Virtual Application Profiler (VAPP) Problem – Increasing hardware complexity – Programmers need to understand interactions between architecture and their.
END OF KEY STAGE TESTS SUMMER TERM 2016.
Refactoring Agile Development Project. Lecture roadmap Refactoring Some issues to address when coding.
Unit – I Presentation. Unit – 1 (Introduction to Software Project management) Definition:-  Software project management is the art and science of planning.
CS223: Software Engineering Lecture 25: Software Testing.
CSE 143 Lecture 13 Inheritance slides created by Ethan Apter
Algorithms and Problem Solving
A template for describing behaviour change theories
Effective Data-Race Detection for the Kernel
Chapter 6: Design of Expert Systems
Lecture 2 of Computer Science II
Lecture Software Process Definition and Management Chapter 3: Descriptive Process Models Dr. Jürgen Münch Fall
Threads Chapter 4.
Algorithms and Problem Solving
Software Requirements Specification (SRS) Template.
SPL – PS3 C++ Classes.
Presentation transcript:

1 Perracotta: Mining Temporal API Rules from Imperfect Traces Jinlin Yang David Evans Deepali Bhardwaj Thirumalesh Bhat Manuvir Das

2 Agenda Background Perracotta Approximate Inference Contextual Properties Chaining Results Critique

3 Background Software tasks require specifications. What are the intended behaviors of the program? Expected outputs are necessary for testing. What aspects can be modified during maintenance of software? etc. The problem: Many programs don't provide precise specifications. Many implementations are not consistent with specifications. As maintenance continues, specifications become increasingly incorrect. So? Several researchers have been motivated to study the problem of specification inference.

4 Background (2)‏ Previous work: Proposed an approach to dynamically infer temporal properties of programs. “...dynamically?” To infer specifications by analysing sample execution traces of a program. “...temporal properties”?...deal with the order of occurrence of program events. ex) Property: acquiring a lock should eventually be followed by a release of the lock. This paper addresses only inference of Alternating Properties, because “It's the strictest of the template patterns and has proven the most useful in practice.” ex) If A and B are events specified to behave according to the Alternating Property, “ABABAB”, not “ABABBAAB”.

5 Background (3)‏ Current limitations: Inference algorithms scale poorly with the size of the program and input trace. Inferred properties only worked for perfect traces....in other words, there was an assumption that the implementations of the traced programs were correct. Many of the inferred properties are uninteresting; since uninteresting properties add up, this makes it unfeasible for large programs.

6 Background (4)‏ Quick summary of background: Specifications tend to be inconsistent with implementations. Researchers have developed techniques to dynamically infer specification properties of programs....however they suffer three notable limitations: These techniques only work with small programs The techniques cannot detect specifications from inconsistent implementations. Many of the inferred properties are uninteresting “noise”. Contributions of this paper/Perracotta: Address the above problems.

7 Perracotta Contributions: Approximate Inference Makes it possible to infer a specification from an implementation that is not always consistent with that specification Contextual Properties Allows for more precise inferences by keeping track of contextual data instead of mere static behaviors Selection Heuristics Filters out the uninteresting properties, thus greatly reducing the amount of “noise” from the inferred properties.

8 Approximate Inference Imperfect traces: It is expected that allocated memory will be freed eventually, to avoid memory leak. Unfortunately even skilled programmers fail to be consistent with this temporal property, especially in complex code. A sample execution trace that is not consistent with this property is an example of an “imperfect trace”. Previous algorithms failed to associate/infer properties from imperfect traces, thus ruining the whole point of dynamic inference. Approximate Inference: Infers a specification from an implementation, even if the implementation is bugged with respect to that specification

9 Approximate Inference (2)‏ “STSTSTSTSTSSS” Events (functions) S and T are called multiple times in a trace. They alternate n times, but there is no alternation in last three S's. Will Perracotta (successfully) infer the Alternating Property from this? Perracotta's approach: Partition the trace: [S,T][S,T][S,T][S,T][S,T][SSS] Number of alternations = 4 Number of total partitions = 5 Satisfaction rate of Alternating Property = 4/5 The higher the satisfaction rate, the more likely it is to infer. The lower the predefined threshold value, the more likely it is to infer.

10 Contextual Properties “An acquired lock should eventually be released.” But what if there are multiple locks? Context-neutral: “a lock was acquired” Context-sensitive: “Lock#1 was acquired” Without context, the inference tool will treat all locks as if they are the same lock, thus not being able to infer anything about lock behavior.

11 Selection Heuristics Goal: reduce the number of uninteresting properties ex) “There is always a printf() before a readLine() prompt”. Infers nothing about API specifications - uninteresting. Reachability: Events with call relationships are less interesting than ones without.

12 Selection Heuristics (2)‏ Name Similarities Functions with similar names are likely to be associated with interesting inferences. ex) ExAcquireFastMutexUnsafe vs ExReleaseFastMutexUnsafe Chaining: Suppose A->B, B->C, and A->C, that is, A and B have Alternating Property, as to BC and AC. There are three inferences. It is correct to chain them into a single inference – ABC....thus reducing the number of inferences from 3 to 1, reducing “noise”.

13 Results Test Programs: Daisy JBoss Windows Kernel APIs

14 Results (2)‏

15 Critique Likes: The scope of the paper was narrowed down to the Alternating Property. It tackled problems worth solving in the field of Dynamic Inference. Actually detected a major bug in Windows. Dislikes: Definitions of important keywords were all over the place in the paper. It's not very clear how they got the algorithm to work with large programs. The “Approach” section was actually merely the approach for the previous work, not the current one. There was no explicit label to clarify where the overview of Perracotta starts.