CRIL: A Concurrent Reversible Intermediate Language

09/13/2023
by   Shunya Oguchi, et al.
0

We present a reversible intermediate language with concurrency for translating a high-level concurrent programming language to another lower-level concurrent programming language, keeping reversibility. Intermediate languages are commonly used in compiling a source program to an object code program closer to the machine code, where an intermediate language enables behavioral analysis and optimization to be decomposed in steps. We propose CRIL (Concurrent Reversible Intermediate Language) as an extension of RIL used by Mogensen for a functional reversible language, incorporating a multi-thread process invocation and the synchronization primitives based on the P-V operations. We show that the operational semantics of CRIL enjoy the properties of reversibility, including the causal safety and causal liveness proposed by Lanese et al., checking the axiomatic properties. The operational semantics is defined by composing the bidirectional control flow with the dependency information on updating the memory, called annotation DAG. We show a simple example of `airline ticketing' to illustrate how CRIL preserves the causality for reversibility in imperative programs with concurrency.

READ FULL TEXT

page 1

page 2

page 3

page 4

research
06/19/2018

A Theory of Reversibility for Erlang

In a reversible language, any forward computation can be undone by a fin...
research
12/07/2022

revTPL: The Reversible Temporal Process Language

Reversible debuggers help programmers to find the causes of misbehaviour...
research
07/25/2017

Design and Implementation of a Reversible Object-Oriented Programming Language

High-level reversible programming languages are few and far between and ...
research
05/10/2021

How could Neural Networks understand Programs?

Semantic understanding of programs is a fundamental problem for programm...
research
12/06/2022

Branching execution symmetry in Jeopardy by available implicit arguments analysis

When the inverse of an algorithm is well-defined – that is, when its out...
research
02/16/2022

Mechanization of LAGC Semantics in Isabelle

Formal programming language semantics are imperative when trying to veri...
research
03/10/2020

Differentiate Everything with a Reversible Programming Language

This paper considers the source-to-source automatic differentiation (AD)...

Please sign up or login with your details

Forgot password? Click here to reset