Skip to main content
European Commission logo
italiano italiano
CORDIS - Risultati della ricerca dell’UE
CORDIS
CORDIS Web 30th anniversary CORDIS Web 30th anniversary

Differential Program Semantics

Periodic Reporting for period 4 - DIAPASoN (Differential Program Semantics)

Periodo di rendicontazione: 2023-09-01 al 2024-02-29

Modern software systems are heterogeneous and complex, and the way to tame their complexity so as to support analytical techniques consists in supporting modular forms of reasoning. Indeed, program semantics is traditionally centred around the notion of program identity, that is to say of program equivalence: a program is identified with its meaning, and programs are considered equal only if their meanings are exactly the same. This view has been extremely fruitful in the past, allowing for a deep understanding of highly interactive forms of computation, like those taking place in higher-order or concurrent programs. The byproducts of all this lie everywhere in computer science, from programming language design to verification methodologies. The emphasis on equality — as opposed to difference — is, however, not in line with the way programs are written and structured in modern complex software systems. Subtasks are delegated to pieces of code which behave as expected only up to a certain probability of error, and only if the environment in which they operate makes this possible deviation irrelevant. This phenomenon is ubiquitous, but particularly apparent in fields like approximate computing, machine learning, or cryptography. Notions of program distances measuring in an inherently quantitative way how far two programs are to each other (or how far a program is to its specification), have been almost neglected by the program semantics community until relatively recently, and still have a marginal role in theoretical computer science. DIAPASoN's goal is to study differences between programs as a constitutive and informative concept, rather than by way of relational reasoning. This is accomplished by generalising four major frameworks of program semantics, traditionally used for giving semantics to, comparing, proving properties of, and controlling the usage of resources of programs, namely logical relations, bisimulation, game semantics, and linear logic.
We are now at the end of the DIAPASoN project, and many interesting results have been obtained. Indeed, the injection of eight postdocs (Aurore Alcolei, Francesco Gavazzo, Guillaume Geoffrey, Paolo Pistone, Alexis Ghyselen, Maurizio Murgia, Davide Barbarossa, and Ken Sakayori) and three junior researchers (Andrea Colledan, Cecilia Di Florio and Giulia Giusti) in the workgroup allowed the team to work on the four WPs, and to obtain many timely and interesting results on all of them. Collaborations between the project participants was made possible by regular physical meetings at the host institution, weekly seminars, and online exchanges - a SLACK workplace specifically about DIAPASoN was created and used to exchange information between the project . Online collaborative tools proved to be very useful during the covid19 pandemic: lockdown was enforced in Italy starting from March 8th, 2020, and physical meetings at the host institution were impossible (until May 4th, 2020) and highly discouraged (until May 2022). The DIAPASoN kickoff meeting took place at IRIF (Paris) on February 26 to February 28, 2020, co-located with the CRECOGI and PPS workshops (see https://www.irif.fr/pps-pihoc-diapason2020). The second DIAPASoN meeting took place online in February 2021, again co-located with the PPS workshop. (see https://www.irif.fr/pps-pihoc-diapason2021). Given the high number of participants (more than one hundred researchers registered for the two events), this has been a very good occasion to share the first results obtained in the project with nearby research communities, and to receive feedback. There have been internal DIAPASoN workshops on July 2022 and April 2023. The final DIAPASoN workshop took place on January 9th, 2024. Results obtained in the project appeared in top journals and conferences on programming language theory, including ICALP, ESOP, POPL, LICS and SCP.
The research activity carried out in the DIAPASoN project was intense, involving the four WPs. In particular, the study of differential logical relations (WP1), namely of generalizations of logical relations capable of capturing differences between programs instead of mere equivalences, resulted in some novel and unexpected results. More specifically, a form of differential logical relation has been proved to form a model of the simply-typed lambda calculus without any linearity or affinity constraints, something impossible when differences are modeled as numerical values. The introduced notion of logical relation has been proved to enable a form of differential reasoning about programs in which the role of the context is taken into account. While differential logical relations provide a denotational semantics of higher-order types with a notion of program distance at each type, such distances do not constitute a metric in the standard sense. An alternative approach to differential semantics (WP1) has been introduced in which higher-order types are interpreted as generalized partial metric spaces, a class of metric spaces widely investigated in theoretical computer science. Still about logical relations, a simple form of open logical relations has been shown to be able to justify forward mode automatic differentiation in a higher-order setting. Our work on differential generalizations of bisimulation (WP2) has produced some interesting ideas; in particular, a variation on the well-known concept of subset construction seems to be the natural way to extend differential logical relations to a coinductive scenario, giving rise to a form of contextual behavioral metrics. About differential forms of game semantics (WP3), we started from the observation that programs are traditionally interpreted as strategies, and equality in those models capture (contextual) equivalence between programs. Building on this fundamental relation, we have been investigating how standard game models support notions of distance and how the latest can be meaningful in evaluating differences between programs. Still about WP3, a form of game model has been shown to support higher-order extensions of cryptographic primitives. Finally, geometry of interaction has been shown to give rise itself to a notion of metric which seems incomparable to the one derived from usual denotational models. About WP4, the work-package about differential ideas in logic (and in linear logic in particular), we have been able to precisely understand in which sense the notion of derivative from differential linear logic is different from the one from differential logical relations. Moreover, by exploiting the Curry-Howard correspondence, we have been working on an extension of Peano Arithmetic with probabilistic primitives, as a means to obtain a logical formalism for reasoning about properties of higher-order probabilistic programs. Many of the mentioned results have been submitted for publication, some of them already appearing in key conferences in the area of theoretical computer science and programming language theory.
Programming with Higher-Order Functions
Via Zamboni, in Bologna