Co-Synthesis Using a Partial Order Based Model of Concurrency Francisco Assis Moreira do Nascimento Wolfgang Rosenstiel University of Tubingen, Wilhelm Schickard Institute
moreira,
[email protected] http://www-ti.informatik.uni-tuebingen/~moreira,~rosen
Abstract
We de ne a Partial Order based Model (POM) as an alternative to model concurrency at a high level of abstraction. The model permits a concise symbolic representation, mainly for systems with high degree of parallelism, and the use of ecient reachability analysis techniques based on partial order reductions. In our design approach, from a speci cation without details of implementation modeled with the POM, the co-synthesis system generates an implementation consisting of hardware and software parts. In this paper we introduce the partial order based model for concurrency and how to use it in modeling at the system level; we present a symbolic representation for the model and its implementation using BDDs; we give reachability analysis algorithms that can be used by performance analysis tasks and formal veri cation; and nally we introduce our co-synthesis approach based on the model.
Keywords
Co-Synthesis, Partial Order, Reachability, Concurrency, Symbolic Techniques
I. Introduction
In the last years several formal models have been developed to support the design of concurrent systems [1]. The models provide formalisms to allow unambiguous design speci cations and transformations on the speci cation. The design transformations incorporate details to the speci cation based on design decisions and should be correct, i.e., preserve the functionality of the original speci cation. Our work is oriented to the co-synthesis of embedded distributed systems, which can be characterized as: consisting of concurrent processes that are constantly reacting to the occurrence of external events; the concurrent processes communicate in order to cooperate and so realize the system functionality; the timing of the operations performed by the processes is subject to constraints that must be satis ed in order to the system operates correctly. Since the objective of our co-synthesis approach is to generate an ecient implementation for a given such system, we are interested in a formalism able to model concurrent, communicating, reactive behaviors while abstracting from implementation details. Most of the existing approaches to co-synthesis (for example, Castle [2], CAMAD [3], COSMOS [4], Olympus/Vulcan [5], PMOSS [6]) use procedural languages to capture the system speci cation and control/data ow graphs (CDFGs) as intermediate representation, on which the synthesis algorithms are applied. This internal representation is obtained by the parsing and data/control ow analysis [7] of the system speci cation. This makes possible to formulate the co-synthesis approaches independent of the language used to specify the system. But with CD-
FGs it is very dicult to implement design transformations that alter the control and/or data ow of the speci cation. In our approach instead of developing a speci cation language, we are also more interested in de ning an intermediate representation, which should be adequate to capture formally and concisely the various aspects of concurrency, and in developing ecient analysis and synthesis algorithms based on this intermediate representation. The use of partial order to the modeling of concurrent systems has already been proposed by Lamport [8] and Pratt [9]. Our work is strongly based on the Chu spaces developed by Pratt and Gupta[10], which is a non interleaving, event-based model for concurrency. We have adapted it in order to model reactive systems using an approach based on the concept of relations between events from the event structure model [11] and the Chu space semantics for these relations in terms of logical formulas. The so resulting Partial Order based Model (POM) is used in our approach as an intermediate representation, which permits a concise symbolic representation, mainly for systems with high degree of parallelism. The POM model makes also possible an ecient BDD based implementation of analysis and synthesis algorithms. In this paper we concentrate on the modeling and reachability analysis based on the POM model and give only a brief desccription of our co-synthesis approach. The paper is organized as follows: The section II presents the modeling using the POM Model; the section III describes the reachability analysis algorithms based on the model and their application in our co-synthesis approach, which is presented in the section IV; nally in the section V we present some preliminary results and conclusions. II. System Modeling
In our approach the modeling of a system for co-synthesis consists of system speci cation, design constraints and hardware/software libraries. The system speci cation describes the system in terms of a set of modules composed of concurrent intercommunicating processes. Each module has an interface to the environment and channel declarations for the communications between the processes inside the module. Each process consists of declaration of variables and a process body described in a procedural language with assignment, conditional and iterative constructs. In the description of the process we also have send and receive state-
ments for the communication between the processes and a fork/join construct to specify intra-process concurrency. The behavior of each process is captured by a POM based representation (Behavioral POM { BPOM) which abstracts the control/data ow structure of the process. Diering from the Control/Data Flow Graph based representations, the intermediate representation based on the model captures all the paralelism in the system speci cation and does not re ect the structure imposed by the speci c constructs of the speci cation language. Through the composition of the BPOM of the processes in a module we can also obtain a BPOM for the module. A. Partial Order Based Model for Concurrency A POM consists of a set A of events (each event represent an action) and a set X of states (representing the possible or permitted states). De nition 1 (POM) A POM is a Chu space C given by the tuple (A; X; R), where A = fa0 ; a1 ; : : : ; an g is a set of events, X = fx0 ; x1 ; : : : ; xm g is a set of states, and R : A X ! f0; 1g represents the occurrence relation, i.e., R(a; x) = 1 if the event a has occurred in the state x and R(a; x) = 0, otherwise. Each state xi 2 2A is de ned in terms of R as: xi = faja 2 A and R(a; xi ) = 1g De nition 2 (Logical Representation) We de ne the logical representation fC of the POM _ C as: fxi fC = 0