EUVIMEDObjevte EUVIMED
Open access · CC BY 4.0

Improving Fault Localization with External Oracle by Using Counterfactual Execution

Jongchan Park, Tae Eun Kim, Dongsun Kim, Kihong Heo

ACM Transactions on Software Engineering and Methodology · 2025-02-28 · 34 (2) · 1-22

DOI: 10.1145/3695997 ↗

At a glance

Journal article in ACM Transactions on Software Engineering and Methodology, published online on 2025-01-24. Written by Jongchan Park and 3 co-authors. Cited 2 times so far (Crossref); 33 references. The full text is freely available (open access, CC BY 4.0). Funded by: National Research Foundation of Korea, yungpook National University Research Fund.

AbstraktBibliografické údajeCiteRelated studies

Abstract (original language)

We present Flex , a new approach to improve fault localization with external oracles. Spectrum-based fault localization techniques estimate suspicious statements based on the execution trace of the test suite. State-of-the-art techniques rely on test oracles that internally exist in the program. However, programs often have external oracles that observe their behavior from outside. This in turn hinders fine-grained and accurate estimation of suspicious statements in practice because the correctness of each execution can only be observed at termination. In this article, we aim to address this problem by observing counterfactual execution traces, which enable fine-grained estimation even without precise internal oracles. We observe two types of counterfactual scenarios related to different types of test cases: When the branch condition is set to a Boolean constant, (1) if most of the passing test cases still pass, we consider the newly executed statements in the branch statement as unrelated to the failure; (2) if failing test case still fails, we also consider the originally executed statements as unrelated to the failure. We evaluated the performance on widely used C and Java programs. Flex improves the accuracy of state-of-the-art SBFL techniques on C and Java programs by 24% and 22% on average, respectively.

Funding

  • National Research Foundation of Korea
  • yungpook National University Research Fund

Cite

APA

Park, J., Kim, T. E., Kim, D., & Heo, K. (2025). Improving Fault Localization with External Oracle by Using Counterfactual Execution. ACM Transactions on Software Engineering and Methodology, 34(2), 1-22. https://doi.org/10.1145/3695997

Vancouver

Park J, Kim TE, Kim D, Heo K. Improving Fault Localization with External Oracle by Using Counterfactual Execution. ACM Transactions on Software Engineering and Methodology. 2025;34(2):1-22. doi:10.1145/3695997

BibTeX
@article{Park2025,
  author = {Park, Jongchan and Kim, Tae Eun and Kim, Dongsun and Heo, Kihong},
  title = {Improving Fault Localization with External Oracle by Using Counterfactual Execution},
  journal = {ACM Transactions on Software Engineering and Methodology},
  year = {2025},
  volume = {34},
  number = {2},
  pages = {1--22},
  doi = {10.1145/3695997}
}
Start for free →