1,634 research outputs found
Parameter passing in nondeterministic recursive programs
AbstractCall by value and call by name have some subtleties when used in a nondeterministic programming language. A common formalism is used to establish the denotational semantics of recursive programs called by name and called by value. Ashcroft and Hennessy introduced the idea of differentiating between selecting arguments from a set of arguments at the point of invocation and selecting arguments during the run of the procedure. This distinction is shown to be independent of the evaluation according to value or name, giving rise to four possible parameter passing methods, all of which have a suitable least fixed point semantics
Fifty years of Hoare's Logic
We present a history of Hoare's logic.Comment: 79 pages. To appear in Formal Aspects of Computin
Recommended from our members
A general theory of action languages
We present a general theory of action-based languages as a paradigm, for the description, of those computational
systems which include elements of concurrency and networking, and extend this approach
to describe dist.ributed systems and also t,o describe the interaction of a system, with an environment.
As part of this approach we introduce the Action Language as a common model for the class of nondeterministic
concurrent programming languages and define its intensional and interaction semantics
in terrors of continuous transformation of environment behavior. This semantics i.s specialized for
programs with stores, and extended to describe distributed computations
Interacting via the Heap in the Presence of Recursion
Almost all modern imperative programming languages include operations for
dynamically manipulating the heap, for example by allocating and deallocating
objects, and by updating reference fields. In the presence of recursive
procedures and local variables the interactions of a program with the heap can
become rather complex, as an unbounded number of objects can be allocated
either on the call stack using local variables, or, anonymously, on the heap
using reference fields. As such a static analysis is, in general, undecidable.
In this paper we study the verification of recursive programs with unbounded
allocation of objects, in a simple imperative language for heap manipulation.
We present an improved semantics for this language, using an abstraction that
is precise. For any program with a bounded visible heap, meaning that the
number of objects reachable from variables at any point of execution is
bounded, this abstraction is a finitary representation of its behaviour, even
though an unbounded number of objects can appear in the state. As a
consequence, for such programs model checking is decidable.
Finally we introduce a specification language for temporal properties of the
heap, and discuss model checking these properties against heap-manipulating
programs.Comment: In Proceedings ICE 2012, arXiv:1212.345
Recommended from our members
Interaction of agents and environments
A new abstract model of interaction between agents and environments considered as objects of different types is introduced. Agents are represented by means of labelled transition systems considered up to bisimilarity. The equivalence of agents is characterised in terms of an algebra of behaviours which is a continuous algebra with approximation and two operations: nondeterministic choice and prefixing. Environments are introduced as agents supplied with an insertion function which takes the behaviour of an agent and the behaviour of an environment as arguments and returns the new behaviour of an environment. Arbitrary continuous functions can be used as insertion functions, and we use functions defined by means of rewriting logic as computable ones. The transformation of environment behaviours defined by the insertion function also defines a new type of agent equivalence--- insertion equivalence. Two behaviours are insertion equivalent if they define the same transformation of an environment. The properties of this equivalence are studied. Three main types of insertion functions are used to develop interesting applications: one-step insertion, head insertion, and look-ahead insertion functions
A Linear First-Order Functional Intermediate Language for Verified Compilers
We present the linear first-order intermediate language IL for verified
compilers. IL is a functional language with calls to a nondeterministic
environment. We give IL terms a second, imperative semantic interpretation and
obtain a register transfer language. For the imperative interpretation we
establish a notion of live variables. Based on live variables, we formulate a
decidable property called coherence ensuring that the functional and the
imperative interpretation of a term coincide. We formulate a register
assignment algorithm for IL and prove its correctness. The algorithm translates
a functional IL program into an equivalent imperative IL program. Correctness
follows from the fact that the algorithm reaches a coherent program after
consistently renaming local variables. We prove that the maximal number of live
variables in the initial program bounds the number of different variables in
the final coherent program. The entire development is formalized in Coq.Comment: Addressed comments from reviewers (ITP 2015): (1) Added discussion of
a paper in related work (2) Added definition of renamed-apart in appendix (3)
Formulation changes in a coupe of place
FliPpr: A Prettier Invertible Printing System
When implementing a programming language, we often write
a parser and a pretty-printer. However, manually writing both programs
is not only tedious but also error-prone; it may happen that a pretty-printed
result is not correctly parsed. In this paper, we propose FliPpr,
which is a program transformation system that uses program inversion
to produce a CFG parser from a pretty-printer. This novel approach
has the advantages of fine-grained control over pretty-printing, and easy
reuse of existing efficient pretty-printer and parser implementations
- …