AFID: An Automated Fault Identification Tool Alex Edwards Sean Tucker Sébastien Worms Rahul Vaidya Brian Demsky.

Slides:



Advertisements
Similar presentations
Week 2 DUE This Week: Safety Form and Model Release DUE Next Week: Project Timelines and Website Notebooks Lab Access SharePoint Usage Subversion Software.
Advertisements

Making the System Operational
Automatic Memory Management Noam Rinetzky Schreiber 123A /seminar/seminar1415a.html.
An Empirical Study of the Reliability in UNIX Utilities Barton Miller Lars Fredriksen Brysn So Presented by Liping Cai.
Version Control System (Sub)Version Control (SVN).
Overview of Programming and Problem Solving ROBERT REAVES.
Programming Types of Testing.
FIT FIT1002 Computer Programming Unit 19 Testing and Debugging.
Observing users Chapter 12. Observation ● Why? Get information on.. – Context, technology, interaction ● Where? – Controlled environments – In the field.
Guide to Oracle10G1 Introduction To Forms Builder Chapter 5.
Using subversion COMP 2400 Prof. Chris GauthierDickey.
A Guide to Oracle9i1 Introduction To Forms Builder Chapter 5.
©Ian Sommerville 2000Software Engineering, 6th edition. Chapter 19Slide 1 Verification and Validation l Assuring that a software system meets a user's.
CS 333 Introduction to Operating Systems Class 18 - File System Performance Jonathan Walpole Computer Science Portland State University.
SIM5102 Software Evaluation
Guide To UNIX Using Linux Third Edition
Programming Fundamentals (750113) Ch1. Problem Solving
Efficiently Sharing Common Data HTCondor Week 2015 Zach Miller Center for High Throughput Computing Department of Computer Sciences.
Copyright © 2006 by The McGraw-Hill Companies, Inc. All rights reserved. McGraw-Hill Technology Education Copyright © 2006 by The McGraw-Hill Companies,
Programming. Software is made by programmers Computers need all kinds of software, from operating systems to applications People learn how to tell the.
Chapter 18: Modifying SAS Data Sets and Tracking Changes 1 STAT 541 ©Spring 2012 Imelda Go, John Grego, Jennifer Lasecki and the University of South Carolina.
P51UST: Unix and Software Tools Unix and Software Tools (P51UST) Compilers, Interpreters and Debuggers Ruibin Bai (Room AB326) Division of Computer Science.
CLEO’s User Centric Data Access System Christopher D. Jones Cornell University.
Ext Environment Copyright © 2005 Liferay, LLC All Rights Reserved. No material may be reproduced electronically or in print without written permission.
© Janice Regan, CMPT 128, Jan CMPT 128 Introduction to Computing Science for Engineering Students Creating a program.
WorkPlace Pro Utilities.
1 AutoBash: Improving Configuration Management with Operating System Causality Analysis Ya-Yunn Su, Mona Attariyan, and Jason Flinn University of Michigan.
สาขาวิชาเทคโนโลยี สารสนเทศ คณะเทคโนโลยีสารสนเทศ และการสื่อสาร.
Scalable Statistical Bug Isolation Ben Liblit, Mayur Naik, Alice Zheng, Alex Aiken, and Michael Jordan, 2005 University of Wisconsin, Stanford University,
1 Computing Software. Programming Style Programs that are not documented internally, while they may do what is requested, can be difficult to understand.
Ext Environment Copyright © 2005 Liferay, LLC All Rights Reserved. No material may be reproduced electronically or in print without written permission.
Module 7 Reading SQL Server® 2008 R2 Execution Plans.
Programming Lifecycle
Program Development Life Cycle (PDLC)
1 The Software Development Process  Systems analysis  Systems design  Implementation  Testing  Documentation  Evaluation  Maintenance.
Automated Whitebox Fuzz Testing (NDSS 2008) Presented by: Edmund Warner University of Central Florida April 7, 2011 David Molnar UC Berkeley
CERN IT Department CH-1211 Genève 23 Switzerland t Internet Services Job Monitoring for the LHC experiments Irina Sidorova (CERN, JINR) on.
Python From the book “Think Python”
CSC 230: C and Software Tools Rudra Dutta Computer Science Department Course Introduction.
DEBUGGING. BUG A software bug is an error, flaw, failure, or fault in a computer program or system that causes it to produce an incorrect or unexpected.
Homework #1 J. H. Wang Oct. 5, 2015.
TEST-1 6. Testing & Refactoring. TEST-2 How we create classes? We think about what a class must do We focus on its implementation We write fields We write.
1 Chapter 3 Syntax, Errors, and Debugging Fundamentals of Java: AP Computer Science Essentials, 4th Edition Lambert / Osborne.
The Software Development Process
Celluloid An interactive media sequencing language.
Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University IWPSE 2003 Program.
CISC Machine Learning for Solving Systems Problems Presented by: Suman Chander B Dept of Computer & Information Sciences University of Delaware Automatic.
CS333 Intro to Operating Systems Jonathan Walpole.
Computer and Programming. Computer Basics: Outline Hardware and Memory Programs Programming Languages and Compilers.
Dynamic Taint Analysis for Automatic Detection, Analysis, and Signature Generation of Exploits on Commodity Software Paper by: James Newsome and Dawn Song.
Installing Java on a Home machine For Windows Users: Download/Install: Go to downloads html.
CompSci 100E 18.1 Testing and Debugging Robert A Wagner.
1 The Software Development Process ► Systems analysis ► Systems design ► Implementation ► Testing ► Documentation ► Evaluation ► Maintenance.
The Development Process Compilation. Compilation - Dr. Craig A. Struble 2 Programming Process Problem Solving Phase We will spend significant time on.
Evolution of C and C++ n C was developed by Dennis Ritchie at Bell Labs (early 1970s) as a systems programming language n C later evolved into a general-purpose.
GC Assertions: Using the Garbage Collector To Check Heap Properties Samuel Z. Guyer Tufts University Edward Aftandilian Tufts University.
PROGRAMMING FUNDAMENTALS INTRODUCTION TO PROGRAMMING. Computer Programming Concepts. Flowchart. Structured Programming Design. Implementation Documentation.
Testing Programs with Loops CSIS 1595: Fundamentals of Programming and Problem Solving 1.
Introduction to Computer Programming Concepts M. Uyguroğlu R. Uyguroğlu.
CopperDroid Logan Horton. Android - Background Android is complicated to analyse due to having 2 places to check for code execution Normally, code is.
Visit for more Learning Resources
Testing Tutorial 7.
Designing and Debugging Batch and Interactive COBOL Programs
Social Media And Global Computing Introduction to Visual Studio
Programming Fundamentals (750113) Ch1. Problem Solving
Programming Fundamentals (750113) Ch1. Problem Solving
Programming Fundamentals (750113) Ch1. Problem Solving
Event loops.
SPL – PS1 Introduction to C++.
CHAPTER 6 Testing and Debugging.
Presentation transcript:

AFID: An Automated Fault Identification Tool Alex Edwards Sean Tucker Sébastien Worms Rahul Vaidya Brian Demsky

Motivation Much research focuses on software bugs Relatively little emphasis on empirical methods as compared to other fields Remarkably few software fault data sets are publically available that Are uniformly structured Contain faulty source code Contain fault correction Contain fault revealing test case Lack of data sets affects how we approach research

Effects Guide research based on General impressions of important bug classes Are these the important bug classes? What are we missing? Often evaluate our research on Hand selected bugs Synthetic bugs Difficult to study dynamic properties of software bugs

Manual Collection Colleagues tried to get students to manually record their software faults Asked them to record: Test case that revealed fault Copy of the source code with the fault Copy of the change that removed the fault Limited success Tedious Often forgot

Goal Automatically record repositories of real software bugs Minimize developer involvement Okay to miss software faults

Basic Approach Obtain fault revealing test cases Monitor source code for changes Use fault revealing test cases to detect fault corrections When correction is detected, record Fault revealing test case Faulty version Fault correcting source code change

Obtaining Fault Revealing Test Cases Wait for developer to execute program Record information about program interactions with the operating system If it crashes, build test case from the recorded information Record Command line Files accessed Console interactions

Recording Interactions Application Operating System System Calls

Recording Interactions Application Operating System System Calls Monitor Ptrace

Ptrace Monitoring Open call for read access Record file name (and copy later if the program crashes) Open call for write access Record file name and copy file Console input Record user input Console output Record program prompting

Extraneous files Programs read many files that would not be considered input Java programs read libraries, class files, JVM components C programs read shared libraries Such files are not interesting for the test case make the test case huge make the test case less portable

Remove Extraneous Files Can filter files Create a test program that does nothing Record what files are read Exclude those files Use patterns to guess other files to exclude Exclude class files Exclude library directories User can use regular expressions to exclude other files (or include files)

Duplicate Test Cases Developers often rerun test cases Results in multiple copies of same test case Use hashing to avoid making multiple copies of test cases Optimize for performance, ignore possibility of hash collisions

Console Input Problem: Want to support user interactions Challenge: Would like to reuse test case in the presence of small modification Approach: Record transcript of user interactions Compute for each user response, the shortest suffix of the output that uniquely identifies when the input occurred Generate transcript using these suffixes and the user inputs Provides flexibility to some prompt changes

Monitoring Source Code Changes Want to detect changes in source files Need to know which files comprise an application Goals: Want to avoid input from developer Should work with any tool chain

Approach Use same ptrace-based monitoring infrastructure on the compiler Detect files when the compiler reads them Use wildcards to identify source files

Monitoring Source Changes Build internal SVN repository Add new files automatically as detected Check in updates at every compile

Detecting Fault Correcting Changes Test cases can be used to detect which code changes correct which faults For each code change, we rerun outstanding test cases to see if they still crash

Replaying Test Cases Could just copy test case files back to their original locations Huge downsides Developer may have written important data in new versions of these files File system may have different directory structure Execution could overwrite important data Need to sandbox execution

Sandboxing Make a copy of the test case Replay program in ptrace-based sandbox Use ptrace to intercept file open commands Use ptrace to replace open call’s file names with our copies Intercept console I/O interactions to replay user interactions Technical details in the paper

Looping Source code changes can cause formerly crashing test cases to loop Solution: Record elapsed time for every execution of application Estimate upper bound on execution time Terminate replays once they exceed this bound Okay to be wrong - just miss recording a fault

Central Repository When fault correcting change is detected, AFID uploads information to repository server Information contains: Buggy source code SVN repository Fault correcting change Fault revealing test case

Overhead Measurements Jasmin byte code assembler 11,450 lines of code I/O intensive benchmark Inyo ray tracer 5,843 lines of code Longer running, compute bound benchmark Measured on 2.2 GHz Core 2 Duo, 1GB RAM, Debian HotSpot JVM version 1.5.0

Overheads JasminInyo Normal compile1.07 s0.77 s Monitored compile w/ svn4.32 s3.54 s Monitored compile w/o svn1.40 s0.95 s Normal execution0.22 s31.88 s Monitored execution0.47 s32.64 s

Case Study Goal: To determine whether AFID effectively records real software faults 8 participants Each participant Solved a programming contest problem Used AFID while coding

Fault Breakdown Fault TypeCount Parsing logic error3 Null pointer dereference3 Initialization error2 Missing condition check1 Loop bound error1 Shadowed field1 Incorrect comparison1

Fault Counts by Participant Participant# Recorded Faults # Verified Corrections A22 B11 C42 D85 E11 F11 G00 H00

Lessons Some participants debugged by commenting out code Cause AFID to detect the wrong fault correcting change Modified AFID to ask when it detects a fault correcting change Source code changes can cause applications to loop instead of crash Execution time estimator

Participant feedback Found the user experience very good In general, tool was unnoticeable Noticed slight delay when compiling

Privacy Concerns AFID records all source code changes and test inputs that crash the program Could easily record personal information Limit use of AFID to projects that are not likely to process personal information Print out message to remind user that AFID is running

Related Work Mining CVS Repositories Software-artifact Infrastructure Repository iBUGS Replay systems

Conclusion Next phase is data collection Plan to make data available to other researchers We need participants Please go to