11 research outputs found
Partially distributed coordination with Reo and constraint automata
Algorithms and the Foundations of Software technolog
PrDK: Protocol programming with automata
We present PrDK: a development kit for programming protocols. PrDK is based on syntactic separation of process code, presumably written in an existing general-purpose language, and protocol code, written in a domain-specific language with explicit, high-level elements of syntax for programming protocols. PrDK supports two complementary syntaxes (one graphical, one textual) with a common automata-theoretic semantics. As a tool for construction of systems, PrDK consists of syntax editors, a translator, a parser, an interpreter, and a compiler into Java. Performance in the NAS Parallel Benchmarks is promising
Treo: Textual Syntax for Reo Connectors
Reo is an interaction-centric model of concurrency for compositional
specification of communication and coordination protocols. Formal verification
tools exist to ensure correctness and compliance of protocols specified in Reo,
which can readily be (re)used in different applications, or composed into more
complex protocols. Recent benchmarks show that compiling such high-level Reo
specifications produces executable code that can compete with or even beat the
performance of hand-crafted programs written in languages such as C or Java
using conventional concurrency constructs.
The original declarative graphical syntax of Reo does not support intuitive
constructs for parameter passing, iteration, recursion, or conditional
specification. This shortcoming hinders Reo's uptake in large-scale practical
applications. Although a number of Reo-inspired syntax alternatives have
appeared in the past, none of them follows the primary design principles of
Reo: a) declarative specification; b) all channel types and their sorts are
user-defined; and c) channels compose via shared nodes. In this paper, we offer
a textual syntax for Reo that respects these principles and supports flexible
parameter passing, iteration, recursion, and conditional specification. In
on-going work, we use this textual syntax to compile Reo into target languages
such as Java, Promela, and Maude.Comment: In Proceedings MeTRiD 2018, arXiv:1806.0933
Connectors meet Choreographies
We present Cho-Reo-graphies (CR), a new language model that unites two
powerful programming paradigms for concurrent software based on communicating
processes: Choreographic Programming and Exogenous Coordination. In CR,
programmers specify the desired communications among processes using a
choreography, and define how communications should be concretely animated by
connectors given as constraint automata (e.g., synchronous barriers and
asynchronous multi-casts). CR is the first choreography calculus where
different communication semantics (determined by connectors) can be freely
mixed; since connectors are user-defined, CR also supports many communication
semantics that were previously unavailable for choreographies. We develop a
static analysis that guarantees that a choreography in CR and its user-defined
connectors are compatible, define a compiler from choreographies to a process
calculus based on connectors, and prove that compatibility guarantees
deadlock-freedom of the compiled process implementations
Modular Programming of Synchronization and Communication among Tasks in Parallel Programs
Implementing synchronization and communication among tasks in parallel programs is a major challenge. We present a high-level DSL geared toward this challenge, by generalizing the existing protocol language Reo from supporting only a compile-time/statically set number of tasks (unsuitable for parallel programming), to supporting also a run-time/dynamically set number of tasks. Our contribution comprises new syntax, a new compilation/execution approach, and experimental results. Most surprisingly, the new approach can outperform the existing approach, even though the new approach requires more work to be done at run-time
Data optimizations for constraint automata
Constraint automata (CA) constitute a coordination model based on finite
automata on infinite words. Originally introduced for modeling of coordinators,
an interesting new application of CAs is implementing coordinators (i.e.,
compiling CAs into executable code). Such an approach guarantees
correctness-by-construction and can even yield code that outperforms
hand-crafted code. The extent to which these two potential advantages
materialize depends on the smartness of CA-compilers and the existence of
proofs of their correctness.
Every transition in a CA is labeled by a "data constraint" that specifies an
atomic data-flow between coordinated processes as a first-order formula. At
run-time, compiler-generated code must handle data constraints as efficiently
as possible. In this paper, we present, and prove the correctness of two
optimization techniques for CA-compilers related to handling of data
constraints: a reduction to eliminate redundant variables and a translation
from (declarative) data constraints to (imperative) data commands expressed in
a small sequential language. Through experiments, we show that these
optimization techniques can have a positive impact on performance of generated
executable code