paperbot · PL 论文追踪

全部论文 待读 收藏

P1 Large Language Models for Equivalent Mutant Detection: How Far Are We?

大语言模型用于等价变异体检测:我们进展到哪了?
ISSTA Proceedings of the 33rd ACM SIGSOFT International Symposium on Software Testing and Analysis2024匹配度 5/10 · 论文将 LLM 用于等价变异体检测,属于 LLM 辅助软件测试/程序分析,与“AI→PL:利用 LLM 改进程序分析”方向有一定关联。但它不涉及静态分析、形式化验证、浮点程序分析、贝叶斯程序分析或 Agentic 程序,因此仅为中等相关。引用 16 inbox
Zhao Tian, Honglin Shu, Dong Wang, Xuejie Cao, Yasutaka Kamei, Junjie Chen
crossref: 2026-09-12

AI 速览

一句话:首个针对等价变异体检测的系统实证研究,表明 LLM 显著优于现有技术,平均 F1 提升 35.69%。

变异测试对保障软件质量至关重要,但等价变异体会带来冗余开销与偏差,削弱其实际效果。已有等价变异体检测(EMD)技术受限于训练数据稀缺且难以泛化到未见变异体。近期大语言模型(LLM)在多种代码任务中展现出更强的语义理解能力,但其在 EMD 上的表现尚不明确。本文在 3302 个方法级 Java 变异体对上开展实证研究,系统评估 LLM 用于 EMD 的有效性与效率:将 LLM 与现有 EMD 技术对比,考察不同 LLM 使用策略,分析各类 EMD 技术之间的正交性,并测量训练与推理时间开销。结果显示,基于 LLM 的技术显著优于现有方法(F1 平均提升 35.69%),其中微调代码嵌入策略最为有效;同时 LLM 技术在成本(训练与推理时间相对较低)与效果之间取得良好平衡。文章还讨论了模型规模与嵌入质量的影响,并给出未来研究方向。

问题
等价变异体的存在造成冗余成本与偏差,而现有等价变异体检测技术受训练数据稀缺和泛化能力不足的限制;LLM 在该任务上的表现尚不清楚。
方法
在 3302 个方法级 Java 变异体对上进行实证研究,比较 LLM 与现有 EMD 技术的效果,考察不同 LLM 策略、技术间的正交性以及训练与推理时间开销。
评估
以 F1 分数为主要指标进行对比,发现基于 LLM 的技术平均 F1 提升 35.69%,微调代码嵌入策略最佳,且训练与推理时间相对较低,成本效益平衡;并进一步分析模型规模与嵌入质量的影响。
原文摘要(Abstract)

Mutation testing is vital for ensuring software quality. However, the presence of equivalent mutants is known to introduce redundant cost and bias issues, hindering the effectiveness of mutation testing in practical use. Although numerous equivalent mutant detection (EMD) techniques have been proposed, they exhibit limitations due to the scarcity of training data and challenges in generalizing to unseen mutants. Recently, large language models (LLMs) have been extensively adopted in various code-related tasks and have shown superior performance by more accurately capturing program semantics. Yet the performance of LLMs in equivalent mutant detection remains largely unclear. In this paper, we conduct an empirical study on 3,302 method-level Java mutant pairs to comprehensively investigate the effectiveness and efficiency of LLMs for equivalent mutant detection. Specifically, we assess the performance of LLMs compared to existing EMD techniques, examine the various strategies of LLMs, evaluate the orthogonality between EMD techniques, and measure the time overhead of training and inference. Our findings demonstrate that LLM-based techniques significantly outperform existing techniques (i.e., the average improvement of 35.69% in terms of F1-score), with the fine-tuned code embedding strategy being the most effective. Moreover, LLM-based techniques offer an excellent balance between cost (relatively low training and inference time) and effectiveness. Based on our findings, we further discuss the impact of model size and embedding quality, and provide several promising directions for future research. This work is the first to examine LLMs in equivalent mutant detection, affirming their effectiveness and efficiency.

链接与引用

DOI 原文 ·

BibTeX
@inproceedings{paperbot8553,
  title = {Large Language Models for Equivalent Mutant Detection: How Far Are We?},
  author = {Zhao Tian and Honglin Shu and Dong Wang and Xuejie Cao and Yasutaka Kamei and Junjie Chen},
  booktitle = {ISSTA},
  year = {2024},
  doi = {10.1145/3650212.3680395}
}