paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Differential Execution with Lexical Tracing

带词法追踪的差分执行
OOPSLA 10(OOPSLA1)2026匹配度 2/10 · 论文属于形式语义、定理证明与增量计算,核心贡献是差分执行的词法追踪与 Rocq 验证,不涉及 LLM/Agent、静态分析、浮点程序分析或贝叶斯程序分析,与用户主要研究方向交叉很弱。仅在形式验证/程序语言理论层面有间接关联,因此匹配度较低。引用 0 inbox
Sebastian Erdweg, Runqing Xu, Mo Bitar
crossref: 2026-09-10

AI 速览

一句话:提出词法追踪为差分执行步骤提供稳定标识,并在Rocq中验证带缓存的差分执行语义,实现渐进高效。

增量计算旨在输入微小修改后大幅加速,但多数方法仅跳过未变工作并重算其余子计算;差分执行通过传播数据增量避免重算,然而现有差分大步语义每步仍需重放原计算,且缺乏可靠高效的缓存机制。本文提出词法追踪,用大步语义推导树中的路径唯一标识执行步骤,并保证在前序控制流变化时标识仍稳定;进而将词法追踪与缓存扩展到差分执行,给出首个经形式验证且渐进高效的命令式语言差分执行方案。作者在Rocq中机械化证明词法追踪的缓存稳定性及差分缓存语义的正确性与完备性。

问题
现有差分大步语义仍需在每一步重放原计算,且缺乏可靠高效的缓存机制;其核心困难是执行步骤的唯一标识及控制流变化下的标识稳定性。
方法
提出词法追踪,以大步语义推导树中的路径唯一标识执行步骤,并据此设计稳定的缓存机制;将词法追踪与缓存融入差分执行语义。
评估
在Rocq中机械化证明词法追踪的缓存稳定性,以及差分缓存语义的正确性与完备性,并论证其渐进效率。
原文摘要(Abstract)

Incremental computing promises large speed-ups after small input edits. Yet, most incrementality approaches merely skip unchanged work and recompute the remaining sub-computations, even when the inputs change only slightly. Differential execution avoids this by propagating data changes (i.e., deltas), and prior work has shown how to develop a provably correct differential big-step semantics. Unfortunately, that semantics must still replay the original computation at every step, squandering much of the potential gain of incrementalization. While the semantics clearly needs caching to avoid recomputations, a sound and efficient caching discipline is challenging. First, each execution step must be uniquely identified; second, the identifier must remain stable even when the preceding control flow changes. To this end, we develop lexical tracing , which identifies execution steps through their path in the derivation tree of the big-step semantics. We then extend differential execution with lexical tracing and caching to deliver, for the first time, a formally verified, asymptotically efficient account of differential execution for imperative languages. In particular, we developed a novel mechanized theory of cache stability for lexical traces and their semantic rules, which was essential in proving the differential caching semantics correct and complete in Rocq.

链接与引用

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

BibTeX
@article{paperbot3843,
  title = {Differential Execution with Lexical Tracing},
  author = {Sebastian Erdweg and Runqing Xu and Mo Bitar},
  journal = {Proceedings of the ACM on Programming Languages},
  volume = {10},
  number = {OOPSLA1},
  year = {2026},
  doi = {10.1145/3798261}
}