arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 1509.03339cs.LOcs.PL
收藏

分离逻辑的形式化C存储模型

A Formal C Memory Model for Separation Logic

Robbert Krebbers

摘要:

命令式程序设计语言的形式语义的核心是描述存储器上的操作的行为的存储器模型。定义一个与C11标准中的C语言描述相匹配的内存模型是一个挑战,因为C语言允许高级(通过类型化表达式)和低级(通过位操作)内存访问。C11标准限制了这两个级别之间的交互,以使更有效的编译器优化成为可能,代价是使内存模型变得复杂。我们描述了一个正式的内存模型(非并发部分)C11标准,结合这些限制,并在同一时间描述了低级别的内存操作。这种形式化的内存模型包括一个丰富的权限模型,使其可用于分离逻辑,并支持程序转换的推理。使用Coq证明助手对记忆模型及其基本性质进行了形式化描述。

英文摘要:

The core of a formal semantics of an imperative programming language is a memory model that describes the behavior of operations on the memory. Defining a memory model that matches the description of C in the C11 standard is challenging because C allows both high-level (by means of typed expressions) and low-level (by means of bit manipulation) memory accesses. The C11 standard has restricted the interaction between these two levels to make more effective compiler optimizations possible, on the expense of making the memory model complicated. We describe a formal memory model of the (non-concurrent part of the) C11 standard that incorporates these restrictions, and at the same time describes low-level memory operations. This formal memory model includes a rich permission model to make it usable in separation logic and supports reasoning about program transformations. The memory model and essential properties of it have been fully formalized using the Coq proof assistant.

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

↑