• No se han encontrado resultados

A PORTACIONES PARA UN ESCENARIO TERRITORIAL DESEABLE

CIUDADANÍA Y TERRITORIO EN EL MEDIO VINALOPÓ

OBERVACIÓN PARTICIPADA

6.2. E L MARCO LEGAL DE LA PARTICIPACIÓN CIUDADANA

6.3.2. A PORTACIONES PARA UN ESCENARIO TERRITORIAL DESEABLE

The PeaCE Environment [143] specifies a system level design with a heterogeneous composi- tion of three models of computation. The PeaCE environment provides seamless co-design flow from functional simulation to system synthesis, utilizing the features of the formal mod- els maximally during the whole design process. This framework is based on the Ptolemy project [144]. When dealing with C/C++ specifications, the Peace approach, however, does not propose an automatic procedure to transform this specification into dataflow graphs. SystemCoDesigner [145] is an actor-oriented approach using a high-level language named SysteMoC, which is built on top of SystemC. It generates HW-SW SoC with automatic design space exploration techniques. The model is translated into behavioral SystemC model as a starting point for HW and SW synthesis. The HW synthesis is delegated to a commercial tool, viz. Forte’s Cynthesizer, which generates RTL code from their SystemC intermediate model. Hardware/Software Co-Design based on RVC-CAL programming language has been studied in all steps of this thesis design flow. A first approach on CAL and RVC-CAL simulation and hardware code generation was provided by the OpenDF [146, 147] framework developed by Xilinx. An alternative to OpenDF for software synthesis called Open RVC-CAL Compiler has been effectuated in [148] and it is the compiler infrastructure used in this thesis. A third experimental compiler infrastructure for CAL developed by Ericsson is called Caltoopia and described in [149]. Hardware and C++ software code generation for Orcc were firstly introduced in [2, 3] and further developed in this thesis. Moreover, Interface synthesis for heterogeneous platforms is presented in [150]. Furthermore, a design space exploration for RVC-CAL dataflow programs is discussed in [10, 7]. Finally, a complete Co-Design environment is presented in [9, 19].

Actor and Dataflow Machines [151, 6] is a machine model for dataflow actors that focuses on minimizing the overhead of action selection for efficient implementations of static and dynamic dataflow programs. Actor machines are used to reduce the runtime testing of con- ditions, also actor machines can be composed to eliminate testing of port conditions. For this thesis Actor Machines were not used due to the late arrival of a compiler infrastructure supporting them. Finally, in the future works chapter is described that Dataflow Machines is going to replace the Orcc intermediate representation for a better software and hardware code generation that contains fewer tests in the action selection.

2.6 Conclusion

In this chapter, the state-of-the-art of high-level synthesis tools and design flows for het- erogeneous platforms were presented. It was shown that the behavioral description of the third-generation HLS tools is mainly C or C-like programming languages. In fact, C languages have an important limitation; they do not express parallelism. As discussed, to circumvent these obstacle vendors and academics have either modified the C language structures or they provide specialized library, or add pragmas that recognized only by a single tool. Alternative languages for HLS either offer a block-structure syntax or the possibility to design systems

that react continuously to their environment.

Three building blocks found in almost all HLS are also introduced and discussed. Those are scheduling of operators, pipelining, and power optimization. The list of the most used scheduling algorithm is given and two types of scheduling problems were considered: time constrained and resource-constrained scheduling. On one hand, the ILP approach solves the time-constrained problem but it has long time executions. On the contrary, FDS finds a solution quickly, but the optimality is not guaranteed. The Iterative Rescheduling improves an initial schedule generated by one the previous schedulers. Moreover, list-scheduling solved the problem of resource scheduling. As discussed, pipelining optimization is a time and resource constrained scheduling problem with the purpose to increase the frequency of the overall system. Power saving methodologies are related to the technology that is being used. Most of the introduced methodologies and strategies are for ASICs, but there is a growing interest for power saving techniques for FPGAs. In addition, there is no strategy that helps to reduce the dynamic power dissipation for dynamic dataflow programs. Thus, power saving techniques are applied or to static dataflow programs or synchronous or the power reduction is effectuated statically during synthesis. A solution for reducing the dynamic power dissipation caused by flip flop switching activities and extends the state-of-the-art in clock-gating is given in Chapter 6.

Furthermore, design flow for hardware and software Co-Design were presented. Each design- flow uses a high-level behavioral description for representing a design, mainly a derivative of C language. In contrast, LabView’s behavioral description is a schematic based one. Matlab, Syndex, Deadalus and others provides also a graphical representation of the dataflow depen- dencies between the process. In addition, part of tools are using a single dataflow model of computations such as the Kahn Process Network or in Mescal a combination of models of computation is used. Finally, an RVC-CAL based flow were also introduced. In contrast, with other design flows the RVC-CAL design flow, which is described and provided with this thesis, permits the description of dynamic systems from a single representation. Moreover, it offers support for both hardware and software processing elements, and a design space exploration that permits the performance estimation and refactoring directions that can be applied for accelerating the system latency (Chapter 5).

3

CAL Dataflow Programming Language

3.1 Introduction

Compiler Infrastructure Code Generation Synthesis or Compilation Implementation Profiling and Analysis Performance Estimation RVC-CAL (Behavioral Description) Architecture Constraints R ef ac to ri n g D ir e ct io n s C o m p il e r D ir ec ti ve s Action FSM Guarded atomic Action

Point to point, buffered Token passing Connection

Encapsulated State

Actor

Actor

Figure 3.1 – RVC-CAL as the Behavioral Description in the Design Flow.

The emergence of parallel processing elements such as many-cores/multi-cores, FPGAs, GPGPUs demands to rethink the way of programming them. It is widely recognized that programming parallel platforms is difficult and tedious. In addition, heterogeneous platforms consisting on parallel processing elements is becoming a standard on personal computers, a combination of multi-core processors and massively parallel GPUs, and also the introduction of MPSoCs with programmable logic in the industry demands higher level of abstraction. A key to the heterogeneous system level design is the notion of models of computation (MoC) [152]. A MoC is the semantics of the interactions between modules. Moreover, it is the model or the specification principles of a design. Furthermore, MoCs relate strongly to the design style but is not necessary to refer to the implementation technology. Classes of MoCs include:

Imperative, Finite State Machine, Discrete Event, Synchronous Languages, and Dataflow. The imperative MoC executes the modules sequentially to accomplish a task. In Finite State Machines MoC, an enumeration of set of states specifies the steps to achieve a task. In the Discrete Event MoC, modules react to event that occurs at a given time instant and produces other events at the same time instant or at some future time instant. In Synchronous Languages MoC, modules simultaneously react to a set of input events and instantaneously produce output events.

A Dataflow MoC, is conceptually represented as a direct graph where nodes, called actors, represent computational units, while edges describes communication channels on which tokens are flowing. A token is an atomic piece of data. Dataflow graphs are often used to represent data-dominated systems, like signal processing applications. Using Dataflow MoC in such application domains often leads to behavioral descriptions that are much closer to the original conception of the algorithms than if an imperative MoC was used. Dataflow models also date back to the early 1970s, starting with seminal work by Dennis [153] and Kahn [88]. Several execution models that define the behavior of a dataflow program have been introduced in literature [88, 152]. A Dataflow MoC may constrain the behavior of an actor, how actors are executed relatively to each other, and aspects of their interaction with one another. As a result, different MoCs offer different degrees of analyzability and compile-time schedulability of dataflow programs written in them, and permit different guarantees (such as absence of deadlocks or boundedness of buffers) to be inferred from them.

The first two MoC are fundamentally sequential and the last three are concurrent. In fact it is possible to use the first two on parallel processing elements and the last three on sequential machines. Thus, there is a distinction between MoCs and the way that they are implemented. As a consequence, the efficiency might take a hit. In heterogeneous platforms there should be a separation of tasks depending properties of a design. Modules that are sequential should preferably execute on sequential platforms and parallel ones should perform on concurrent machines. In effect, for system level design either should be a mix of different MoCs or the properties and semantics of a single MoC should be rich enough to support heterogeneous designs.

A potential candidate for heterogeneous system level design is RVC-CAL. RVC-CAL is dataflow programming language that is based on the Dataflow MoC and it has the property to ex- press applications as network processes. In fact, it offers parallelism scalability, modularity, scheduling by finite state machines, portability, and adaptivity properties that are necessary to unify the system level design for heterogeneous platforms. The MoC underlying the dataflow networks that are expressed using the CAL formal language is based on the dataflow process

networks (DPN) model [152]. In addition to the properties of dataflow mentioned above, each

DPN actor executes a sequence of discrete computational steps, called firings. In each step, an actor may (a) consume a finite number of input tokens, (b) produce a finite number of output tokens, and (c) modify its internal state, if it has any. In an actor language such as CAL [154]

3.1. Introduction

and its subset RVC-CAL this behavior is specified as one or more actions. Each action describes the conditions under which it may be fired (which may include the availability and values of input tokens, and the actor’s state), and also what happens when it fires, i.e. how many tokens are consumed and produced at each port, the values of the output tokens, and how the actor state is modified. The execution of such an actor consists of two alternating phases: the determination of an action who firing conditions are fulfilled (including a choice if there is more than at some point), and the execution of that action itself.

Table 3.1 – System-Level Requirements and Coverage. Withlsupported,wpartially supported,

andmnot supported.

C C++ O penC L Jav a VHDL Ver il og H ar dw a reC S pecC R V C -C AL Behavioral hierarchy m m w m m m m l l Structural hierarchy m m m m l l l l l Concurrency m w l w l l l l l Synchronization m m l w l l l l l Exception handling w l l l l l m l m Timing m m m m l l w l m State transitions m m w m m m m l l

Composition data types l l l l w w m l w

Heterogeneous & CoDesign m m l m m m m m l

Fine-Grain Profiling m m w m m m m m l

Table 3.1 compares traditional languages against a set of language requirements. Partial values are retrieved from [48]. RVC-CAL supports the following behavioral hierarchies: sequen- tial execution inside actions, FSM by the finite state machine of the actor, concurrent and pipelined execution by the MoC. In addition, RVC-CAL supports structural hierarchy by actor composition. An actor composition may contain another actor composition. Furthermore, Synchronization is provided by the FIFO queues that the actors are interconnected. Exception handling is not currently supported. RVC-CAL is high-level language that makes a total ab- straction of time. Moreover, RVC-CAL support list types and future version will also support composite types. Finally, this thesis demonstrates that RVC-CAL is a potential candidate heterogeneous system level design and that it supports fine-grain profiling for hardware and software processing elements.

Before describing the CAL programming language and its features, a brief introduction to the Process Networks and the Model of Computations that CAL uses is given in the next section.