Search-based Refactoring Using Recorded Code Changes

被引:37
作者
Ouni, Ali [1 ,2 ]
Kessentini, Marouane [2 ]
Sahraoui, Houari [1 ]
机构
[1] Univ Montreal, DIRO, Montreal, PQ H3C 3J7, Canada
[2] Missouri Univ Sci & Technol, CS, Rolla, MO 65409 USA
来源
PROCEEDINGS OF THE 17TH EUROPEAN CONFERENCE ON SOFTWARE MAINTENANCE AND REENGINEERING (CSMR 2013) | 2013年
关键词
Search-based Software Engineering; Refactoring; Software Maintenance; Multi-objective Optimization;
D O I
10.1109/CSMR.2013.31
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
Over the past decades, many techniques and tools have been developed to record the sequence of applied refactoring to improve design quality. We start from the observation that these recorded code changes can be used to propose new refactoring solutions in similar contexts. In addition, this knowledge can be combined with structural and semantic information, used by existing work, to improve the automation of refactoring. In this paper, we propose a multi-objective optimization approach to find the best sequence of refactorings that maximizes the use of refactoring applied in the past to similar contexts, minimizes semantic errors and minimizes the number of defects (improve code quality). To this end, we use the non-dominated sorting genetic algorithm (NSGA-II) to find the best trade-off between these three objectives. We report the results of our experiments on different open source java projects.
引用
收藏
页码:221 / 230
页数:10
相关论文
共 27 条
  • [1] [Anonymous], 1999, Modern Information Retrieval
  • [2] Bavota G, 2012, PROC INT CONF SOFTW, P1419, DOI 10.1109/ICSE.2012.6227233
  • [3] Cinnéide MO, 2012, INT SYMP EMP SOFTWAR, P49, DOI 10.1145/2372251.2372260
  • [4] Corazza A, 2012, 2012 28TH IEEE INTERNATIONAL CONFERENCE ON SOFTWARE MAINTENANCE (ICSM), P233, DOI 10.1109/ICSM.2012.6405277
  • [5] A fast and elitist multiobjective genetic algorithm: NSGA-II
    Deb, K
    Pratap, A
    Agarwal, S
    Meyarivan, T
    [J]. IEEE TRANSACTIONS ON EVOLUTIONARY COMPUTATION, 2002, 6 (02) : 182 - 197
  • [6] Effective software merging in the presence of object-oriented refactorings
    Dig, Danny
    Manzoor, Kashif
    Johnson, Ralph
    Nguyen, Tien N.
    [J]. IEEE TRANSACTIONS ON SOFTWARE ENGINEERING, 2008, 34 (03) : 321 - 335
  • [7] Refactoring - Improving coupling and cohesion of existing code
    Du Bois, B
    Demeyer, S
    Verelst, J
    [J]. 11TH WORKING CONFERENCE ON REVERSE ENGINEERING, PROCEEDINGS, 2004, : 144 - 151
  • [8] Ekman Torbjorn., 2004, Electr. Notes Theor. Comput. Sci, V107, P57, DOI DOI 10.1016/J.ENTCS.2004.02.048
  • [9] Fenton N., 1997, SOFTWARE METRICS RIG
  • [10] Fokaefs M, 2011, 2011 33RD INTERNATIONAL CONFERENCE ON SOFTWARE ENGINEERING (ICSE), P1037, DOI 10.1145/1985793.1985989