Font Size: a A A

Research On Automatic Repair Method Of Conditional Statement Defects In Object Oriented Programs

Posted on:2022-01-24Degree:MasterType:Thesis
Country:ChinaCandidate:J WuFull Text:PDF
GTID:2518306551470444Subject:Software engineering
Abstract/Summary:PDF Full Text Request
In software development and maintenance,debugging is an important step to find program defects and reduce them.Recent researches have shown that this activity usually takes up about 50% of the software developer's time.In the fast and short development cycle,traditional manual debugging is no longer suitable for repairing large and complex software.Therefore,in order to optimize the cost of software development,researchers proposed automatic defect repair technology to assist or replace developers in software debugging.Most automated defect repair technologies use test cases to describe the correct behavior of program and verify the effectiveness of patches by rerunning them.A patch is identified as an effective patch to fix the defect if all the test cases are executed successfully.However,test suites are often incomplete,effective patches generated by such techniques may pass given test cases but not actually fix defects.In order to improve the defect repair rate and the patch accuracy,this paper focuses on the conditional statement defects in object-oriented programs,and proposes a novel automatic conditional statement defects repair method.This method includes two steps: fault localization,patch generation and validation.(1)In the process of fault localization,two spectrum-based fault localization technologies are integrated to acquire suspicious statements list more efficiently and accurately,which are divided into two phases: suspicious method localization and suspicious statement localization.Further,improved angel repair location technology is used to find repair point in the suspicious statements list.(2)Depending on the statement type of repair point,repair process selects different patch generation strategies.On the one side,this method defines three kinds of suitable mutation operators for conditional statements,and use mutation technology to simply modify the original conditional expressions as candidate patches.On the other hand,by collecting program semantic information,this method uses component-based program synthesis technology to synthesize conditional expressions satisfying the constraints as candidate patches.Finally,run test suite again for patch validation.This paper developed a tool prototype MSFix,and manually selected 62 real conditional statement defects from the Defects4 J dataset for experimental verification.The experimental results show that(1)The defect repair rate of this solution is 62.90%,and the patch accuracy is 53.85%.(2)Compared with some existing popular defect repair technologies,the defect repair rate and patch accuracy of this solution are significantly improved.
Keywords/Search Tags:automatic defect repair, software debugging, fault localization, program mutation, program synthesis technology
PDF Full Text Request
Related items