使用SC正确性证明推断并发程序中的栅栏
Inferring Fences in a Concurrent Program Using SC proof of Correctness
摘要:
大多数并发程序的证明系统假设底层的内存模型是顺序一致的(SC),这一假设不适用于现代多核处理器。出于性能原因,这些处理器实现了宽松的内存模型。作为这种放松的结果,一个程序,在SC内存模型上被证明是正确的,可能会错误地执行。为了保证其在松弛条件下的正确性,在代码中插入了栅栏指令。在本文中,我们表明,SC证明的算法的正确性,在[Sou84]的证明系统中进行,确定每个线程的指令排序足够的SC证明。此外,为了在底层松弛存储器模型上正确地执行该算法,通过插入栅栏指令仅尊重这些排序就足够了。
英文摘要:
Most proof systems for concurrent programs assume the underlying memory model to be sequentially consistent (SC), an assumption which does not hold for modern multicore processors. These processors, for performance reasons, implement relaxed memory models. As a result of this relaxation a program, proved correct on the SC memory model, might execute incorrectly. To ensure its correctness under relaxation, fence instructions are inserted in the code. In this paper we show that the SC proof of correctness of an algorithm, carried out in the proof system of [Sou84], identifies per-thread instruction orderings sufficient for this SC proof. Further, to correctly execute this algorithm on an underlying relaxed memory model it is sufficient to respect only these orderings by inserting fence instructions.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。