[en] Automated program repair (APR) has extensively been developed by leveraging search-based techniques, in which fix ingredients are explored and identified in different granularities from a specific search space. State-of-the approaches often find fix ingredients by using mutation operators or leveraging manually-crafted templates. We argue that the fix ingredients can be searched in an online mode, leveraging code search techniques to find potentially-fixed versions of buggy code fragments from which repair actions can be extracted. In this study, we present an APR tool, LSRepair, that automatically explores code repositories to search for fix ingredients at the method-level granularity with three strategies of similar code search. Our preliminary evaluation shows that code search can drive a faster fix process (some bugs are fixed in a few seconds). LSRepair helps repair 19 bugs from the Defects4J benchmark successfully. We expect our approach to open new directions for fixing multiple-lines bugs.
Centre de recherche :
Interdisciplinary Centre for Security, Reliability and Trust (SnT) > Security Design and Validation Research Group (SerVal)
Disciplines :
Sciences informatiques
Auteur, co-auteur :
LIU, Kui ; University of Luxembourg > Interdisciplinary Centre for Security, Reliability and Trust (SNT)
KOYUNCU, Anil ; University of Luxembourg > Interdisciplinary Centre for Security, Reliability and Trust (SNT)
KIM, Kisub ; University of Luxembourg > Interdisciplinary Centre for Security, Reliability and Trust (SNT)
M. Wen, J. Chen, R. Wu, D. Hao, and S.-C. Cheung, "Context-aware patch generation for better automated program repair," in ICSE, 2018.
A. Koyuncu, T. Bissyandé, D. Kim, J. Klein, M. Monperrus, and Y. Le Traon, "Impact of Tool Support in Patch Construction," in Proceedings of the 26th ACM SIGSOFT International Symposium on Software Testing and Analysis. New York, NY, USA: ACM, 2017, pp. 237-248.
W. Weimer, Z. P. Fry, and S. Forrest, "Leveraging program equivalence for adaptive program repair: Models and first results," in ASE, 2013.
A. Carzaniga, A. Gorla, A. Mattavelli, N. Perino, and M. Pezze, "Automatic recovery from runtime failures," in ICSE, 2013.
Z. Coker and M. Hafiz, "Program transformations to fix c integers," in ICSE, 2013.
H. D. T. Nguyen, D. Qi, A. Roychoudhury, and S. Chandra, "Semfix: program repair via semantic analysis," in ICSE, 2013.
E. T. Barr, Y. Brun, P. Devanbu, M. Harman, and F. Sarro, "The plastic surgery hypothesis," in FSE, 2014.
Y. Ke, K. T. Stolee, C. Le Goues, and Y. Brun, "Repairing programs with semantic code search (t)," in ASE, 2015.
S. Mechtaev, J. Yi, and A. Roychoudhury, "Directfix: Looking for simple program repairs," in ICSE, 2015.
M. Martinez and M. Monperrus, "Mining repair models for reasoning on the search space of automated program fixing," EMSE, 2013.
F. Long and M. Rinard, "An analysis of the search spaces for generate and validate patch generation systems," in ICSE, 2016.
X.-B. D. Le, Q. L. Le, D. Lo, and C. Le Goues, "Enhancing automated program repair with deductive verification," in ICSME, 2016.
L. Chen, Y. Pei, and C. A. Furia, "Contract-based program repair without the contracts," in ASE, 2017.
X.-B. D. Le, D.-H. Chu, D. Lo, C. Le Goues, and W. Visser, "S3: syntaxand semantic-guided repair synthesis via programming by examples," in FSE, 2017.
F. Long, P. Amidon, and M. Rinard, "Automatic inference of code transforms for patch generation," in FSE, 2017.
J. Xuan, M. Martinez, F. Demarco, M. Clement, S. L. Marcote, T. Durieux, D. Le Berre, and M. Monperrus, "Nopol: Automatic repair of conditional statement bugs in Java programs," TSE, 2017.
Y. Xiong, J. Wang, R. Yan, J. Zhang, S. Han, G. Huang, and L. Zhang, "Precise condition synthesis for program repair," in ICSE, 2017.
T. Janssen, R. Abreu, and A. J. van Gemund, "Zoltar: A toolset for automatic fault localization," in ASE 2009.
M. Martinez et al., "Automatic repair of real bugs in Java: A large-scale experiment on the defects4j dataset," EMSE, 2017.
Y. Xiong, X. Liu, M. Zeng, L. Zhang, and G. Huang, "Identifying patch correctness in test-based program repair," in ICSE, 2018.
M. Martinez, W. Weimer, and M. Monperrus, "Do the fix ingredients already exist-an empirical inquiry into the redundancy assumptions of program repair approaches," in ICSE-NIER, 2014.
A. Koyuncu, K. Liu, T. F. Bissyandé, D. Kim, J. Klein, M. Monperrus, and Y. L. Traon, "Fixminer: Mining relevant fix patterns for automated program repair," arXiv preprint, 2018.
J.-R. Falleri, F. Morandat, X. Blanc, M. Martinez, and M. Monperrus, "Fine-grained and accurate source code differencing," in ASE, 2014.
B. Fluri, M. Wuersch, M. Pinzger, and H. Gall, "Change distilling: Tree differencing for fine-grained source code change extraction," TSE, 2007.
M. Martinez, L. Duchien, and M. Monperrus, "Automatically extracting instances of code change patterns with ast analysis," in ICSME, 2013.
A. Carzaniga, A. Gorla, N. Perino, and M. Pezze, "Automatic workarounds for web applications," in FSE, 2010.
M. Gabel and Z. Su, "A study of the uniqueness of source code," in FSE, 2010.
S. Mechtaev, M.-D. Nguyen, Y. Noller, L. Grunske, and A. Roychoudhury, "Semantic program repair using a reference implementation," in ICSE, 2018.
Z. Li, S. Lu, S. Myagmar, and Y. Zhou, "CP-Miner: a tool for finding copy-paste and related bugs in operating system code," in OSDI, 2004.
L. Jiang, G. Misherghi, Z. Su, and S. Glondu, "Deckard: Scalable and accurate tree-based detection of code clones," in ICSE, 2007.
J. Krinke, "Identifying similar code with program dependence graphs," in RE, 2001.
C. Liu, C. Chen, J. Han, and P. S. Yu, "Gplag: detection of software plagiarism by program dependence graph analysis," in KDD, 2006.
M. Kim and D. Notkin, "Discovering and representing systematic code changes," in ICSE, 2009.
S. Kim, K. Pan, and E. Whitehead Jr, "Memories of bug fixes," in FSE, 2006.
T. Molderez, R. Stevens, and C. De Roover, "Mining change histories for unknown systematic edits," in MSR, 2017.
R. Yue, N. Meng, and Q. Wang, "A characterization study of repeated bug fixes," in ICSME, 2017.
Y. Padioleau, J. Lawall, R. R. Hansen, and G. Muller, "Documenting and automating collateral evolutions in linux device drivers," in OSR, 2008.
K. Kim, D. Kim, T. F. Bissyandé, E. Choi, L. Li, J. Klein, and Y. Le Traon, "FaCoY-a code-to-code search engine," in ICSE, 2018.
S. Sidiroglou, E. Lahtinen, N. Rittenhouse, P. Piselli, F. Long, D. Kim, and M. Rinard, "Targeted automatic integer overflow discovery using goal-directed conditional branch enforcement," in ACM Notices, 2015.
K. Liu, D. Kim, T. F. Bissyandé, S. Yoo, and Y. L. Traon, "Mining fix patterns for findbugs violations," IEEE TSE, 2019 (to appear).
K. Liu, D. Kim, L. Li, K. Anil, T. F. Bissyandé, and Y. L. Traon, "A closer look at real-world patches," in ICSME, 2018.
Q. Xin and S. P. Reiss, "Leveraging syntax-related code for automated program repair," in ASE, 2017.
R. K. Saha, Y. Lyu, H. Yoshida, and M. R. Prasad, "Elixir: Effective object-oriented program repair," in ASE, 2017.
J. Hua, M. Zhang, K. Wang, and S. Khurshid, "Towards practical program repair with on-demand candidate generation," in ICSE, 2018.
R. Just, D. Jalali, and M. D. Ernst, "Defects4j: A database of existing faults to enable controlled testing studies for Java," in ISSTA, 2014.
Eirini et al, "The promises and perils of mining github," in MSR, 2014.
E. K. Smith, E. T. Barr, C. Le Goues, and Y. Brun, "Is the cure worse than the disease-overfitting in automated program repair," in FSE, 2015.
V. Sobreira, T. Durieux, F. Madeiral, M. Monperrus, and M. de Almeida Maia, "Dissection of a Bug Dataset: Anatomy of 395 Patches from Defects4J," in SANER, 2018.
E. T. Barr, M. Harman, Y. Jia, A. Marginean, and J. Petke, "Automated software transplantation," in ISSTA, 2015.
S. Sidiroglou-Douskos, E. Lahtinen, F. Long, and M. Rinard, "Automatic error elimination by horizontal code transfer across multiple applications," in ACM SIGPLAN Notices, 2015.
S. Sidiroglou-Douskos, E. Davis, and M. Rinard, "Horizontal code transfer via program fracture and recombination," 2015.