paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Better living through operational semantics: an optimizing compiler for radio protocols

通过操作语义实现更好的生活:面向无线协议的优化编译器
ICFP 1(ICFP)2017匹配度 1/10 · 该论文研究无线协议DSL的形式语义与优化编译器,属于传统编程语言与编译领域,不涉及LLM/Agent、AI系统静态分析、浮点程序分析或贝叶斯程序分析,与用户当前聚焦的PL与AI交叉方向无直接关联。引用 3 inbox
Geoffrey Mainland
dblp: 2026-09-10crossref: 2026-09-10

AI 速览

一句话:为 Ziria 无线协议语言建立核心语言、操作语义与类型系统,并据此提出融合与流水线合并变换,实现更快的编译器。

软件定义无线电希望将软件的灵活迭代带入无线协议设计,但高数据率与时序要求使高层语言难以胜任;原 Ziria 编译器虽证明可行,却缺少形式语义,成功经验难以复用。本文首先为 Ziria 给出核心语言、操作语义与类型系统,并由此设计两种程序变换:融合可消除 Ziria 程序中的中间队列,流水线合并通过批处理 IO 降低执行开销,且后者依赖融合并简化了原编译器的“向量化”。基于这些变换,作者实现新的 Ziria 编译器,利用中间语言减少不必要的内存流量,生成代码显著快于原编译器。该工作既为 Ziria 奠定形式基础,也表明操作语义能带来实际软件工程收益,其核心语言与变换可用于其他高速流数据处理领域。

问题
Ziria 虽能用高层语言编写高性能无线协议,但缺少形式语义,使其优化难以复用与推广。
方法
作者定义 Ziria 核心语言、操作语义和类型系统,并基于语义洞察设计融合与流水线合并变换,进而构建新优化编译器。
评估
通过实现新编译器并与原 Ziria 编译器比较生成代码性能,报告显著加速,说明变换在实际无线协议上的效果。
原文摘要(Abstract)

Software-defined radio (SDR) promises to bring the flexibility and rapid iterative workflow of software to radio protocol design. Many factors make achieving this promise challenging, not least of which are the high data rates and timing requirements of real-world radio protocols. The Ziria language and accompanying compiler demonstrated that a high-level language can compete in this demanding space, but extracting reusable lessons from this success is difficult due to Ziria's lack of a formal semantics. Our first contribution is a core language, operational semantics, and type system for Ziria. The insight we gained through developing this operational semantics led to our second contribution, consisting of two program transformations. The first is fusion, which can eliminate intermediate queues in Ziria programs. Fusion subsumes many one-off optimizations performed by the original Ziria compiler. The second transformation is pipeline coalescing, which reduces execution overhead by batching IO. Pipeline coalescing relies critically on fusion and provides a much simpler story for the original Ziria compiler's "vectorization" transformation. These developments serve as the basis of our third contribution, a new compiler for Ziria that produces significantly faster code than the original compiler. The new compiler leverages our intermediate language to help eliminate unnecessary memory traffic. As well as providing a firm foundation for the Ziria language, our work on an operational semantics resulted in very real software engineering benefits. These benefits need not be limited to SDR---the core language and accompanying transformations we present are applicable to other domains that require processing streaming data at high speed.

链接与引用

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

BibTeX
@article{Mainland17,
  title = {Better living through operational semantics: an optimizing compiler for radio protocols},
  author = {Geoffrey Mainland},
  journal = {Proceedings of the ACM on Programming Languages},
  volume = {1},
  number = {ICFP},
  year = {2017},
  doi = {10.1145/3110263}
}