Just like any other branch of mathematics, denotational semantics of programming languages should be formalised in type theory, but adapting traditional domain theoretic semantics, as originally formulated in classical set theory to type theory has proven challenging. This paper is part of a project on formulating denotational semantics in type theories with guarded recursion. This should have the benefit of not only giving simpler semantics and proofs of properties such as adequacy, but also hopefully in the future to scale to languages with advanced features, such as general references, outside the reach of traditional domain theoretic techniques. Working in Guarded Dependent Type Theory (GDTT), we develop denotational semantics for FPC, the simply typed lambda calculus extended with recursive types, modelling the recursive types of FPC using the guarded recursive types of GDTT. We prove soundness and computational adequacy of the model in GDTT using a logical relation between syntax and semantics constructed also using guarded recursive types. The denotational semantics is intensional in the sense that it counts the number of unfold-fold reductions needed to compute the value of a term, but we construct a relation relating the denotations of extensionally equal terms, i.e., pairs of terms that compute the same value in a different number of steps. Finally we show how the denotational semantics of terms can be executed inside type theory and prove that executing the denotation of a boolean term computes the same value as the operational semantics of FPC.
The clocks they are adjunctions:Denotational semantics for Clocked Type Theory
Clocked类型论(Clotted Type Theory,CloTT)是一种用于保护递归的类型论,可用于使用共归纳类型进行编程,允许将生产力编码在类型中,并用于使用步骤索引的抽象形式来推理高级程序设计语言功能。CloTT之前已经被证明具有许多语法属性,包括强规范化,规范性和类型检查的可判定性。在本文中,我们为CloTT提供了一个有用的指称语义,例如,用于研究未来的CloTT扩展,如路径类型。构建这个模型的主要挑战是对CloTT中用于共归纳类型的共归纳推理的滴答概念进行建模。我们建立在一个以前用于对保护递归进行建模的类别上,但是在这个类别中没有ticks对象,因此不能使用标准工具对上下文中的tick假设进行建模。相反,我们展示了如何使用伴随函子来建模滴答,以及如何使用语义替换来建模滴答常数。
Andrew Pitts的域的关系属性框架是定义域上的谓词或关系的强大方法,其应用范围从程序等价的推理原则到连接指称语义和操作语义的充分性证明。它的主要吸引力是处理递归定义,显然是没有良好的基础:只要相应的域也是递归定义的,其递归模式与关系的定义适当地对齐,框架可以保证它们的存在。皮茨最初的发展使用Knaster-Tarski不动点定理作为关键成分。在这些笔记中,我展示了如何他的建设可以被看作是一个例子,其他关键的不动点定理:逆极限建设,巴拿赫不动点定理和克莱因不动点定理。这种联系强调了皮茨的构造是如何与构造基本递归域本身的方法紧密联系在一起的,也与基于保护递归或步进索引的技术紧密联系在一起,这些技术在过去二十年中变得流行。
Abstract Compilation as Abstraction of Operator Semantics, applied to Cost Analysis
Universidad Politécnica de Madrid(马德里理工大学);IMDEA Software Institute(IMDEA软件研究所);Spanish Council for Scientific Research (CSIC)(西班牙国家研究委员会);Computer Science Laboratory of Sorbonne University (LIP6)(索邦大学计算机科学实验室);STMicroelectronics(意法半导体)