Semantic Slicing of Software Version Histories (T)

Software developers often need to transfer functionality, e.g., a set of commits implementing a new feature or a bug fix, from one branch of a configuration management system to another. That can be a challenging task as the existing configuration management tools lack support for matching high-level semantic functionality with low-level version histories. The developer thus has to either manually identify the exact set of semantically-related commits implementing the functionality of interest or sequentially port a specific subset of the change history, "inheriting" additional, unwanted functionality. In this paper, we tackle this problem by providing automated support for identifying the set of semantically-related commits implementing a particular functionality, which is defined by a set of tests. We refer to our approach, CSLICER, as semantic slicing of version histories. We formally define the semantic slicing problem, provide an algorithm for identifying a set of commits that constitute a slice, and instantiate it in a specific implementation for Java projects managed in Git. We evaluate the correctness and effectiveness of our approach on a set of open-source software repositories. We show that it allows to identify subsets of change histories that maintain the functionality of interest but are substantially smaller than the original ones.

[1]  Sarfraz Khurshid,et al.  Localizing failure-inducing program edits based on spectrum information , 2011, 2011 27th IEEE International Conference on Software Maintenance (ICSM).

[2]  Gregg Rothermel,et al.  Whole program path-based dynamic impact analysis , 2003, 25th International Conference on Software Engineering, 2003. Proceedings..

[3]  Matias Martinez,et al.  Fine-grained and accurate source code differencing , 2014, ASE.

[4]  David Chenho Kung,et al.  Change impact identification in object oriented software maintenance , 1994, Proceedings 1994 International Conference on Software Maintenance.

[5]  Klaus Pohl,et al.  Software Product Line Engineering , 2005 .

[6]  Akira Mori,et al.  Diff/TS: A Tool for Fine-Grained Structural Change Analysis , 2008, 2008 15th Working Conference on Reverse Engineering.

[7]  Harald C. Gall,et al.  Classifying Change Types for Qualifying Change Couplings , 2006, 14th IEEE International Conference on Program Comprehension (ICPC'06).

[8]  Alessandro Orso,et al.  Leveraging field data for impact analysis and regression testing , 2003, ESEC/FSE-11.

[9]  Marsha Chechik,et al.  Managing forked product variants , 2012, SPLC '12.

[10]  Sven Apel,et al.  Type-Checking Software Product Lines - A Formal Approach , 2008, 2008 23rd IEEE/ACM International Conference on Automated Software Engineering.

[11]  Harald C. Gall,et al.  Change Distilling:Tree Differencing for Fine-Grained Source Code Change Extraction , 2007, IEEE Transactions on Software Engineering.

[12]  Andreas Zeller,et al.  Simplifying and Isolating Failure-Inducing Input , 2002, IEEE Trans. Software Eng..

[13]  Frank Tip,et al.  Chianti: a tool for change impact analysis of java programs , 2004, OOPSLA.

[14]  Sven Apel,et al.  Guaranteeing Syntactic Correctness for All Product Line Variants: A Language-Independent Approach , 2009, TOOLS.

[15]  Philip Wadler,et al.  Featherweight Java: a minimal core calculus for Java and GJ , 2001, TOPL.

[16]  Matthew B. Dwyer,et al.  Differential symbolic execution , 2008, SIGSOFT '08/FSE-16.

[17]  Thomas W. Reps,et al.  Precise Interprocedural Dataflow Analysis with Applications to Constant Propagation , 1995, TAPSOFT.

[18]  Klaus Pohl,et al.  Software Product Line Engineering - Foundations, Principles, and Techniques , 2005 .

[19]  C. A. R. Hoare,et al.  Differential static analysis: opportunities, applications, and challenges , 2010, FoSER '10.

[20]  Gregg Rothermel,et al.  A framework for evaluating regression test selection techniques , 1994, Proceedings of 16th International Conference on Software Engineering.

[21]  Jennifer Widom,et al.  Change detection in hierarchically structured information , 1996, SIGMOD '96.

[22]  Jianjun Zhao,et al.  Change impact analysis for AspectJ programs , 2008, 2008 IEEE International Conference on Software Maintenance.

[23]  Frank Tip,et al.  A survey of program slicing techniques , 1994, J. Program. Lang..

[24]  Robert S. Arnold,et al.  Software Change Impact Analysis , 1996 .

[25]  Philip Bille,et al.  A survey on tree edit distance and related problems , 2005, Theor. Comput. Sci..