paperbot · PL 论文追踪

全部论文 待读 收藏

P2 CRGC: Fault-Recovering Actor Garbage Collection in Pekko

CRGC:Pekko 中容错的 Actor 垃圾回收
PLDI 9(PLDI)2025匹配度 2/10 · 该论文属于程序语言与运行时/分布式系统方向,关注 actor 垃圾回收、容错与 TLA+ 形式化,虽兼具形式化和工程实现,但并未涉及静态分析、LLM/Agent、浮点程序分析或贝叶斯程序分析等用户核心研究方向;这里的 actor 也不同于画像中由 LLM 交互定义的 Agentic 程序。引用 1 inbox
Dan Plyukhin, Gul Agha, Fabrizio Montesi
crossref: 2026-09-10

AI 速览

一句话:提出首个容错且可回收循环垃圾的 actor 垃圾收集器 CRGC,并在 Pekko 中实现与评估。

Actor 框架要求程序员显式杀死 actor 来释放资源。已有 actor 垃圾收集器(GC)要么无法回收循环垃圾,要么在丢消息或节点崩溃时不再容错,难以用于不可靠分布式系统。本文提出 CRGC,首个容错的循环 actor GC。它让 actor 与节点本地记录信息并向各节点 GC 广播更新;无需锁、内存屏障或消息顺序假设,仅依赖 actor 到本地 GC 的可靠 FIFO 通道。作者给出操作语义并在 TLA+ 中形式化,证明可靠性(非垃圾 actor 永不被杀)与完备性(合理假设下所有垃圾 actor 最终被杀)。在 Apache Pekko 中的初步实现和两个基准套件显示,其开销与加权引用计数等简单方法相当,但能力更强。

问题
在不可靠、节点可能失效的分布式 actor 系统中,现有 actor GC 要么不回收循环垃圾,要么不具备容错性,导致垃圾无法回收。
方法
提出 CRGC:actor 与节点本地记录信息并向各节点 GC 广播更新,无需锁、内存屏障或消息顺序假设;给出操作语义并在 TLA+ 中形式化,证明健全性与完备性。
评估
在 Apache Pekko 中初步实现,用两个 actor 基准套件测量性能;开销与加权引用计数等简单方法有竞争力,同时功能更强。
原文摘要(Abstract)

Actors are lightweight reactive processes that communicate by asynchronous message-passing. Actors address common problems like concurrency control and fault tolerance, but resource management remains challenging: in all four of the most popular actor frameworks (Pekko, Akka, Erlang, and Elixir) programmers must explicitly kill actors to free up resources. To simplify resource management, researchers have devised actor garbage collectors (actor GCs) that monitor the application and detect when actors are safe to kill. However, existing actor GCs are impractical for distributed systems where the network is unreliable and nodes can fail. The simplest actor GCs do not collect cyclic garbage, whereas more sophisticated actor GCs are not fault-recovering : dropped messages and crashed nodes can cause actors to become garbage that never gets collected. We present Conflict-free Replicated Garbage Collection (CRGC): the first fault-recovering cyclic actor GC. In CRGC, actors and nodes record information locally and broadcast updates to the garbage collectors running on each node. CRGC does not require locks, explicit memory barriers, or any assumptions about message delivery order, except for reliable FIFO channels from actors to their local garbage collector. Moreover, CRGC is simple: we concisely present its operational semantics, which has been formalized in TLA + , and prove both soundness (non-garbage actors are never killed) and completeness (all garbage actors are eventually killed, under reasonable assumptions). We also present a preliminary implementation in Apache Pekko and measure its performance using two actor benchmark suites. Our results show the performance overhead of CRGC is competitive with simpler approaches like weighted reference counting, while also being much more powerful.

链接与引用

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

BibTeX
@article{paperbot3129,
  title = {CRGC: Fault-Recovering Actor Garbage Collection in Pekko},
  author = {Dan Plyukhin and Gul Agha and Fabrizio Montesi},
  journal = {Proceedings of the ACM on Programming Languages},
  volume = {9},
  number = {PLDI},
  year = {2025},
  doi = {10.1145/3729288}
}