Font Size: a A A

Research On Software Bug Localization Based On Deep Learning And Program Slicing

Posted on:2024-07-01Degree:MasterType:Thesis
Country:ChinaCandidate:J YongFull Text:PDF
GTID:2558307136495644Subject:Software engineering
Abstract/Summary:
Bug localization is a critical area in software engineering research.As computer technology continues to evolve,the size of software becomes larger and larger,and the number of bugs contained in software increases.With this comes a significant increase in the difficulty and cost of bug localization,which makes software developers need to spend more effort and time to locate and fix bugs.To address this problem,researchers have proposed a series of automated bug localization techniques.These techniques can give a recommended list of suspicious source code files based on the content of bug reports,thus assisting software developers in locating bugs.However,there is much room for improvement in the performance of existing software bug localization techniques.This thesis first focuses on the task of bug localization at the file level.Existing deep learningbased bug localization methods usually first construct a semantic representation of the entire source code file and then match it with the bug report.Since a source code file may contain multiple subbehaviors,and the bug behavior described by the bug report may only be relevant to some subbehaviors of the source code file.Therefore,directly constructing the semantic representation of the whole source code file may hinder the matching process between the bug report and the source code file.For this reason,this thesis proposes a novel bug localization method called S-Bug Locator,which first decomposes a completed source code file using program slicing techniques to obtain its slices.After that,these slices are divided into multi-row slices and single-row slices,and different feature extraction methods are used to construct semantic representations of these two types of slices.Finally,the semantic similarity scores of bug reports and source code file slices are calculated to recommend suspicious files.The experimental results show that the method improves the accuracy of the bug localization task at the file level.In addition,this thesis also focuses on the task of method-level bug localization.Compared with file-level bug localization tasks,the average instance content that needs to be matched in methodlevel bug localization tasks is shorter,and more instances need to be retrieved,making it a more challenging task.Since many existing file-level bug localization methods have achieved good results,this thesis hopes to improve the accuracy of bug localization by finding some effective file-level features and applying them to method-level bug localization tasks.To this end,this thesis proposes a method-level bug localization method that mainly utilizes three types of features,namely deep features,information retrieval features,and software engineering features.The experimental results show that the method improves the accuracy of the bug localization task at the method level.Finally,this thesis implementes a bug localization system based on the bug localization methods proposed in Chapter 3 and Chapter 4.The system is mainly divided into three modules: user login module,dataset management module,and bug localization module.After logging into the system,users can view data sets,upload data,and use the bug localization function to view the list of suspicious files and suspicious methods recommended by the system.
Keywords/Search Tags:Program Slicing, Bug Report, Code Semantic Representation, Deep Learning
Related items