一句话:提出 Propel,自动验证应用代码中的结合律、交换律、幂等律等基本代数律,支持辅助性质猜想与等式/不等式推理。
函数的代数律(如交换律、结合律、幂等律)是数学与抽象计算思维的基础,在编程中同样关键:编译器优化、大数据处理、数据流处理、机器学习以及分布式算法与数据结构的正确性都依赖这些性质。然而多数编程语言缺乏内建机制来强制并验证操作是否满足此类代数律。本文提出一个专门面向一组基本代数律的验证器:它能够自动猜想辅助性质,并对表达式的等式与不等式进行推理,这正是在其他工具失败时仍能证明目标性质的关键。作者将该思想实现在 Propel 验证器中,并在总计 142 个代数性质实例上与五个最先进验证器进行比较。结果表明,Propel 能自动推导出依赖这些性质保证正确性的不同领域中的代数律,即便竞争工具无法验证或超时的情况下也能成功。
Algebraic laws of functions in mathematics – such as commutativity, associativity, and idempotence – are often used as the basis to derive more sophisticated properties of complex mathematical structures and are heavily used in abstract computational thinking. Algebraic laws of functions in coding , however, are rarely considered. Yet, they are essential. For example, commutativity and associativity are crucial to ensure correctness of a variety of software systems in numerous domains, such as compiler optimization, big data processing, data flow processing, machine learning or distributed algorithms and data structures. Still, most programming languages lack built-in mechanisms to enforce and verify that operations adhere to such properties. In this paper, we propose a verifier specialized on a set of fundamental algebraic laws that ensures that such laws hold in application code. The verifier can conjecture auxiliary properties and can reason about both equalities and inequalities of expressions, which is crucial to prove a given property when other competitors do not succeed. We implement these ideas in the Propel verifier. Our evaluation against five state-of-the-art verifiers on a total of 142 instances of algebraic properties shows that Propel is able to automatically deduce algebraic properties in different domains that rely on such properties for correctness, even in cases where competitors fail to verify the same properties or time out.
@article{paperbot2513,
title = {Automated Verification of Fundamental Algebraic Laws},
author = {George Zakhour and Pascal Weisenburger and Guido Salvaneschi},
journal = {Proceedings of the ACM on Programming Languages},
volume = {8},
number = {PLDI},
year = {2024},
doi = {10.1145/3656408}
}