arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 1908.09758cs.PL
收藏

CountDownLatch的自动验证

Automated Verification of CountDownLatch

Wei-Ngan Chin, Ton Chanh Le, Shengchao Qin

摘要:

CountDownLatch(CDL)是一种通用的并发机制,最早在Java 5中引入,现在也被C++和C#采用。它的使用允许一个或多个线程交换资源,并通过等待某些任务完成,然后其他任务才能继续进行同步。在本文中,我们提出了一个新的框架,用于验证使用CDLs的并发应用程序的正确性。我们的框架是建立在两个现有的机制,并发抽象谓词和虚构的分离逻辑,与一些增强,如借用堆和线程本地抽象。此外,我们提出了一种新的基于等待关系的不一致检测机制,以保证死锁自由。以前的并发验证工作主要集中在数据竞争自由。作为一个实际的概念证明,我们已经实现了这个新的规范和验证机制CDL在一个新的工具,称为HIPCAP,在现有的HIP验证器。我们已经使用这个新工具成功验证了CDL的各种用例。

英文摘要:

The CountDownLatch (CDL) is a versatile concurrency mechanism that was first introduced in Java 5, and is also being adopted into C++ and C#. Its usage allows one or more threads to exchange resources and synchronize by waiting for some tasks to be completed before others can proceed. In this paper, we propose a new framework for verifying the correctness of concurrent applications that use CDLs. Our framework is built on top of two existing mechanisms, concurrent abstract predicate and fictional separation logic, with some enhancements such as borrowed heap and thread local abstraction. In addition, we propose a new inconsistency detection mechanism based on waits-for relation to guarantee deadlock freedom. Prior concurrency verification works have mostly focused on data-race freedom. As a practical proof of concept, we have implemented this new specification and verification mechanism for CDL in a new tool, called HIPCAP, on top of an existing HIP verifier. We have used this new tool to successfully verify various use cases for CDL.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑