A Strategy to Determine When to Stop Using Automatic Bug Localization.
Abstract
Information retrieval based automatic bug localization techniques provide developers a ranked list of suspicious buggy source entities to aid locate the ones needed to be modified and to fix the bug. However, it is unavoidable that some buggy entities are ranked low in the result list using these automatic techniques. We assume a bug localization process to address this challenge. Each time a source code entity in the ranked list is examined; the developers will have the option as to whether to continue examining the automatic bug localization result, or simply switch to using a conventional localization approach. We propose a new evaluation metric called ETC (Expected Time Cost) in the localization process, which includes the time cost of using the conventional approach. Under our assumptions, we derived simple criteria to minimize ETC. We compared the time cost of a state-of-art automatic localization method, BugLocator, with and without using our strategy in two projects. The result shows that using our proposed strategy combining both automatic localization technique together with conventional approach performs better than using only either the automatic localization technique or the conventional approach. I. 3 II. INFORMATION RETRIEVAL BASED BUG LOCALIZATION When software users encounter a fault, they usually submit a bug report, which records the description of the fault, and how to reproduce the bug and other related information. The goal of bug localization is to find which of the source code entities need to be modified in order to fix the bug. Intuitively, the text description of bug contains the semantic information about the functionalities where the bug surfaced, and the source code identifiers are also named by their functionalities. 185 Authorized licensed use limited to: CITY UNIV OF HONG KONG. Downloaded on September 17,2026 at 02:34:25 UTC from IEEE Xplore. Restrictions apply. This assumption guarantees that developers will not skip the buggy entities when they check it, and also will not give wrong buggy labels to source code entities. In addition, the source code comments may have related semantic information about the bug. Text in