FlyCatcher: 从测试中自动推断运行时检查器
FlyCatcher: Neural Inference of Runtime Checkers from Tests
AI总结:
FlyCatcher通过结合LLM合成、静态分析和动态验证,从现有测试中自动推断运行时检查器,能检测更多隐性故障。
摘要:
复杂的软件系统常面临隐性故障,即违反预期语义但不引发显式错误。使用特定系统的运行时检查器可检测此类错误,但编写此类检查器具有挑战性且耗时。FlyCatcher是一种自动方法,通过LLM合成、静态分析和动态验证,从现有测试中推断运行时检查器。推断的检查器具有状态性,通过维护抽象状态来推理系统行为。评估显示,FlyCatcher从400个测试中推断出334个检查器,其中300个经交叉验证正确,比现有方法多推断2.6倍正确检查器,能检测5.2倍更多错误。
英文摘要:
Complex software systems often suffer from silent failures, i.e., violations of the intended semantics that do not cause explicit errors. A promising approach to detect such errors is to use system-specific runtime checkers that monitor the execution of a system and check for violations of the intended semantics. However, writing such checkers for a given software system is challenging and time-consuming, and hence, rarely done in practice. This work presents FlyCatcher, an automated approach to derive runtime checkers from existing tests, i.e., from a resource available for most software systems. The critical challenge of such an approach is to generalize the behavioral properties encoded in a test case to arbitrary executions of a system. FlyCatcher addresses this challenge through a combination of LLM-based synthesis, static analysis, and dynamic validation, which infers a checker that monitors specific method calls and asserts properties that should hold when they are called. The inferred checkers are stateful, i.e., they reason about the system's behavior by maintaining a shadow state that abstracts the actual system state as needed by the checker. Our evaluation applies FlyCatcher to 400 tests from four widely used, complex software systems. The approach infers 334 checkers, out of which 300 are found to be correct via cross-validation. Compared with a state-of-the-art approach, our approach infers 2.6x more correct checkers, which enables it to detect 5.2x more errors. By contributing to the automated inference of runtime checkers from tests, this work enables the broader adoption of runtime checking as a practical approach to detect silent failures in complex software systems.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。