05-899D: Human Aspects of Software Development Spring 2011, Lecture 20 YoungSeok Yoon Institute for Software.

Slides:



Advertisements
Similar presentations
Duplicate code detection using Clone Digger Peter Bulychev Lomonosov Moscow State University CS department.
Advertisements

A Mutation / Injection-based Automatic Framework for Evaluating Code Clone Detection Tools Chanchal Roy University of Saskatchewan The 9th CREST Open Workshop.
Min Zhang School of Computer Science University of Hertfordshire
Code Smell Research: History and Future Directions Second PLOW Installment - March 5, Nikolaos Tsantalis Computer Science & Software Engineering.
Reverse Engineering © SERG Code Cloning: Detection, Classification, and Refactoring.
Refactoring-aware Configuration Management for Object-Oriented Programs Written by: Danny Dig, Kashif Manzoor, Ralph Johnson, and Tien Nguyen ACM International.
Preventive Software Maintenance: The Past, the Present, the Future Nikolaos Tsantalis Computer Science & Software Engineering Consortium for Software Engineering.
Automated Analysis and Code Generation for Domain-Specific Models George Edwards Center for Systems and Software Engineering University of Southern California.
Memories of Bug Fixes Sunghun Kim, Kai Pan, and E. James Whitehead Jr., University of California, Santa Cruz Presented By Gleneesha Johnson CMSC 838P,
Analyzing Software Code and Execution – Plagiarism and Bug Detection Shoaib Jameel.
Revision Control Practices in Software Engineering Surekha, Kotiyala Madhuri, Komuravelly Suchitra, Yerramalla.
About the Presentations The presentations cover the objectives found in the opening of each chapter. All chapter objectives are listed in the beginning.
CODING Research Data Management. Research Data Management Coding When writing software or analytical code it is important that others and your future.
Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University Industrial Application.
Software Reengineering 2003 년 12 월 2 일 최창익, 고광 원.
Chapter 9 – Software Evolution and Maintenance
Impact Analysis of Database Schema Changes Andy Maule, Wolfgang Emmerich and David S. Rosenblum London Software Systems Dept. of Computer Science, University.
Introduction to High-Level Language Programming
1 Software Maintenance and Evolution CSSE 575: Session 8, Part 2 Analyzing Software Repositories Steve Chenoweth Office Phone: (812) Cell: (937)
272: Software Engineering Fall 2012 Instructor: Tevfik Bultan Lecture 17: Code Mining.
System Analysis and Design
Dependency Tracking in software systems Presented by: Ashgan Fararooy.
Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University What Kinds of.
CD in Natural Language Software Artifacts 1 Clone Detection in Natural Language Software Artifacts: Techniques and Applications Elmar Juergens November.
Software Engineering CS3003
Department of CSE, MIT, Manipal SOFTWARE ENGINEERING By Prakash Kalingrao Aithal.
Supervisor:Mr. Sayed Morteza Zaker Presentor:Fateme hadinezhad.
Algorithms and Programming
Introduction CS 3358 Data Structures. What is Computer Science? Computer Science is the study of algorithms, including their  Formal and mathematical.
Sadegh Aliakbary Sharif University of Technology Spring 2012.
Mining and Analysis of Control Structure Variant Clones Guo Qiao.
Bug Localization with Machine Learning Techniques Wujie Zheng
Reviewing Recent ICSE Proceedings For:.  Defining and Continuous Checking of Structural Program Dependencies  Automatic Inference of Structural Changes.
Computer Concepts 2014 Chapter 12 Computer Programming.
CMCD: Count Matrix based Code Clone Detection Yang Yuan and Yao Guo Key Laboratory of High-Confidence Software Technologies (Ministry of Education) Peking.
Cross Language Clone Analysis Team 2 October 27, 2010.
Samad Paydar Web Technology Lab. Ferdowsi University of Mashhad 10 th August 2011.
Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University Applying Clone.
Which Configuration Option Should I Change? Sai Zhang, Michael D. Ernst University of Washington Presented by: Kıvanç Muşlu.
Department of Computer Science, Graduate School of Information Science & Technology, Osaka University Inoue Laboratory Eunjong Choi 1 Investigating Clone.
C++ Programming Language Lecture 2 Problem Analysis and Solution Representation By Ghada Al-Mashaqbeh The Hashemite University Computer Engineering Department.
Automatic Identification of Bug-Introducing Changes. Presenter: Haroon Malik.
Barbara Weber Univ. of Innsbruck, Austria Manfred Reichert Univ. of Ulm, Germany Presenter: Arghyadip Paul Refactoring Process Models in Large Process.
1 Program Slicing Amir Saeidi PhD Student UTRECHT UNIVERSITY.
Presented by: Ashgan Fararooy Referenced Papers and Related Work on:
Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University IWPSE 2003 Program.
Chapter 5: Software Re-Engineering Omar Meqdadi SE 3860 Lecture 5 Department of Computer Science and Software Engineering University of Wisconsin-Platteville.
Sadegh Aliakbary Sharif University of Technology Spring 2011.
Automatically detecting and describing high level actions within methods Presented by: Gayani Samaraweera.
1 ECE 750 Topic 8 Meta-programming languages, systems, and applications Evolving Object-Oriented Designs with Refactorings – Lance Tokuda and Don Batory.
1 Experience from Studies of Software Maintenance and Evolution Parastoo Mohagheghi Post doc, NTNU-IDI SEVO Seminar, 16 March 2006.
SEG 4110 – Advanced Software Design and Reengineering Topic T Introduction to Refactoring.
Diagnosing Design Problems in Object Oriented Systems Adrian Trifu, Radu Marinescu Proceedings of the 12th IEEE Working Conference on Reverse Engineering.
Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University 1 Extracting Sequence.
What kind of and how clones are refactored? A case study of three OSS projects WRT2012 June 1, Eunjong Choi†, Norihiro Yoshida‡, Katsuro Inoue†
The Hashemite University Computer Engineering Department
A proposal to support the extreme programming development methodology from the quality assurance point of view Authors: Calin Jebelean –
Chapter 16 Maintaining Information Systems. Objectives:  Explain and contrast four types of system maintenance.  Describe factors affecting maintenance.
Chapter 25 – Configuration Management 1Chapter 25 Configuration management.
Estimating Code Size After a Complete Code-Clone Merge Buford Edwards III, Yuhao Wu, Makoto Matsushita, Katsuro Inoue 1 Graduate School of Information.
Software Testing.
Software Metrics 1.
Detecting Table Clones and Smells in Spreadsheets
Rename Local Variable Refactoring Instances
Ruru Yue1, Na Meng2, Qianxiang Wang1 1Peking University 2Virginia Tech
: Clone Refactoring Davood Mazinanian Nikolaos Tsantalis Raphael Stein
Software Refactoring Group
Quaid-i-Azam University
Advanced Programming Behnam Hatami Fall 2017.
Recommending Adaptive Changes for Framework Evolution
Presentation transcript:

05-899D: Human Aspects of Software Development Spring 2011, Lecture 20 YoungSeok Yoon Institute for Software Research Carnegie Mellon University Software Evolution - Evolving and Improving Code - 1 Mar 24 th, 2011

Carnegie Mellon University, School of Computer Science Outline Copy & Paste, Code Clones Two different thoughts about code clones Clone detection tools Tools to help making, managing code clones Refactoring What is refactoring, and how it is supported Studies about refactoring Program Differencing Different types of program differencing Logical Structural Diff 2

Carnegie Mellon University, School of Computer Science Cloning Considered Harmful There has been a common wisdom about code cloning 3 Making code clones should be avoided because they tend to introduce maintenance problems. (i.e. It is difficult to update all the code clones consistently) Making code clones should be avoided because they tend to introduce maintenance problems. (i.e. It is difficult to update all the code clones consistently)

Carnegie Mellon University, School of Computer Science Cloning Considered Harmful “It has long been known that copying can make the code larger, more complex, and more difficult to maintain” [Baker95] “Code duplication is one of the factors that severely complicates t he maintenance and evolution of large software systems” [Ducas se99] “Number one in the stink parade is duplicated code. If you see the same code structure in more than one place, you can be sure that your program will be better if you find a way to unify them.” [Fowler99] – well known “bad smell” of a program code Every other clone detection tool papers somehow claim that code clones are bad. 4

Carnegie Mellon University, School of Computer Science Two Different Research Directions “How can we find the code clones in the code base effectively?” Automatic code clone detection tools “How can we help developers help avoid code cloning?” Refactoring 5

Carnegie Mellon University, School of Computer Science An Ethnographic Study of Copy and Paste Programming Practices in OOPL [M. Kim04] Study Settings A programmer produces 4 non-trivial C&P/hr (total 16/hr) Taxonomy of C&P usage in three different aspects Intention Design Maintenance 6 M. Kim, L. Bergman, T. Lau, and D. Notkin (2004), “An ethnographic study of copy and paste programming practices in OOPL,” in Proceedings of International Symposium on Empirical Software Engineering (ISESE’04), pp

Carnegie Mellon University, School of Computer Science An Ethnographic Study of Copy and Paste Programming Practices in OOPL [M. Kim04] C&P Intentions structural template (the most common intention) relocate, regroup, reorganize, restructure, refactor semantic template design pattern usage of a module (following a certain protocol) reuse a definition of particular behavior reuse control structure (nested if~else or loops) 7 M. Kim, L. Bergman, T. Lau, and D. Notkin (2004), “An ethnographic study of copy and paste programming practices in OOPL,” in Proceedings of International Symposium on Empirical Software Engineering (ISESE’04), pp

Carnegie Mellon University, School of Computer Science An Ethnographic Study of Copy and Paste Programming Practices in OOPL [M. Kim04] Other Insights Unavoidable duplicates (e.g., lack of multiple inheritance) Programmers use their memory of C&P history to determine when to restructure code delaying restructuring helps them discover the right level of abstraction C&P dependencies are worth observing and maintaining 8 M. Kim, L. Bergman, T. Lau, and D. Notkin (2004), “An ethnographic study of copy and paste programming practices in OOPL,” in Proceedings of International Symposium on Empirical Software Engineering (ISESE’04), pp

Carnegie Mellon University, School of Computer Science “Cloning Considered Harmful” Considered Harmful [Kasper06] Provides list of patterns of cloning (similar to the style of design patterns) For each pattern, the followings are described Name Motivation Advantages Disadvantages 9 Management Long term issues Structural manifestations Examples C. Kapser and M. W. Godfrey (2006), “‘Cloning Considered Harmful’ Considered Harmful,” in 13th Working Conference on Reverse Engineering (WCRE ’06), 2006, pp

Carnegie Mellon University, School of Computer Science List of Copy & Paste Patterns Forking Hardware variations Platform variation Experimental variation Templating Boiler-plating due to language in-expressiveness API/Library protocols General language or algorithmic idioms Customization Bug workarounds Replicate and specialize 10 C. Kapser and M. W. Godfrey (2006), “‘Cloning Considered Harmful’ Considered Harmful,” in 13th Working Conference on Reverse Engineering (WCRE ’06), 2006, pp

Carnegie Mellon University, School of Computer Science Code Clone Genealogies [M. Kim05] Investigates the validity of the assumption that code clones are bad Defines clone evolution model Built an automatic tool to extract the history of code clones from a software repository 11 M. Kim, V. Sazawal, D. Notkin, and G. Murphy (2005), “An empirical study of code clone genealogies,” in Proceedings of the 10th European software engineering conference held jointly with 13th ACM SIGSOFT international symposium on Foundations of software engineering (ESEC/FSE-13). Code Snippet Clone Group Clone Lineage

Carnegie Mellon University, School of Computer Science Code Clone Genealogies [M. Kim05] 12 M. Kim, V. Sazawal, D. Notkin, and G. Murphy (2005), “An empirical study of code clone genealogies,” in Proceedings of the 10th European software engineering conference held jointly with 13th ACM SIGSOFT international symposium on Foundations of software engineering (ESEC/FSE-13).

Carnegie Mellon University, School of Computer Science Code Clone Genealogies [M. Kim05] 13 M. Kim, V. Sazawal, D. Notkin, and G. Murphy (2005), “An empirical study of code clone genealogies,” in Proceedings of the 10th European software engineering conference held jointly with 13th ACM SIGSOFT international symposium on Foundations of software engineering (ESEC/FSE-13). Observations In both systems, a large number of clones were volatile 26% ~ 34% of dead lineages were discontinued because of divergent changes in the clone group  Aggressive, immediate refactoring may not be cost-effective.

Carnegie Mellon University, School of Computer Science Types of Clones TypesDescription Type 1exact copy without modifications (except for white space and comments) Type 2syntactically identical copy; only variable, type, or function identifiers were changed Type 3copy with further modifications; statements were changed, added, or removed Type 4semantically similar code snippets, which might be written independently 14 S. Bellon, R. Koschke, G. Antoniol, J. Krinke, and E. Merlo (2007), “Comparison and Evaluation of Clone Detection Tools”, IEEE Transactions on Software Engineering, vol. 33, no. 9, pp C. K. Roy and J. R. Cordy (2007), “A Survey on Software Clone Detection Research,” SCHOOL OF COMPUTING TR , QUEEN’S UNIVERSITY, vol. 115.

Carnegie Mellon University, School of Computer Science Types of Clone Detection Tools TypesExample Tools & Research TextualDup Loc [Ducasse99], [Johnson93], [Karp & Rabin87] TokenDup [Baker95, 96], CCFinder [Kamiya02] Metric[Kontogiannis95, 96], [Mayrand96] AST 1) basedCloneDR [Baxter98] PDG 2) basedDuplix [Krinke01], [Komondoor01] 15 S. Bellon, R. Koschke, G. Antoniol, J. Krinke, and E. Merlo (2007), “Comparison and Evaluation of Clone Detection Tools”, IEEE Transactions on Software Engineering, vol. 33, no. 9, pp ) AST: Abstract Syntax Tree 2) PDG: Program Dependence Graph

Carnegie Mellon University, School of Computer Science Comparison and Evaluation of Clone Detection Tools An experiment conducted by Bellon et al. 16 Reference corpus (oracle) Oracle was built manually. An independent person looked at 2 percent of all 325,935 submitted candidates. Clone injection S. Bellon, R. Koschke, G. Antoniol, J. Krinke, and E. Merlo (2007), “Comparison and Evaluation of Clone Detection Tools”, IEEE Transactions on Software Engineering, vol. 33, no. 9, pp

Carnegie Mellon University, School of Computer Science Comparison and Evaluation of Clone Detection Tools Conclusion The two token-based (Baker, Kamiya) and text-based (Rieger) behave astonishingly similarly. The tools based on tokens and text have higher recall Merlo’s tool and Baxter’s AST-based tool have higher precision (but considerably higher costs in terms of execution time) The PDG-based tool (Krinke) does not perform too well (sensible only for type-3 clones). Large number of rejected candidates (24% ~ 77%) Many injected clones were missed (24% ~ 46% found) 17 S. Bellon, R. Koschke, G. Antoniol, J. Krinke, and E. Merlo (2007), “Comparison and Evaluation of Clone Detection Tools”, IEEE Transactions on Software Engineering, vol. 33, no. 9, pp

Carnegie Mellon University, School of Computer Science MeCC [H. Kim11] Detects semantic clones Use path-sensitive semantic-based static ana lyzer to symbolically estimate the memory ef fects of procedures Compare the abstract memory states 18 path-insensitive analysis will ignore this difference H. Kim, Y. Jing, S. Kim, and K. Yi (2011), “MeCC: Memory Comparison-based Clone Detector”, in Proceedings of the 33rd International Conference on Software Engineering (ICSE2011).

Carnegie Mellon University, School of Computer Science MeCC [H. Kim11] Abstract memory state example 19 H. Kim, Y. Jing, S. Kim, and K. Yi (2011), “MeCC: Memory Comparison-based Clone Detector”, in Proceedings of the 33rd International Conference on Software Engineering (ICSE2011).

Carnegie Mellon University, School of Computer Science MeCC [H. Kim11] Evaluation 20 H. Kim, Y. Jing, S. Kim, and K. Yi (2011), “MeCC: Memory Comparison-based Clone Detector”, in Proceedings of the 33rd International Conference on Software Engineering (ICSE2011).

Carnegie Mellon University, School of Computer Science Linked Editing [Toomim04] Solves several problems unobservable inconsistencies tedious, repetitive edits Evaluation study Within subject design Compare functional abstraction vs. linked editing 21 M. Toomim, A. Begel, and S. L. Graham (2004), “Managing Duplicated Code with Linked Editing,” in Proceedings of IEEE Symposium on Visual Languages and Human Centric Computing (VL/HCC'04), 2004, pp

Carnegie Mellon University, School of Computer Science EUKLAS [Dörner11] 22 C. Dörner and B. Myers (2011), “EUKLAS: Supporting Copy-and-Paste Strategies for Integrating Example Code”. (submitted to IEEE Symposium on Visual Languages and Human Centric Computing, VL/HCC 2011) Detects following C&P errors in JavaScript code 1. missing parameter definitions 2. missing local/global variable definitions 3. missing function definitions 4. missing CSS imports 5. missing JavaScript imports 6. missing HTML elements accessed by getElementById Provide quick fixes for 1~3.

Carnegie Mellon University, School of Computer Science EUKLAS [Dörner11] 23 C. Dörner and B. Myers (2011), “EUKLAS: Supporting Copy-and-Paste Strategies for Integrating Example Code”. (submitted to IEEE VL/HCC 2011) Evaluation

Carnegie Mellon University, School of Computer Science Summary of C&P, Code Clones There has been a common wisdom that code clones are inherently bad (since before 1990’s) Many different types of code clone detectors has been built Recent empirical studies (since 2004) have shown that nevertheless developers create code clones and they are not always bad There are tools to help developers create and manage code clones more effectively and correctly 24

Carnegie Mellon University, School of Computer Science Outline Copy & Paste, Code Clones Two different thoughts about code clones Clone detection tools Tools to help making, managing code clones Refactoring What is refactoring, and how it is supported Studies about refactoring Program Differencing Different types of program differencing Logical Structural Diff 25

Carnegie Mellon University, School of Computer Science Refactoring “Refactoring is the process of changing a software system in such a way that it does not alter the external behavior of the code yet improves its internal structure.” [Fowler 1999] Popular refactoring examples Rename Extract Method Pull Up Method / Push Down Method 26 M. Fowler, K. Beck, J. Brant, W. Opdyke, and D. Roberts (1999), “Refactoring: Improving the Design of Existing Code”, 1st ed. Addison-Wesley Professional.

Carnegie Mellon University, School of Computer Science A Refactoring tool for Smalltalk [Roberts97] Refactoring tool integrated in an IDE Most of the recent IDEs have this feature 27 D. Roberts, J. Brant, and R. Johnson (1997), “A refactoring tool for smalltalk,” Theory and Practice of Object Systems, vol. 3, no. 4, pp

Carnegie Mellon University, School of Computer Science Refactoring Practice (Eclipse Case Study) [Xing06] Compared three pairs of Eclipse releases using UMLDiff [Xing05] technique 28 Z. Xing and E. Stroulia (2005), “UMLDiff: an algorithm for object-oriented design differencing,” in Proceedings of the 20th IEEE/ACM international Conference on Automated software engineering (ASE’05), p. 54–65. Z. Xing and E. Stroulia (2006), “Refactoring Practice: How it is and How it Should be Supported - An Eclipse Case Study,” in Proceedings of 22nd IEEE International Conference on Software Maintenance (ICSM ‘06), 2006, pp

Carnegie Mellon University, School of Computer Science Refactoring Practice (Eclipse Case Study) [Xing06] Observations About 70% of structural changes may be due to refactorings About 60% of these changes, the references to the affected entities in a component-based application can be automatically updated State-of-the-art IDEs only support a subset of common low-level refactorings, and lack support for more complex ones 29 Z. Xing and E. Stroulia (2006), “Refactoring Practice: How it is and How it Should be Supported - An Eclipse Case Study,” in Proceedings of 22nd IEEE International Conference on Software Maintenance (ICSM ‘06), 2006, pp

Carnegie Mellon University, School of Computer Science How We Refactor, and How We Know It [Murphi-Hill09] Extensive study using 4 data sets spanning > 13,000 developers, > 240,000 refactorings > 2500 developer hours, > 3400 commits Data sets Users (collected by Murphy et al. in 2005) Everyone (collected by Eclipse Usage Collector) Toolsmiths (refactoring tool developers) Eclipse CVS Casts doubt on some of the previously stated assumptions 30 E. Murphy-Hill, C. Parnin, and A. P. Black (2009), “How we refactor, and how we know it,” in Proceedings of the 31st International Conference on Software Engineering (ICSE 2009), p. 287–297.

Carnegie Mellon University, School of Computer Science How We Refactor, and How We Know It [Murphi-Hill09] Observations The Rename refactoring tool is used much more frequently by ordinary programmers than by the toolsmiths About 40% of refactorings performed using a tool occur in batches (i.e., refactorings of the same kind within 60 secs) About 90% of configuration defaults or refactoring tools remain unchanged when programmers use the tools Messages written by programmers in commit logs do not reliably indicate the presence of refactoring Programmers frequently floss refactor (i.e., interleave refactoring with other programming activities) 31 E. Murphy-Hill, C. Parnin, and A. P. Black (2009), “How we refactor, and how we know it,” in Proceedings of the 31st International Conference on Software Engineering (ICSE 2009), p. 287–297.

Carnegie Mellon University, School of Computer Science How We Refactor, and How We Know It [Murphi-Hill09] Observations (cont’d) About half of the refactorings are not high-level.  refactoring detection tools that look exclusively for high-level refactorings will not detect them Refactorings are performed frequently Almost 90% of refactorings are performed manually, without the help of tools The kind of refactoring performed with tools differ from the kind performed manually 32 E. Murphy-Hill, C. Parnin, and A. P. Black (2009), “How we refactor, and how we know it,” in Proceedings of the 31st International Conference on Software Engineering (ICSE 2009), p. 287–297.

Carnegie Mellon University, School of Computer Science Roles of API-level Refactorings [M. Kim11] Investigate the role of refactoring by observing the correlation between refactoring and bug fixing Study Approach Study Subjects: Eclipse JDT, jEdit, and Columba Identify refactoring revisions Use automatic refactoring reconstruction technique Identify bug fix revisions Heuristically mine by searching for keywords such as “bug” or “fixed”, or bug report ID Identify bug-introducing changes From the bug fix revisions, trace back when was the code fragment that had bug introduced 33 M. Kim, D. Cai, and S. Kim (2011), "An Empirical Investigation into the Role of API-Level Refactorings during Software Evolution", in Proceedings of the 33rd International Conference on Software Engineering (ICSE2011).

Carnegie Mellon University, School of Computer Science Roles of API-level Refactorings [M. Kim11] Observations The number of bug fixes increases after API-level refactoring The time taken to fix bugs is shorter after API-level refactoring A large number of refactoring revisions include bug fixes at the same time or related to later bug fixes API-level refactorings occur more frequently before than after major software releases 34 M. Kim, D. Cai, and S. Kim (2011), "An Empirical Investigation into the Role of API-Level Refactorings during Software Evolution", in Proceedings of the 33rd International Conference on Software Engineering (ICSE2011).

Carnegie Mellon University, School of Computer Science Outline Copy & Paste, Code Clones Two different thoughts about code clones Clone detection tools Tools to help making, managing code clones Refactoring What is refactoring, and how it is supported Studies about refactoring Program Differencing Different types of program differencing Logical Structural Diff 35

Carnegie Mellon University, School of Computer Science Types of Program Differencing Longest Common Sequence (Textual) Abstract Syntax Tree (AST) Based Control Flow Graph (CFG) Based Program Dependence Graph (PDG) Based Rule Based 36

Carnegie Mellon University, School of Computer Science LSDiff [M. Kim 09] LSDiff: Logical Structural Diff Infer the systematic structural differences as logic rules Detects exceptions to the logic rules 37 M. Kim and D. Notkin, “Discovering and representing systematic code changes”, Proceedings of the 31st International Conference on Software Engineering, p. 309–319, 2009.

Carnegie Mellon University, School of Computer Science LSDiff [M. Kim 09] Represent a program version as a set of predicates which describe structural information (also called as “fact-based representation”) M. Kim and D. Notkin, “Discovering and representing systematic code changes”, Proceedings of the 31st International Conference on Software Engineering, p. 309–319,

Carnegie Mellon University, School of Computer Science LSDiff [M. Kim 09] M. Kim and D. Notkin, “Discovering and representing systematic code changes”, Proceedings of the 31st International Conference on Software Engineering, p. 309–319,

Carnegie Mellon University, School of Computer Science LSDiff [M. Kim 09] Exception is also shown, which might be a mistake made by the developer while refactoring 40 M. Kim and D. Notkin, “Discovering and representing systematic code changes”, Proceedings of the 31st International Conference on Software Engineering, p. 309–319, 2009.

Carnegie Mellon University, School of Computer Science Conclusion Code clones are generally considered bad, but rece nt studies has shown that they are not always bad Many types of code clone detection tools has been developed since 1990’s, and still being actively deve loped There are tools that help developers to manage cod e clones effectively and correctly Refactoring is widely used, but the refactoring tools only support relatively low-level refactorings There are many different approaches of program diff erencing, which help reviewing and understanding c ode changes 41

Carnegie Mellon University, School of Computer Science Other Closely Related Topics Keyword: “Software Evolution” Mining Software Repositories 6.2 Reverse Engineering Crosscutting Concerns, AOP Delta Debugging 42

Carnegie Mellon University, School of Computer Science Questions? 43