SmartFL: Semantics Based Probabilistic Fault Localization
- 27 May 2025
- journal article
- Published by Institute of Electrical and Electronics Engineers (IEEE) in IEEE Transactions on Software Engineering
- Vol. 51 (7) , 2161-2180
Abstract
Testing-based fault localization has been a research focus in software engineering in the past decades. It localizes faulty program elements based on a set of passing and failing test executions. Since whether a fault could be triggered and detected by a test is related to program semantics, it is crucial to model program semantics in fault localization approaches. Existing approaches either consider the full semantics of the program (e.g., mutation-based fault localization and angelic debugging), leading to scalability issues, or ignore the semantics of the program (e.g., spectrum-based fault localization), leading to imprecise localization results. Our key idea is: by modeling only the correctness of program values but not their full semantics, a balance could be reached between effectiveness and scalability. To realize this idea, we introduce a probabilistic model by efficient approximation of program semantics and several techniques to address scalability challenges. Our approach, SmartFL (SeMantics bAsed pRobabilisTic Fault Localization), is evaluated on a real-world dataset, Defects4J 2.0. The top-1 statementlevel accuracy of our approach is 14%, which improves 130% over the best SBFL and MBFL methods. The average time cost is 205 seconds per fault, which is half of SBFL methods. After combining our approach with existing approaches using the CombineFL framework, the performance of the combined approach is significantly boosted by an average of 10% on top-1, top-3, and top-5 accuracy compared to state-of-the-art combination methods.Keywords
All Related Versions
Funding Information
- National Key Research and Development Program of China (2022YFB4501902)
- National Natural Science Foundation of China (62232003, 62232001, 62172017, W2411051)
This publication has 43 references indexed in Scilit:
- Delta4Ms: Improving mutation‐based fault localization by eliminating mutant biasSoftware Testing, Verification and Reliability, 2024
- Improving Fault Localization by Integrating Value and Predicate Based Causal Inference Techniques2021
- Combining Spectrum-Based Fault Localization and Statistical Debugging: An Empirical Study2019
- Semantic Fault Localization and Suspiciousness Ranking2019
- Evaluating and Improving Fault Localization2017
- HSFal: Effective fault localization using hybrid spectrum of full slices and execution slicesJournal of Systems and Software, 2014
- Slice-based statistical fault localizationJournal of Systems and Software, 2014
- Metallaxis‐FL: mutation‐based fault localizationSoftware Testing, Verification and Reliability, 2013
- Factor graphs and the sum-product algorithmIEEE Transactions on Information Theory, 2001
- PIE: a dynamic failure-based techniqueIEEE Transactions on Software Engineering, 1992