paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Denotational Foundations for Expected Cost Analysis

期望代价分析的指称语义基础
OOPSLA 9(OOPSLA1)2025匹配度 2/10 · 论文研究概率程序的期望代价指称语义,属于概率编程形式语义,与用户关注的浮点程序分析、贝叶斯程序分析及 LLM 交叉方向无直接关联,也未涉及静态分析工具或 Agentic 程序。因此匹配度较低。引用 4 inbox
Pedro H. Azevedo de Amorim
crossref: 2026-09-10

AI 速览

一句话:提出概率程序期望代价分析的指称语义框架 cert,并证明其与操作语义的可靠性和充分性。

程序执行代价分析是计算机科学的基础问题,但在概率编程中,代价因随机采样而不再确定,并与递归和求值策略复杂交互。本文提出 cert:一个基于 Call-By-Push-Value 的元语言,用于推理概率代价。作者定义操作代价语义以及代价语义和期望代价语义两种指称语义,证明前者相对操作语义的可靠性与充分性,并为期望代价语义建立代价充分性定理。文章还证明 CBPV 的效应模拟性质以关联两种指称语义,并基于一元概率语义证明期望代价语义是期望代价与概率的最小语义。最后通过随机算法到随机过程等案例展示 cert 的表达力及其语义对预期期望代价的刻画。

问题
概率程序的执行代价因随机采样而成为随机变量,且与递归、求值策略相互作用复杂,现有指称语义缺乏对期望代价的系统刻画。
方法
提出 CBPV 元语言 cert,定义操作代价语义、指称代价语义和期望代价语义,并证明操作可靠性/充分性、代价充分性、效应模拟及期望代价语义的最小性/典范性。
评估
通过从随机算法到随机过程的案例研究,展示 cert 与期望代价语义的表达力及其对预期期望代价的刻画;评估以理论证明和案例为主。
原文摘要(Abstract)

Reasoning about the cost of executing programs is one of the fundamental questions in computer science. In the context of programming with probabilities, however, the notion of cost stops being deterministic, since it depends on the probabilistic samples made throughout the execution of the program. This interaction is further complicated by the non-trivial interaction between cost, recursion and evaluation strategy. In this work we introduce cert : a Call-By-Push-Value (CBPV) metalanguage for reasoning about probabilistic cost. We equip cert with an operational cost semantics and define two denotational semantics — a cost semantics and an expected-cost semantics. We prove operational soundness and adequacy for the denotational cost semantics and a cost adequacy theorem for the expected-cost semantics. We formally relate both denotational semantics by stating and proving a novel effect simulation property for CBPV. We also prove a canonicity property of the expected-cost semantics as the minimal semantics for expected cost and probability by building on recent advances on monadic probabilistic semantics. Finally, we illustrate the expressivity of cert and the expected-cost semantics by presenting case-studies ranging from randomized algorithms to stochastic processes and show how our semantics capture their intended expected cost.

链接与引用

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

BibTeX
@article{paperbot3182,
  title = {Denotational Foundations for Expected Cost Analysis},
  author = {Pedro H. Azevedo de Amorim},
  journal = {Proceedings of the ACM on Programming Languages},
  volume = {9},
  number = {OOPSLA1},
  year = {2025},
  doi = {10.1145/3720424}
}