Automatically Finding Patches Using Genetic Programming
|
|
- Melanie Doyle
- 5 years ago
- Views:
Transcription
1 Automatically Finding Patches Using Genetic Programming Authors: Westley Weimer, ThanhVu Nguyen, Claire Le Goues, Stephanie Forrest Presented by: David DeBonis, Qi Lu, Shuang Yang Department of Computer Science University of New Mexico February, 0
2 Outline Mutation Crossover 5
3 Error Correction in Source Code Based on positive / negative test cases Program isolation Repair by insert / delete / swap Repeat until a variant passes all tests Minimize difference
4 Example of Errant Code Listing : Euclid s greatest common divisor algorithm /* requires : a >= 0, b >= 0 */ void gcd ( int a, int b ) { if ( a == 0) { printf ( " % d ", b ); } while ( b!= 0) a = a - b; else b = b - a; printf ( " % d ", a ); exit (0); }
5 Variants Creation and Representation Restricted to code substitutions from other parts Mutation / Crossover constrained to area relevant to error Abstract Syntax Tree (AST) Weighted program path P Fitness = N i= wi passed test cases
6 An abstract syntax tree(ast). It includes all of the statements in the program. A weighted path through the program, (statement, weight). The weighted path is a list of pairs, each pair contains a statement and a weight based on that statement s occurrences in various testcases.
7 The algorithm of mutation
8 The example for Mutation 5 6 while ( b!= 0) a = a - b; else b = b + a; return a ;
9 The example for Mutation statement sequence return 0.0 while op:!= : a branch 5 6 while ( b!= 0) a = a - b; else b = b + a; return a ; : b constant: 0 : a op: > : b : a : a 0 bin op: : b : b Figure: The AST of the program : b bin op: + : a
10 Mutation: Swap statement sequence return 0.0 while op:!= : a branch : b constant: 0 : a op: > : b : b : b 0 bin op: + : a : a : a bin op: : b
11 Mutation: Swap 5 6 while ( b!= 0) a = a - b; else b = b + a; return a ; 5 6 while ( b!= 0) b = b + a; else a = a - b; return a ;
12 Mutation: Insertion statement sequence 0.0 condition while 0.0 body op:!= : a branch : b constant: 0 : a 0.0 return condition if body op: > : b : a : a bin op: else body : a 0 bin op: : b : a : b : b : b bin op: + : a
13 Mutation: Insertion 5 6 while ( b!= 0) a = a - b; else b = b + a; return a ; while ( b!= 0) a = a - b; else b = b + a; a = a - b; return a ;
14 Mutation: Deletion statement sequence 0.0 condition while return body op:!= : a branch : b constant: 0 : a condition if body op: > : b : a : a else body 0 bin op: : b : b : b Deletion bin op: + : a
15 Mutation: Deletion 5 6 while ( b!= 0) a = a - b; else b = b + a; return a ; while ( b!= 0) a = a - b; return a ;
16 Crossover Choose a cutoff point for each program Combine the first part of one program with the second part of another and vice versa Input: [P, P, P, P ] and [Q, Q, Q, Q ] with cutoff Child: [P, P, Q, Q ] and [Q, Q, P, P ]
17 Crossover a = a - b; else b = b - a; cutoff point at a = a + b; else b = b + a;
18 Crossover branch branch if-body condition else-body op: > bin op op: if-body condition op: > bin op op: else-body bin op op: + bin op op: +
19 Crossover branch branch if-body condition else-body op: > bin op op: if-body condition op: > bin op op: + else-body bin op op: + bin op op:
20 Crossover a = a - b; else b = b + a; a = a + b; else b = b - a;
21 Crossover
22 Crossover branch branch if-body condition else-body op: > bin op op: + if-body condition op: > bin op op: else-body bin op op: bin op op: +
23 Demonstrated GP approach Based on AST representation Mutate / Crossover algorithm Minimal code changes Experiments over 0 test cases Sizeable code bases Orthogonal errors present Reasonable solution found ( 50%) Efficacy to code maintenance Experiments using Amazon Cloud Equated to under $8 per bug on average Who wants to manually debug anyway!
24 Limitations and Assumptions Only as good as your test cases Not necessarily memory / computing time optimized Expects redundant code segments How well does it scale? by number of bugs... by number of revisions... by number of LOC... Will this technique work on another GP?
A Systematic Study of Automated Program Repair: Fixing 55 out of 105 Bugs for $8 Each
A Systematic Study of Automated Program Repair: Fixing 55 out of 105 Bugs for $8 Each Claire Le Goues (Virginia), Michael Dewey-Vogt (Virginia), Stephanie Forrest (New Mexico), Westley Weimer (Virginia)
More informationUsing Execution Paths to Evolve Software Patches
Using Execution Paths to Evolve Software Patches ThanhVu Nguyen*, Westley Weimer**, Claires Le Gouges**, Stephanie Forrest* * University of New Mexico ** University of Virginia Tuesday, March 31, 2009
More informationFixing software bugs in 10 minutes or less using evolutionary computation
Fixing software bugs in 10 minutes or less using evolutionary computation University of New Mexico Stephanie Forrest ThanhVu Nguyen University of Virginia Claire Le Goues Westley Weimer Summary of method
More informationAutomatically Finding Patches Using Genetic Programming. Westley Weimer, Claire Le Goues, ThanVu Nguyen, Stephanie Forrest
Automatically Finding Patches Using Genetic Programming Westley Weimer, Claire Le Goues, ThanVu Nguyen, Stephanie Forrest Motivation Software Quality remains a key problem Over one half of 1 percent of
More informationProgram Synthesis. SWE 795, Spring 2017 Software Engineering Environments
Program Synthesis SWE 795, Spring 2017 Software Engineering Environments Today HW3 is due next week in class! Part 1 (Lecture)(~50 mins) Break! Part 2 (Discussion)(~60 mins) Discussion of readings Part
More informationRepair & Refactoring
S C I E N C E P A S S I O N T E C H N O L O G Y Repair & Refactoring Birgit Hofer Institute for Software Technology 1 u www.tugraz.at Outline Model-based Software Debugging o Traffic Light Example Repair
More informationAutomatically Finding Patches Using Genetic Programming
Automatically Finding Patches Using Genetic Programming Westley Weimer University of Virginia weimer@virginia.edu ThanhVu Nguyen University of New Mexico tnguyen@cs.unm.edu Claire Le Goues University of
More informationAutomatically Finding Patches Using Genetic Programming
Automatically Finding Patches Using Genetic Programming Westley Weimer, Stephanie Forrest, Claire Le Goues, ThanVu Nguyen, Ethan Fast, Briana Satchell, Eric Schulte Motivation Software Quality remains
More informationAUTOMATIC PROGRAM REPAIR USING GENETIC PROGRAMMING
AUTOMATIC PROGRAM REPAIR USING GENETIC PROGRAMMING CLAIRE LE GOUES APRIL 22, 2013 http://www.clairelegoues.com 1 GENPROG STOCHASTIC SEARCH + TEST CASE GUIDANCE = AUTOMATIC, EXPRESSIVE, SCALABLE PATCH GENERATION
More informationTrusted Software Repair for System Resiliency. Westley Weimer, Stephanie Forrest, Miryung Kim, Claire Le Goues, Patrick Hurley
Trusted Software Repair for System Resiliency, Stephanie Forrest, Miryung Kim, Claire Le Goues, Patrick Hurley For The Next 17 Minutes Program Repair: Resilient but Untrusted Can we assess post-repair
More informationLEVERAGING LIGHTWEIGHT ANALYSES TO AID SOFTWARE MAINTENANCE ZACHARY P. FRY PHD PROPOSAL
LEVERAGING LIGHTWEIGHT ANALYSES TO AID SOFTWARE MAINTENANCE ZACHARY P. FRY PHD PROPOSAL MAINTENANCE COSTS For persistent systems, software maintenance can account for up to 90% of the software lifecycle
More informationREPAIRING PROGRAMS WITH SEMANTIC CODE SEARCH. Yalin Ke Kathryn T. Stolee Claire Le Goues Yuriy Brun
REPAIRING PROGRAMS WITH SEMANTIC CODE SEARCH Yalin Ke Kathryn T. Stolee Claire Le Goues Yuriy Brun Iowa State Iowa State Carnegie Mellon UMass Amherst 1 Input: buggy program, tests Output: fixed program
More informationASTOR: A Program Repair Library for Java
ASTOR: A Program Repair Library for Java Matias Martinez University of Lugano, Switzerland Martin Monperrus University of Lille & Inria, France ABSTRACT During the last years, the software engineering
More informationDynaMoth: Dynamic Code Synthesis for Automatic Program Repair
DynaMoth: Dynamic Code Synthesis for Automatic Program Repair AST 2016 Thomas Durieux & Martin Monperrus March 6, 2017 Inria & University of Lille Automatic test-suite based repair DynaMoth is an automatic
More informationGenetic Programming for Julia: fast performance and parallel island model implementation
Genetic Programming for Julia: fast performance and parallel island model implementation Morgan R. Frank November 30, 2015 Abstract I introduce a Julia implementation for genetic programming (GP), which
More informationSubstitution Based Rules for Efficient Code Duplication on Object Oriented Systems
I J C T A, 9(7), 2016, pp. 3109-3115 International Science Press ISSN: 0974-5572 Substitution Based Rules for Efficient Code Duplication on Object Oriented Systems Anoop Sreekumar R.S.* and R.V. Sivabalan**
More informationRepresentations and Operators for Improving Evolutionary Software Repair
Representations and Operators for Improving Evolutionary Software Repair Claire Le Goues University of Virginia Charlottesville, VA 22903 legoues@cs.virginia.edu Westley Weimer University of Virginia Charlottesville,
More informationLeveraging Program Equivalence for Adaptive Program Repair: Models and First Results. Westley Weimer, UVA Zachary P. Fry, UVA Stephanie Forrest, UNM
Leveraging Program Equivalence for Adaptive Program Repair: Models and First Results Westley Weimer, UVA Zachary P. Fry, UVA Stephanie Forrest, UNM Automated Program Repair Given a program, a notion of
More informationSemFix: Program Repair via Semantic Analysis. Ye Wang, PhD student Department of Computer Science Virginia Tech
SemFix: Program Repair via Semantic Analysis Ye Wang, PhD student Department of Computer Science Virginia Tech Problem Statement Debugging takes much time and effort Even after root cause of a bug is identified,
More informationAutomated Program Repair
#1 Automated Program Repair Motivation Software maintenance is expensive Up to 90% of the cost of software [Seacord] Up to $70 Billion per year in US [Jorgensen, Sutherland] Bug repair is the majority
More informationAutomated Program Repair through the Evolution of Assembly Code
Automated Program Repair through the Evolution of Assembly Code Eric Schulte University of New Mexico 08 August 2010 1 / 26 Introduction We present a method of automated program repair through the evolution
More informationUEE1302(1066) F12: Introduction to Computers and Programming Function (II) - Parameter
UEE1302(1066) F12: Introduction to Computers and Programming Function (II) - Parameter What you will learn from Lab 7 In this laboratory, you will understand how to use typical function prototype with
More informationAn Unsystematic Review of Genetic Improvement. David R. White University of Glasgow UCL Crest Open Workshop, Jan 2016
An Unsystematic Review of Genetic Improvement David R. White University of Glasgow UCL Crest Open Workshop, Jan 2016 A Systematic Study of GI is currently under preparation. Justyna Petke Mark Harman Bill
More informationAutomatically Repairing Concurrency Bugs with ARC MUSEPAT 2013 Saint Petersburg, Russia
Automatically Repairing Concurrency Bugs with ARC MUSEPAT 2013 Saint Petersburg, Russia David Kelk, Kevin Jalbert, Jeremy S. Bradbury Faculty of Science (Computer Science) University of Ontario Institute
More informationIntroduction to Scientific Modeling CS 365, Fall Semester, 2011 Genetic Algorithms
Introduction to Scientific Modeling CS 365, Fall Semester, 2011 Genetic Algorithms Stephanie Forrest http://cs.unm.edu/~forrest/classes/cs365 forrest@cs.unm.edu 505-277-7104 Genetic Algorithms" Principles
More information9/5/17. The Design and Implementation of Programming Languages. Compilation. Interpretation. Compilation vs. Interpretation. Hybrid Implementation
Language Implementation Methods The Design and Implementation of Programming Languages Compilation Interpretation Hybrid In Text: Chapter 1 2 Compilation Interpretation Translate high-level programs to
More informationAutoma'c, Efficient, and General Repair of So8ware Defects using Lightweight Program Analyses
Automa'c, Efficient, and General Repair of So8ware Defects using Lightweight Program Analyses Disserta'on Proposal Claire Le Goues September 22, 2010 So8ware Errors Are Expensive Everyday, almost 300 bugs
More informationTACi: Three-Address Code Interpreter (version 1.0)
TACi: Three-Address Code Interpreter (version 1.0) David Sinclair September 23, 2018 1 Introduction TACi is an interpreter for Three-Address Code, the common intermediate representation (IR) used in compilers.
More informationCSCE 110: Programming I
CSCE 110: Programming I Sample Questions for Exam #1 February 17, 2013 Below are sample questions to help you prepare for Exam #1. Make sure you can solve all of these problems by hand. For most of the
More informationAutomatic Repair of Real Bugs in Java: A Large-Scale Experiment on the Defects4J Dataset
Automatic Repair of Real Bugs in Java: A Large-Scale Experiment on the Defects4J Dataset Matias Martinez, Thomas Durieux, Romain Sommerard, Jifeng Xuan, Martin Monperrus 1 Automatic Software Repair Automatic
More informationAlgorithm Design: GCD
Algorithm Design: GCD Problem solution through refinement GCD Example of use of loops Arguing the complexity of an algorithm Greek mathematics achievement: Euclid s Algorithm 1 How to find the GCD of 2
More informationWhat is recursion? Recursion. How can a function call itself? Recursive message() modified. contains a reference to itself. Week 7. Gaddis:
Recursion What is recursion? Week 7! Generally, when something contains a reference to itself Gaddis:19.1-19.4! Math: defining a function in terms of itself CS 5301 Fall 2013 Jill Seaman 1! Computer science:
More informationNames and Functions. Chapter 2
Chapter 2 Names and Functions So far we have built only tiny toy programs. To build bigger ones, we need to be able to name things so as to refer to them later. We also need to write expressions whose
More informationAC64/AT64 DESIGN & ANALYSIS OF ALGORITHMS DEC 2014
AC64/AT64 DESIGN & ANALYSIS OF ALGORITHMS DEC 214 Q.2 a. Design an algorithm for computing gcd (m,n) using Euclid s algorithm. Apply the algorithm to find gcd (31415, 14142). ALGORITHM Euclid(m, n) //Computes
More information1.7 Recursion. Department of CSE
1.7 Recursion 1 Department of CSE Objectives To learn the concept and usage of Recursion in C Examples of Recursion in C 2 Department of CSE What is recursion? Sometimes, the best way to solve a problem
More informationStandard Version of Starting Out with C++, 4th Edition. Chapter 19 Recursion. Copyright 2003 Scott/Jones Publishing
Standard Version of Starting Out with C++, 4th Edition Chapter 19 Recursion Copyright 2003 Scott/Jones Publishing Topics 19.1 Introduction to Recursion 19.2 The Recursive Factorial Function 19.3 The Recursive
More informationDescribing and Implementing Algorithms
Describing and Implementing Algorithms ECE2036 Lecture 1 ECE2036 Describing and Implementing Algorithms Spring 2016 1 / 19 What is an Algorithm? According to Wikipedia: An algorithm is a sequence of instructions,
More information15-122: Principles of Imperative Computation (Section G)
15-122: Principles of Imperative Computation (Section G) Document 2 Solutions 0. Contracts This lecture was mainly about contracts and ensuring correctness of code. Josh Zimmerman There are 4 types of
More informationA Systematic Study of Automated Program Repair: Fixing 55 out of 105 bugs for $8 Each
A Systematic Study of Automated Program Repair: Fixing 55 out of 105 bugs for $8 Each Claire Le Goues Michael Dewey-Vogt Computer Science Department University of Virginia Charlottesville, VA Email: legoues,mkd5m@cs.virginia.edu
More informationChapter 4 Functions By C.K. Liang
1 Chapter 4 Functions By C.K. Liang What you should learn? 2 To construct programs modularly from small pieces called functions Math functions in C standard library Create new functions Pass information
More informationLoops / Repetition Statements
Loops / Repetition Statements Repetition statements allow us to execute a statement multiple times Often they are referred to as loops C has three kinds of repetition statements: the while loop the for
More informationWhat is recursion? Recursion. How can a function call itself? Recursive message() modified. Week 10. contains a reference to itself.
Recursion What is recursion? Week 10 Generally, when something contains a reference to itself Gaddis:19.1-19.5 CS 5301 Spring 2014 Jill Seaman 1 Math: defining a function in terms of itself Computer science:
More information3. Logical Values. Boolean Functions; the Type bool; logical and relational operators; shortcut evaluation
140 3. Logical Values Boolean Functions; the Type bool; logical and relational operators; shortcut evaluation Our Goal 141 int a; std::cin >> a; if (a % 2 == 0) std::cout
More informationLecture 7: General Loops (Chapter 7)
CS 101: Computer Programming and Utilization Jul-Nov 2017 Umesh Bellur (cs101@cse.iitb.ac.in) Lecture 7: General Loops (Chapter 7) The Need for a More General Loop Read marks of students from the keyboard
More informationarxiv: v1 [cs.se] 25 Mar 2014
Do the Fix Ingredients Already Exist? An Empirical Inquiry into the Redundancy Assumptions of Program Repair Approaches Matias Martinez Westley Weimer Martin Monperrus University of Lille & INRIA, France
More informationCombining Bug Detection and Test Case Generation
Combining Bug Detection and Test Case Generation Martin Kellogg University of Washington, USA kelloggm@cs.washington.edu ABSTRACT Detecting bugs in software is an important software engineering activity.
More informationAutomated Program Repair by Using Similar Code Containing Fix Ingredients
Automated Program Repair by Using Similar Code Containing Fix Ingredients Tao Ji, Liqian Chen, Xiaoguang Mao, Xin Yi College of Computer National University of Defense Technology Changsha, China jitao
More informationPlanning and Search. Genetic algorithms. Genetic algorithms 1
Planning and Search Genetic algorithms Genetic algorithms 1 Outline Genetic algorithms Representing states (individuals, or chromosomes) Genetic operations (mutation, crossover) Example Genetic algorithms
More informationMosig M1 - PLSCD Written exam
Mosig M1 - PLSCD 0809 - Written exam 1 Exercise I : Operational semantics - a debugger In this exercise we consider program execution with the help of a debugger. This execution will be defined on an intermediate
More informationAryan College. Fundamental of C Programming. Unit I: Q1. What will be the value of the following expression? (2017) A + 9
Fundamental of C Programming Unit I: Q1. What will be the value of the following expression? (2017) A + 9 Q2. Write down the C statement to calculate percentage where three subjects English, hindi, maths
More informationCSI32 Object-Oriented Programming
Outline Department of Mathematics and Computer Science Bronx Community College February 2, 2015 Outline Outline 1 Chapter 1 Cornerstones of Computing Textbook Object-Oriented Programming in Python Goldwasser
More informationUpcoming. Repairing Automated Repair. Generalizing 3/19/18
Upcoming Homework 3 due March 22 Literature review due today March 20 Project plan assignment posted, due April 10 Repairing Automated Repair Paper presentation instructions: http://people.cs.umass.edu/~brun/class/2018spring/cs21/paperpresentation/paperpresentation.pdf
More informationChapter 4 C Program Control
1 Chapter 4 C Program Control Copyright 2007 by Deitel & Associates, Inc. and Pearson Education Inc. All Rights Reserved. 2 Chapter 4 C Program Control Outline 4.1 Introduction 4.2 The Essentials of Repetition
More informationTechnical Section. Lab 4 while loops and for loops. A. while Loops or for loops
Lab 4 while loops and for loops The purpose of this lab is to introduce you to the concept of a for loop, gain experience distinguishing between a while loop (which is a more general type of loop than
More informationClassification Using Genetic Programming. Patrick Kellogg General Assembly Data Science Course (8/23/15-11/12/15)
Classification Using Genetic Programming Patrick Kellogg General Assembly Data Science Course (8/23/15-11/12/15) Iris Data Set Iris Data Set Iris Data Set Iris Data Set Iris Data Set Create a geometrical
More informationIntroClassJava: A Benchmark of 297 Small and Buggy Java Programs
IntroClassJava: A Benchmark of 297 Small and Buggy Java Programs Thomas Durieux, Martin Monperrus To cite this version: Thomas Durieux, Martin Monperrus. IntroClassJava: A Benchmark of 297 Small and Buggy
More informationAn automated approach to program repair with semantic code search
Graduate Theses and Dissertations Iowa State University Capstones, Theses and Dissertations 2015 An automated approach to program repair with semantic code search Yalin Ke Iowa State University Follow
More informationOPERATING SYSTEMS, ASSIGNMENT 4 FILE SYSTEM
OPERATING SYSTEMS, ASSIGNMENT 4 FILE SYSTEM SUBMISSION DATE: 15/06/2014 23:59 In this assignment you are requested to extend the file system of xv6. xv6 implements a Unix-like file system, and when running
More informationAutomatically Repairing Broken Workflows for Evolving GUI Applications
Automatically Repairing Broken Workflows for Evolving GUI Applications Sai Zhang University of Washington Joint work with: Hao Lü, Michael D. Ernst End-user s workflow A workflow = A sequence of UI actions
More informationReading assignment: Reviews and Inspections
Foundations for SE Analysis Reading assignment: Reviews and Inspections M. E. Fagan, "Design and code inspections to reduce error in program development, IBM Systems Journal, 38 (2&3), 1999, pp. 258-287.
More informationPage 1. Reading assignment: Reviews and Inspections. Foundations for SE Analysis. Ideally want general models. Formal models
Reading assignment: Reviews and Inspections Foundations for SE Analysis M. E. Fagan, "Design and code inspections to reduce error in program development, IBM Systems Journal, 38 (2&3), 999, pp. 258-28.
More informationControl Statements. if for while
Control Structures Control Statements if for while Control Statements if for while This This is is called called the the initialization initialization statement statement and and is is performed performed
More informationSearching for Program Invariants using Genetic Programming and Mutation Testing
Searching for Program Invariants using Genetic Programming and Mutation Testing Sam Ratcliff, David R. White and John A. Clark. The 13th CREST Open Workshop Thursday 12 May 2011 Outline Invariants Using
More informationAMCAT Automata Coding Sample Questions And Answers
1) Find the syntax error in the below code without modifying the logic. #include int main() float x = 1.1; switch (x) case 1: printf( Choice is 1 ); default: printf( Invalid choice ); return
More informationScientific Computing
Scientific Computing Martin Lotz School of Mathematics The University of Manchester Lecture 1, September 22, 2014 Outline Course Overview Programming Basics The C++ Programming Language Outline Course
More informationExam 2, Version 2. For the following code, mark True or False for statements 1.8 to 1.10.
1. True or False (clearly write True or False on each line). 1.1. It s possible for the body of a do-while loop to execute zero times F For the following code, mark True or False for statements 1.8 to
More informationCS 101: Computer Programming and Utilization
CS 101: Computer Programming and Utilization Jul - Nov 2016 Bernard Menezes (cs101@cse.iitb.ac.in) Lecture 13: Recursive Functions About These Slides Based on Chapter 10 of the book An Introduction to
More informationCIS 110 Introduction To Computer Programming. February 29, 2012 Midterm
CIS 110 Introduction To Computer Programming February 29, 2012 Midterm Name: Recitation # (e.g. 201): Pennkey (e.g. bjbrown): My signature below certifies that I have complied with the University of Pennsylvania
More informationConditionals !
Conditionals 02-201! Computing GCD GCD Problem: Compute the greatest common divisor of two integers. Input: Two integers a and b. Output: The greatest common divisor of a and b. Exercise: Design an algorithm
More informationOdds and Ends. Think about doing research Programming grading. Assignment 3 due Tuesday
Odds and Ends Think about doing research Programming grading Correctness, Documentation, Style, Testing Working in pairs/groups; acknowledge accordingly Assignment 3 due Tuesday ...? Questions on HW Review
More information3. Logical Values. Our Goal. Boolean Values in Mathematics. The Type bool in C++
148 Our Goal 149 3. Logical Values Boolean Functions; the Type bool; logical and relational operators; shortcut evaluation int a; std::cin >> a; if (a % 2 == 0) std::cout
More informationEECS1012. Net-centric Introduction to Computing. Lecture 7 Computational Thinking. Fall 2018, EECS York University. M.S. Brown and Amir H.
EECS1012 Net-centric Introduction to Computing Lecture 7 Computational hinking all 2018, EECS York University M.S. Brown and Amir H. Chinaei overview computational thinking the thought process involved
More informationA Fitness Function to Find Feasible Sequences of Method Calls for Evolutionary Testing of Object-Oriented Programs
A Fitness Function to Find Feasible Sequences of Method Calls for Evolutionary Testing of Object-Oriented Programs Myoung Yee Kim and Yoonsik Cheon TR #7-57 November 7; revised January Keywords: fitness
More informationLecture Overview Code generation in milestone 2 o Code generation for array indexing o Some rational implementation Over Express Over o Creating
1 ecture Overview Code generation in milestone 2 o Code generation for array indexing o Some rational implementation Over Express Over o Creating records for arrays o Short-circuiting Or o If statement
More information3. Logical Values. Our Goal. Boolean Values in Mathematics. The Type bool in C++
Our Goal 3. Logical Values Boolean Functions; the Type bool; logical and relational operators; shortcut evaluation int a; std::cin >> a; if (a % 2 == 0) std::cout
More informationUsing Genetic Algorithms to Solve the Box Stacking Problem
Using Genetic Algorithms to Solve the Box Stacking Problem Jenniffer Estrada, Kris Lee, Ryan Edgar October 7th, 2010 Abstract The box stacking or strip stacking problem is exceedingly difficult to solve
More informationCS 310 Advanced Data Structures and Algorithms
CS 310 Advanced Data Structures and Algorithms Recursion June 27, 2017 Tong Wang UMass Boston CS 310 June 27, 2017 1 / 20 Recursion Recursion means defining something, such as a function, in terms of itself
More informationProgramming (1.0hour)
COMPETITOR S INSTRUCTION:- Attempt all questions: Where applicable circle the letter that indicates the correct answer. Otherwise answer questions as instructed D1.1 Embedded code is used widely in modern
More informationEvolutionary Search in Machine Learning. Lutz Hamel Dept. of Computer Science & Statistics University of Rhode Island
Evolutionary Search in Machine Learning Lutz Hamel Dept. of Computer Science & Statistics University of Rhode Island What is Machine Learning? Programs that get better with experience given some task and
More information(Not Quite) Minijava
(Not Quite) Minijava CMCS22620, Spring 2004 April 5, 2004 1 Syntax program mainclass classdecl mainclass class identifier { public static void main ( String [] identifier ) block } classdecl class identifier
More informationPaul POCATILU, PhD Economics Informatics and Cybernetics Department The Bucharest Academy of Economic Studies
Paul POCATILU, PhD Email: ppaul@ase.ro Economics Informatics and Cybernetics Department The Bucharest Academy of Economic Studies A FRAMEWORK FOR TEST DATA GENERATORS ANALYSIS Abstract. Test data generation
More informationEuclid's Algorithm. MA/CSSE 473 Day 06. Student Questions Odd Pie Fight Euclid's algorithm (if there is time) extended Euclid's algorithm
MA/CSSE 473 Day 06 Euclid's Algorithm MA/CSSE 473 Day 06 Student Questions Odd Pie Fight Euclid's algorithm (if there is time) extended Euclid's algorithm 1 Quick look at review topics in textbook REVIEW
More informationAPCS Semester #1 Final Exam Practice Problems
Name: Date: Per: AP Computer Science, Mr. Ferraro APCS Semester #1 Final Exam Practice Problems The problems here are to get you thinking about topics we ve visited thus far in preparation for the semester
More informationOperating Systems. Lecture 05
Operating Systems Lecture 05 http://web.uettaxila.edu.pk/cms/sp2013/seosbs/ February 25, 2013 Process Scheduling, System Calls Execution (Fork,Wait,Exit,Exec), Inter- Process Communication Schedulers Long
More informationTESTING AND DEBUGGING
TESTING AND DEBUGGING zombie[1] zombie[3] Buuuuugs zombie[4] zombie[2] zombie[5] zombie[0] Fundamentals of Computer Science I Outline Debugging Types of Errors Syntax Errors Semantic Errors Logic Errors
More informationCOMPUTER PROGRAMMING LAB
COURSE OUTCOMES SEMESTER I Student will be able to: COMPUTER PROGRAMMING LAB 1. Explain basic commands in Linux. 2. Develop programs in C language. 3. Design programs for various problems in C language.
More informationA function is a named piece of code that performs a specific task. Sometimes functions are called methods, procedures, or subroutines (like in LC-3).
CIT Intro to Computer Systems Lecture # (//) Functions As you probably know from your other programming courses, a key part of any modern programming language is the ability to create separate functions
More informationGENETIC PROGRAMMING FOR SOFTWARE TRANSPLANTS IMAN HEMATI MOGHADAM
GENETIC PROGRAMMING FOR SOFTWARE TRANSPLANTS IMAN HEMATI MOGHADAM IMPLEMENTED APPROACH: OVERVIEW 1/20 SLICING: Forward Slicing: Used to extract the implementation of the desired feature. Backward Slicing:
More informationA Practical Approach to Programming With Assertions
A Practical Approach to Programming With Assertions Ken Bell Christian-Albrechts Universität Kiel Department of Computer Science and Applied Mathematics Real-Time Systems and Embedded Systems Group July
More informationAgile Software Development. Lecture 7: Software Testing
Agile Software Development Lecture 7: Software Testing Mahmoud El-Gayyar elgayyar@ci.suez.edu.eg Slides are a modified version of the slides by Prof. Kenneth M. Anderson Outline Testing Terminology Types
More informationUCT Algorithm Circle: Number Theory
UCT Algorithm Circle: 7 April 2011 Outline Primes and Prime Factorisation 1 Primes and Prime Factorisation 2 3 4 Some revision (hopefully) What is a prime number? An integer greater than 1 whose only factors
More informationFall 2015 COMP Operating Systems. Lab #3
Fall 2015 COMP 3511 Operating Systems Lab #3 Outline n Operating System Debugging, Generation and System Boot n Review Questions n Process Control n UNIX fork() and Examples on fork() n exec family: execute
More informationLecture Notes on Contracts
Lecture Notes on Contracts 15-122: Principles of Imperative Computation Frank Pfenning Lecture 2 August 30, 2012 1 Introduction For an overview the course goals and the mechanics and schedule of the course,
More informationWhat is recursion? Recursion. Recursive message() modified. How can a function call itself? contains a reference to itself. Week 10. Gaddis:
Recursion What is recursion? Week 10 Gaddis:19.1-19.5 CS 5301 Spring 2017 Jill Seaman 1 l Generally, when something contains a reference to itself l Math: defining a function in terms of itself l Computer
More informationFounda'ons of So,ware Engineering. Sta$c analysis (1/2) Claire Le Goues
Founda'ons of So,ware Engineering Sta$c analysis (1/2) Claire Le Goues 1 Two fundamental concepts Abstrac'on. Elide details of a specific implementa$on. Capture seman$cally relevant details; ignore the
More informationIntro to Computational Programming in C Engineering For Kids!
CONTROL STRUCTURES CONDITIONAL EXPRESSIONS Take the construction like this: Simple example: if (conditional expression) statement(s) we do if the condition is true statement(s) we do if the condition is
More informationSearch-Based Generalization and Refinement of Code Templates
Search-Based Generalization and Refinement of Code Templates Tim Molderez and Coen De Roover Software Languages Lab, Vrije Universiteit Brussel, Belgium tmoldere@vub.ac.be, cderoove@vub.ac.be Abstract.
More informationComp 182 Data Structures Sample Midterm Examination
Comp 182 Data Structures Sample Midterm Examination 5 November 2014 Name: ANSWERS C. R. Putnam 5 November 2014 1. Design an ADT that represents a simple Social Networking Site. It should allow a user to
More informationCIS 110 Introduction to Computer Programming. February 29, 2012 Midterm
CIS 110 Introduction to Computer Programming February 29, 2012 Midterm Name: Recitation # (e.g. 201): Pennkey (e.g. bjbrown): My signature below certifies that I have complied with the University of Pennsylvania
More informationProgramming in Visual Basic with Microsoft Visual Studio 2010
Programming in Visual Basic with Microsoft Visual Studio 2010 Course 10550; 5 Days, Instructor-led Course Description This course teaches you Visual Basic language syntax, program structure, and implementation
More information