paperbot · PL 论文追踪

全部论文 待读 收藏

P1 The simple essence of automatic differentiation

自动微分的简单本质
ICFP 2(ICFP)2018匹配度 5/10 · 论文属于程序语言与机器学习的交叉,讨论自动微分的简洁算法与编译器插件实现,与用户对PL→AI(机器学习系统)的兴趣有间接关联;但并非静态分析在ML/Agentic程序中的应用,也不涉及LLM/Agent、浮点程序分析或贝叶斯程序分析,因此匹配度中等。引用 88 inbox
Conal Elliott
crossref: 2026-09-10

AI 速览

一句话:从简单规约推导通用自动微分算法,特化后得到无图、无磁带、无变异的简洁反向模式 AD。

反向模式自动微分(RAD)是深度学习和大规模优化的核心组件,但常用的反向传播等算法复杂且带状态,难以理解、改进和并行执行。本文从一条简单自然的规约出发,推导出一个通用 AD 算法,并通过改变导数的表示来特化该算法。特别是,对朴素表示应用已知构造,可得到两个远比以往简洁的 RAD 算法。所得算法不涉及图、磁带、变量、偏导数或变异,因而天然适合并行、构造即正确,并可借助与 AD 无关的编译器插件直接在现有编程语言中使用,无需新数据类型或编程风格。

问题
常用反向模式自动微分(如反向传播)复杂、带状态,难以理解、改进和并行执行,且依赖图、磁带、变量、偏导数和变异等机制。
方法
从简单自然规约推导通用 AD 算法,并通过改变导数表示进行特化;对朴素表示应用已知构造得到两个简洁 RAD 算法,并借助 AD 无关编译器插件直接嵌入现有语言。
评估
评估以数学推导、算法特化及与常用 RAD 实现的定性对比为主,展示所得算法构造即正确、并行友好且无需新数据类型。
原文摘要(Abstract)

Automatic differentiation (AD) in reverse mode (RAD) is a central component of deep learning and other uses of large-scale optimization. Commonly used RAD algorithms such as backpropagation, however, are complex and stateful, hindering deep understanding, improvement, and parallel execution. This paper develops a simple, generalized AD algorithm calculated from a simple, natural specification. The general algorithm is then specialized by varying the representation of derivatives. In particular, applying well-known constructions to a naive representation yields two RAD algorithms that are far simpler than previously known. In contrast to commonly used RAD implementations, the algorithms defined here involve no graphs, tapes, variables, partial derivatives, or mutation. They are inherently parallel-friendly, correct by construction, and usable directly from an existing programming language with no need for new data types or programming style, thanks to use of an AD-agnostic compiler plugin.

链接与引用

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

BibTeX
@article{paperbot266,
  title = {The simple essence of automatic differentiation},
  author = {Conal Elliott},
  journal = {Proceedings of the ACM on Programming Languages},
  volume = {2},
  number = {ICFP},
  year = {2018},
  doi = {10.1145/3236765}
}