Cogent is a restricted functional language designed to reduce the cost of developing verified systems code. Because of its sometimes-onerous restrictions, such as the lack of support for recursion and its strict uniqueness type system, Cogent provides an escape hatch in the form of a foreign function interface (FFI) to C code. This poses a problem when verifying Cogent programs, as imported C components do not enjoy the same level of static guarantees that Cogent does. Previous verification of file systems implemented in Cogent merely assumed that their C components were correct and that they preserved the invariants of Cogent's type system. In this paper, we instead prove such obligations. We demonstrate how they smoothly compose with existing Cogent theorems, and result in a correctness theorem of the overall Cogent-C system. The Cogent FFI constraints ensure that key invariants of Cogent's type system are maintained even when calling C code. We verify reusable higher-order and polymorphic functions including a generic loop combinator and array iterators and demonstrate their application to several examples including binary search and the BilbyFs file system. We demonstrate the feasibility of verification of mixed Cogent-C systems, and provide some insight into verification of software comprised of code in multiple languages with differing levels of static guarantees.


翻译: Cogent 是一种有限的功能语言, 旨在降低开发经核实的系统代码的成本。 由于它有时会受到一些非常严格的限制, 例如缺乏对循环支持及其严格的独有类型系统的支持, Cogent 提供了外功能界面( FFI) 向 C 代码 提供的逃生舱。 当核查 Cogent 程序时, 这造成了一个问题, 因为进口的 C 组件并不享有与 Cogent 相同的静态保障水平。 在 Cogent 中执行的文件系统的先前核查仅仅假设它们的 C 组件是正确的, 它们保存着 Cogent 类型系统的变异性。 在本文中, 我们证明这些义务。 我们展示它们如何顺利地与现有的 Cogent 理论兼容, 并导致整个 Cogent- C 代码系统的正确性理论。 Cogent FFI 制约确保即使在调用 C 代码时, Cogent 类型系统的关键变量也得到维持。 我们核查高排序和多变式功能, 包括通用循环调试调器和编程器, 并演示其应用几个例子, 包括二进式搜索和BilbyF 文件系统。 我们展示了多种核查系统的可行性。

0
下载
关闭预览

相关内容

【硬核书】矩阵代数基础,248页pdf
专知会员服务
86+阅读 · 2021年12月9日
应用机器学习书稿,361页pdf
专知会员服务
59+阅读 · 2020年11月24日
Linux导论,Introduction to Linux,96页ppt
专知会员服务
79+阅读 · 2020年7月26日
强化学习最新教程,17页pdf
专知会员服务
177+阅读 · 2019年10月11日
一句话木马的各种变形
黑白之道
4+阅读 · 2019年7月13日
【TED】生命中的每一年的智慧
英语演讲视频每日一推
10+阅读 · 2019年1月29日
meta learning 17年:MAML SNAIL
CreateAMind
11+阅读 · 2019年1月2日
RL 真经
CreateAMind
5+阅读 · 2018年12月28日
A Technical Overview of AI & ML in 2018 & Trends for 2019
待字闺中
17+阅读 · 2018年12月24日
视觉机械臂 visual-pushing-grasping
CreateAMind
3+阅读 · 2018年5月25日
Hierarchical Disentangled Representations
CreateAMind
4+阅读 · 2018年4月15日
【学习】Hierarchical Softmax
机器学习研究会
4+阅读 · 2017年8月6日
Auto-Encoding GAN
CreateAMind
7+阅读 · 2017年8月4日
Arxiv
0+阅读 · 2022年2月15日
Arxiv
0+阅读 · 2022年2月13日
Arxiv
0+阅读 · 2022年2月11日
VIP会员
相关资讯
一句话木马的各种变形
黑白之道
4+阅读 · 2019年7月13日
【TED】生命中的每一年的智慧
英语演讲视频每日一推
10+阅读 · 2019年1月29日
meta learning 17年:MAML SNAIL
CreateAMind
11+阅读 · 2019年1月2日
RL 真经
CreateAMind
5+阅读 · 2018年12月28日
A Technical Overview of AI & ML in 2018 & Trends for 2019
待字闺中
17+阅读 · 2018年12月24日
视觉机械臂 visual-pushing-grasping
CreateAMind
3+阅读 · 2018年5月25日
Hierarchical Disentangled Representations
CreateAMind
4+阅读 · 2018年4月15日
【学习】Hierarchical Softmax
机器学习研究会
4+阅读 · 2017年8月6日
Auto-Encoding GAN
CreateAMind
7+阅读 · 2017年8月4日
Top
微信扫码咨询专知VIP会员