559 research outputs found
Distilling Abstract Machines (Long Version)
It is well-known that many environment-based abstract machines can be seen as
strategies in lambda calculi with explicit substitutions (ES). Recently,
graphical syntaxes and linear logic led to the linear substitution calculus
(LSC), a new approach to ES that is halfway between big-step calculi and
traditional calculi with ES. This paper studies the relationship between the
LSC and environment-based abstract machines. While traditional calculi with ES
simulate abstract machines, the LSC rather distills them: some transitions are
simulated while others vanish, as they map to a notion of structural
congruence. The distillation process unveils that abstract machines in fact
implement weak linear head reduction, a notion of evaluation having a central
role in the theory of linear logic. We show that such a pattern applies
uniformly in call-by-name, call-by-value, and call-by-need, catching many
machines in the literature. We start by distilling the KAM, the CEK, and the
ZINC, and then provide simplified versions of the SECD, the lazy KAM, and
Sestoft's machine. Along the way we also introduce some new machines with
global environments. Moreover, we show that distillation preserves the time
complexity of the executions, i.e. the LSC is a complexity-preserving
abstraction of abstract machines.Comment: 63 page
Space-Aware Ambients and Processes
Resource control has attracted increasing interest in foundational research on distributed systems. This paper focuses on space control and develops an analysis of space usage in the context of an ambient-like calculus with bounded capacities and weighed processes, where migration and activation require space. A type system complements the dynamics of the calculus by providing static guarantees that the intended capacity bounds are preserved throughout the computation
On the Relative Usefulness of Fireballs
In CSL-LICS 2014, Accattoli and Dal Lago showed that there is an
implementation of the ordinary (i.e. strong, pure, call-by-name)
-calculus into models like RAM machines which is polynomial in the
number of -steps, answering a long-standing question. The key ingredient
was the use of a calculus with useful sharing, a new notion whose complexity
was shown to be polynomial, but whose implementation was not explored. This
paper, meant to be complementary, studies useful sharing in a call-by-value
scenario and from a practical point of view. We introduce the Fireball
Calculus, a natural extension of call-by-value to open terms for which the
problem is as hard as for the ordinary lambda-calculus. We present three
results. First, we adapt the solution of Accattoli and Dal Lago, improving the
meta-theory of useful sharing. Then, we refine the picture by introducing the
GLAMoUr, a simple abstract machine implementing the Fireball Calculus extended
with useful sharing. Its key feature is that usefulness of a step is
tested---surprisingly---in constant time. Third, we provide a further
optimization that leads to an implementation having only a linear overhead with
respect to the number of -steps.Comment: Technical report for the LICS 2015 submission with the same titl
Using Pi-Calculus Names as Locks
Locks are a classic data structure for concurrent programming. We introduce a
type system to ensure that names of the asynchronous pi-calculus are used as
locks. Our calculus also features a construct to deallocate a lock once we know
that it will never be acquired again. Typability guarantees two properties:
deadlock-freedom, that is, no acquire operation on a lock waits forever; and
leak-freedom, that is, all locks are eventually deallocated.
We leverage the simplicity of our typing discipline to study the induced
typed behavioural equivalence. After defining barbed equivalence, we introduce
a sound labelled bisimulation, which makes it possible to establish equivalence
between programs that manipulate and deallocate locks.Comment: In Proceedings EXPRESS/SOS2023, arXiv:2309.0578
Dual-Context Calculi for Modal Logic
We present natural deduction systems and associated modal lambda calculi for
the necessity fragments of the normal modal logics K, T, K4, GL and S4. These
systems are in the dual-context style: they feature two distinct zones of
assumptions, one of which can be thought as modal, and the other as
intuitionistic. We show that these calculi have their roots in in sequent
calculi. We then investigate their metatheory, equip them with a confluent and
strongly normalizing notion of reduction, and show that they coincide with the
usual Hilbert systems up to provability. Finally, we investigate a categorical
semantics which interprets the modality as a product-preserving functor.Comment: Full version of article previously presented at LICS 2017 (see
arXiv:1602.04860v4 or doi: 10.1109/LICS.2017.8005089
A Categorical Normalization Proof for the Modal Lambda-Calculus
We investigate a simply typed modal -calculus,
, due to Pfenning, Wong and Davies, where we define a
well-typed term with respect to a context stack that captures the possible
world semantics in a syntactic way. It provides logical foundation for
multi-staged meta-programming. Our main contribution in this paper is a
normalization by evaluation (NbE) algorithm for which we
prove sound and complete. The NbE algorithm is a moderate extension to the
standard presheaf model of simply typed -calculus. However, central to
the model construction and the NbE algorithm is the observation of Kripke-style
substitutions on context stacks which brings together two previously separate
concepts, structural modal transformations on context stacks and substitutions
for individual assumptions. Moreover, Kripke-style substitutions allow us to
give a formulation for contextual types, which can represent open code in a
meta-programming setting. Our work lays the foundation for extending the
logical foundation by Pfenning, Wong, and Davies towards building a practical,
dependently typed foundation for meta-programming
A Graph Model for Imperative Computation
Scott's graph model is a lambda-algebra based on the observation that
continuous endofunctions on the lattice of sets of natural numbers can be
represented via their graphs. A graph is a relation mapping finite sets of
input values to output values.
We consider a similar model based on relations whose input values are finite
sequences rather than sets. This alteration means that we are taking into
account the order in which observations are made. This new notion of graph
gives rise to a model of affine lambda-calculus that admits an interpretation
of imperative constructs including variable assignment, dereferencing and
allocation.
Extending this untyped model, we construct a category that provides a model
of typed higher-order imperative computation with an affine type system. An
appropriate language of this kind is Reynolds's Syntactic Control of
Interference. Our model turns out to be fully abstract for this language. At a
concrete level, it is the same as Reddy's object spaces model, which was the
first "state-free" model of a higher-order imperative programming language and
an important precursor of games models. The graph model can therefore be seen
as a universal domain for Reddy's model
Modelling MAC-Layer Communications in Wireless Systems
We present a timed process calculus for modelling wireless networks in which
individual stations broadcast and receive messages; moreover the broadcasts are
subject to collisions. Based on a reduction semantics for the calculus we
define a contextual equivalence to compare the external behaviour of such
wireless networks. Further, we construct an extensional LTS (labelled
transition system) which models the activities of stations that can be directly
observed by the external environment. Standard bisimulations in this LTS
provide a sound proof method for proving systems contextually equivalence. We
illustrate the usefulness of the proof methodology by a series of examples.
Finally we show that this proof method is also complete, for a large class of
systems
- …