paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Verifying General-Purpose RCU for Reclamation in Relaxed Memory Separation Logic

在松弛内存分离逻辑中验证通用 RCU 的内存回收
PLDI 9(PLDI)2025匹配度 2/10 · 论文是松弛内存模型下通用 RCU 的形式化验证,属于并发程序验证/分离逻辑,与用户核心方向(LLM/Agent 与静态分析或形式化验证的交叉、浮点程序分析、贝叶斯程序分析)没有直接关联;仅在“形式化验证”大领域上有弱关联。引用 1 inbox
Jaehwang Jung, Sunho Park, Janggun Lee, Jeho Yeon, Jeehoon Kang
crossref: 2026-09-10

AI 速览

一句话:首次在松弛内存模型下形式化验证具备模块化规约、可切换临界区与并发写者支持的通用 RCU。

RCU 是并发数据结构中用于延迟内存回收的关键同步机制,但正确实现和使用因并发复杂性而困难。已有验证工作要么假设顺序一致内存模型,要么缺少通用 RCU 库的三大特性:模块化规约、可切换临界区和并发写者支持。本文给出首个在真实松弛内存一致性模型下对通用 RCU 的形式化验证。为涵盖松弛行为,作者扩展现有 SC 规约以显式同步;为支持需要写后读同步的可切换临界区,提出 RAW 同步 SC fence 的推理原则,并据此首次在松弛内存下验证 Peterson 互斥锁;为处理并发写者的部分有序写入,采用逐节点入链接历史不变量。证明在基于 Iris 的 iRC11 松弛内存分离逻辑中机械化,使用 Rocq。

问题
已有 RCU 验证要么依赖顺序一致假设,要么不支持通用 RCU 的模块化规约、可切换临界区和并发写者。
方法
在 iRC11 松弛内存分离逻辑中扩展现有 SC 规约以显式同步,提出 RAW 同步 SC fence 的推理原则,并用逐节点入链接历史不变量处理并发写者。
评估
在 Rocq 中机械化验证通用 RCU,并首次在松弛内存模型下形式化验证 Peterson 互斥锁。
原文摘要(Abstract)

Read-Copy-Update (RCU) is a critical synchronization mechanism for concurrent data structures, enabling efficient deferred memory reclamation. However, implementing and using RCU correctly is challenging due to its inherent concurrency complexities. While previous work verified RCU, they either relied on unrealistic assumptions of sequentially consistent (SC) memory model or lacked three key features of general-purpose RCU libraries: modular specification, switchable critical sections, and concurrent writer support. We present the first formal verification of a general-purpose RCU in realistic relaxed memory consistency (RMC), addressing the challenges posed by these features. To achieve modular specification that encompasses relaxed behaviors, we extend existing SC specifications to account for explicit synchronization. To support switchable critical sections, which require read-after-write (RAW) synchronization, we introduce a reasoning principle for RAW-synchronizing SC fences . Using this principle, we also present the first formal verification of Peterson's mutex in RMC. To support concurrent writers performing partially ordered writes, we avoid assuming a total order of links and instead formulate invariants based on per-node incoming link histories. Our proofs are mechanized in the iRC11 relaxed memory separation logic, built upon Iris, in Rocq.

链接与引用

DOI 原文 · PDF(开放获取) ·

BibTeX
@article{paperbot3147,
  title = {Verifying General-Purpose RCU for Reclamation in Relaxed Memory Separation Logic},
  author = {Jaehwang Jung and Sunho Park and Janggun Lee and Jeho Yeon and Jeehoon Kang},
  journal = {Proceedings of the ACM on Programming Languages},
  volume = {9},
  number = {PLDI},
  year = {2025},
  doi = {10.1145/3729246}
}