The w-calculus: a synchronous framework for the verified modelling of digital signal processing algorithms

Emilio Jesús Gallego Arias, P. Jouvelot, Sylvain Ribstein, Dorian Desblancs
{"title":"The w-calculus: a synchronous framework for the verified modelling of digital signal processing algorithms","authors":"Emilio Jesús Gallego Arias, P. Jouvelot, Sylvain Ribstein, Dorian Desblancs","doi":"10.1145/3471872.3472970","DOIUrl":null,"url":null,"abstract":"We introduce the W-calculus, an extension of the call-by-value λ-calculus with synchronous semantics, designed to be flexible enough to capture different implementation forms of Digital Signal Processing algorithms, while permitting a direct embedding into the Coq proof assistant for mechanized formal verification. In particular, we are interested in the different implementations of classical DSP algorithms such as audio filters and resonators, and their associated high-level properties such as Linear Time-invariance. We describe the syntax and denotational semantics of the W-calculus, providing a Coq implementation. As a first application of the mechanized semantics, we prove that every program expressed in a restricted syntactic subset of W is linear time-invariant, by means of a characterization of the property using logical relations. This first semantics, while convenient for mechanized reasoning, is still not useful in practice as it requires re-computation of previous steps. To improve on that, we develop an imperative version of the semantics that avoids recomputation of prior stream states. We empirically evaluate the performance of the imperative semantics using a staged interpreter written in OCaml, which, for an input program in W, produces a specialized OCaml program, which is then fed to the optimizing OCaml compiler. The approach provides a convenient path from the high-level semantical description to low-level efficient code.","PeriodicalId":138204,"journal":{"name":"Proceedings of the 9th ACM SIGPLAN International Workshop on Functional Art, Music, Modelling, and Design","volume":"93 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"2021-08-22","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"Proceedings of the 9th ACM SIGPLAN International Workshop on Functional Art, Music, Modelling, and Design","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1145/3471872.3472970","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 0

Abstract

We introduce the W-calculus, an extension of the call-by-value λ-calculus with synchronous semantics, designed to be flexible enough to capture different implementation forms of Digital Signal Processing algorithms, while permitting a direct embedding into the Coq proof assistant for mechanized formal verification. In particular, we are interested in the different implementations of classical DSP algorithms such as audio filters and resonators, and their associated high-level properties such as Linear Time-invariance. We describe the syntax and denotational semantics of the W-calculus, providing a Coq implementation. As a first application of the mechanized semantics, we prove that every program expressed in a restricted syntactic subset of W is linear time-invariant, by means of a characterization of the property using logical relations. This first semantics, while convenient for mechanized reasoning, is still not useful in practice as it requires re-computation of previous steps. To improve on that, we develop an imperative version of the semantics that avoids recomputation of prior stream states. We empirically evaluate the performance of the imperative semantics using a staged interpreter written in OCaml, which, for an input program in W, produces a specialized OCaml program, which is then fed to the optimizing OCaml compiler. The approach provides a convenient path from the high-level semantical description to low-level efficient code.
w-演算:用于数字信号处理算法验证建模的同步框架
我们介绍了w演算,它是同步语义的按值调用λ演算的扩展,设计得足够灵活,可以捕获数字信号处理算法的不同实现形式,同时允许直接嵌入到Coq证明助手中进行机械化形式验证。特别是,我们对经典DSP算法(如音频滤波器和谐振器)的不同实现及其相关的高级属性(如线性时不变性)感兴趣。我们描述了w演算的语法和指称语义,并提供了一个Coq实现。作为机械化语义的第一个应用,我们通过逻辑关系的性质表征,证明了在W的有限句法子集中表示的每一个程序都是线性时不变的。第一种语义虽然对机械化推理很方便,但在实践中仍然没有用,因为它需要重新计算前面的步骤。为了改进这一点,我们开发了语义的命令式版本,以避免重新计算先前的流状态。我们使用用OCaml编写的分阶段解释器来经验地评估命令式语义的性能,对于W中的输入程序,该解释器会生成专门的OCaml程序,然后将其馈送到优化的OCaml编译器。该方法提供了从高级语义描述到低级高效代码的便捷路径。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
求助全文
约1分钟内获得全文 求助全文
来源期刊
自引率
0.00%
发文量
0
×
引用
GB/T 7714-2015
复制
MLA
复制
APA
复制
导出至
BibTeX EndNote RefMan NoteFirst NoteExpress
×
提示
您的信息不完整,为了账户安全,请先补充。
现在去补充
×
提示
您因"违规操作"
具体请查看互助需知
我知道了
×
提示
确定
请完成安全验证×
copy
已复制链接
快去分享给好友吧!
我知道了
右上角分享
点击右上角分享
0
联系我们:info@booksci.cn Book学术提供免费学术资源搜索服务,方便国内外学者检索中英文文献。致力于提供最便捷和优质的服务体验。 Copyright © 2023 布克学术 All rights reserved.
京ICP备2023020795号-1
ghs 京公网安备 11010802042870号
Book学术文献互助
Book学术文献互助群
群 号:481959085
Book学术官方微信