Mutation testing is a powerful technique for ensuring software quality. However, the presence of equivalent mutants introduces unnecessary costs and biases, limiting its practical effectiveness. Although numerous equivalent mutant detection (EMD) methods have been proposed, they often face distinct challenges: pure-code analysis methods can be limited by their reliance on specific compiler infrastructures, while existing machine-learning approaches remain constrained by scarce training data and limited generalization to unseen mutants. Large language models (LLMs) have recently demonstrated remarkable performance across diverse code-related tasks by better capturing program semantics. Yet their potential for EMD remains largely unexplored, particularly in the multi-lingual context. This paper presents the first comprehensive empirical study on LLMs for EMD, using 3,302 Java and 1,088 C mutant pairs to benchmark against state-of-the-art methods, explore strategy variations, assess efficiency, and evaluate cross-lingual generalization. Experimental results show that LLM-based approaches achieve higher F1-scores than the evaluated traditional methods, with fine-tuned code embedding yielding the highest detection accuracy among the tested strategies. Moreover, LLM-based approaches strike a practical balance between effectiveness and efficiency with inference times comparable to existing machine-learning models. Importantly, fine-tuned LLMs demonstrate measurable generalization across programming languages. These findings establish LLMs as a viable and efficient approach for tackling the longstanding challenge of equivalent mutant detection, offering new directions for advancing mutation testing in practice.
Faculdade de Engenharia, Universidade do Porto(波尔图大学工程学院);LASIGE, Faculdade de Ciências, Universidade de Lisboa(里斯本大学理学院LASIGE);Toronto Metropolitan University(多伦多都会大学)
Search-Based Generation of Undetected Quantum Circuit Mutants
Simula Research Laboratory(Simula研究实验室);Oslo Metropolitan University(奥斯陆城市大学);Trinity College Dublin, School of Computer Science and Statistics(都柏林三一学院计算机科学与统计学院);National Institute of Informatics(信息学研究所)
Minimum Complete MR Subsets under Semantic-Mutation Fault Models: A Support-Set Domination Boundary
School of Computing, University of South China(南华大学计算机学院);Hunan Engineering Research Center of Software Evaluation and Testing for Intellectual Equipment(智能装备软件评测与测试湖南省工程研究中心);CNNC Key Laboratory on High Trusted Computing(中核集团高可信计算重点实验室)