EN FR
EN FR




Application Domains
Bibliography




Application Domains
Bibliography


Section: Scientific Foundations

A declarative design language

Signal  [34] , [48] , [49] , [41] is a declarative design language expressed within the polychronous model of computation. In Signal, a process P is an infinite loop that consists of the synchronous composition P|Q of simultaneous equations x:=yfz over signals named x,y,z. The restriction of a signal name x to a process P is noted P/x.

P,Q::=x:=yfz|P/x|P|Q

Equations x:=yfz in Signal more generally denote processes that define timing relations between input and output signals. There are four primitive combinators in Signal:

  • delay x:=y$𝚒𝚗𝚒𝚝v, initially defines the signal x by the value v and then by the previous value of the signal y. The signal y and its delayed copy x=y$𝚒𝚗𝚒𝚝v are synchronous: they share the same set of tags t 1 ,t 2 ,. Initially, at t 1 , the signal x takes the declared value v and then, at tag t n , the value of y at tag t n-1 .

    y t 1 ,v 1 t 2 ,v 2 t 3 ,v 3 y$𝚒𝚗𝚒𝚝v t 1 ,v t 2 ,v 1 t 3 ,v 2
  • sampling x:=y𝚠𝚑𝚎𝚗z, defines x by y when z is true (and both y and z are present); x is present with the value v 2 at t 2 only if y is present with v 2 at t 2 and if z is present at t 2 with the value true. When this is the case, one needs to schedule the calculation of y and z before x, as depicted by y t 2 x t 2 z t 2 .

  • merge x:=y𝚍𝚎𝚏𝚊𝚞𝚕𝚝z, defines x by y when y is present and by z otherwise. If y is absent and z present with v 1 at t 1 then x holds (t 1 ,v 1 ). If y is present (at t 2 or t 3 ) then x holds its value whether z is present (at t 2 ) or not (at t 3 ).

    y t 2 ,v 2 y𝚠𝚑𝚎𝚗z t 2 ,v 2 z t 1 ,0 t 2 ,1 y t 2 ,v 2 t 3 ,v 3 y𝚍𝚎𝚏𝚊𝚞𝚕𝚝z t 1 ,v 1 t 2 ,v 2 t 3 ,v 3 z t 1 ,v 1

The structuring element of a Signal specification is a process. A process accepts input signals originating from possibly different clock domains to produce output signals when needed. This allows, for instance, to specify a counter where the inputs tick and reset and the output value have independent clocks. The body of counter consists of one equation that defines the output signal value . Upon the event reset , it sets the count to 0. Otherwise, upon a tick event, it increments the count by referring to the previous value of value and adding 1 to it. Otherwise, if the count is solicited in the context of the counter process (meaning that its clock is active), the counter just returns the previous count without having to obtain a value from the tick and reset signals.

 

    process counter = (? event tick, reset; ! integer value;)

        (| value := (0 when reset)

            default ((value$ init 0 + 1) when tick)

            default (value$ init 0)

        |);

 

A Signal process is a structuring element akin to a hierarchical block diagram. A process may structurally contain sub-processes. A process is a generic structuring element that can be specialized to the timing context of its call. For instance, the definition of a synchronized counter starting from the previous specification consists of its refinement with synchronization. The input tick and reset clocks expected by the process counter are sampled from the boolean input signals tick and reset by using the when tick and when reset †expressions. The count is then synchronized to the inputs by the equation reset ^= tick ^= value .

 

    process synccounter = (? boolean tick, reset; ! integer value;)

        (| value := counter (when tick, when reset)

         | reset ^= tick ^= value

         |);