A successful automated program proof is, in software verification, the ultimate triumph. In practice, however, the road to such success is paved with many failed proof attempts. Unlike a failed test, which provides concrete evidence of an actual bug in the program, failed proofs leave the programmer guessing. Can we put them to good use? The work reported here takes advantage of the rich internal information that automatic provers collect about the program when attempting a proof. If the proof fails, we use the counterexample generated by the prover (specifically, the SMT solver underlying the proof environment Boogie, used in the AutoProof system to perform correctness proofs of contract-equipped Eiffel programs) to produce a failed test, which provides the programmer with immediately exploitable information to correct the program. The discussion presents the Proof2Test tool implementing these ideas and demonstrates their application to a collection of examples.
翻译:成功的自动程序验证在软件验证中是最终的胜利。 然而,在实践中, 成功的道路被许多失败的验证尝试所铺设。 与提供程序中实际错误的具体证据的失败测试不同, 失败的验证让程序员猜测。 我们能否将其用于良好的用途? 此处报告的工作利用了自动验证者在尝试验证时收集的关于程序的大量内部信息。 如果证明失败, 我们使用验证者产生的反实例( 具体来说, 用于证明环境布吉的SMT解答器, 用于自动Proof系统, 用于对合同装备的 Eiffel 程序进行正确性证明) 来生成一个失败的测试, 向程序员提供可立即利用的信息来纠正程序。 讨论展示了执行这些想法的“ 校验2测试” 工具, 并演示其用于收集实例 。