Post on 31-Jan-2016
description
transcript
technische universiteit eindhoven
Department of Electrical EngineeringElectronic Systems
Liveness and Boundedness of Synchronous Data Flow Graphs
A.H. Ghamarian, M.C.W Geilen, T. Basten, B. Theelen, M. Mousavi, and S. Stuijk
2
Electronic Systems
Outline
Introduction Synchronous Data Flow Graphs (SDFGs) Definition of Liveness and Boundedness Live and Bounded SDFGs Live and Strictly Bounded SDFGs Live and Self-timed Bounded SDFGs Conclusions
intro sdf definitions boundedness strict bndss self-tmd bndss conclusions
3
Electronic Systems
Introduction
Streaming Multimedia and DSP Applications Throughput Buffer sizes …
SDFG Modeling and analysis Single and multiprocessor platforms
Given an SDFG,is it realizable within bounded memory while running forever ?
intro sdf definitions boundedness strict bndss self-tmd bndss conclusions
4
Electronic Systems
C,1
Structure of a (Timed) SDFG
channel (unbounded)
rate
token
execution time
actor
A,2 B,1
3
3
2
211
1
3
Self-loop channel
1 1
intro sdf definitions boundedness strict bndss self-tmd bndss conclusions
5
Electronic Systems
D,1
Behavior: Firing an Actor
C, 1
B, 1
A,1 1
1
1
2
2
3
4
5
2
23
2
1
intro sdf definitions boundedness strict bndss self-tmd bndss conclusions
6
Electronic Systems
Behavior: Execution and Self-timed Execution
An execution is a finite or infinite sequence of actor firings. An execution is maximal iff it is finite with no actor enabled in the
final state or if it is infinite. A self-timed execution is an execution in which each actor fires as
soon as it can fire.
intro sdf definitions boundedness strict bndss self-tmd bndss conclusions
7
Electronic Systems
Consistency and Repetition Vector
A,2 B,1 C,13
3
2
211
1
3
1.q(A)=1.q(A)
1.q(A)=1.q(B)
2.q(B)=3.q(C)
3.q(C)=2.q(B)
An SDFG is consistent iff q(A) > 0 for all actors A
Repetition vector q={(A,3), (B,3), (C,2)}
1 1
intro sdf definitions boundedness strict bndss self-tmd bndss conclusions
8
Electronic Systems
Liveness and Deadlock
An SDFG is live iff it has an execution in which all actors fire infinitely often.
An SDFG has a deadlock iff it has a maximal execution of finite length.
Consistent, but neither live nor deadlocked !
A,2 B,1 C,1
33
3
2
211
Cannot fire after one firing of B and C
A can fire infinitely often
1 1
intro sdf definitions boundedness strict bndss self-tmd bndss conclusions
9
Electronic Systems
Boundedness
An execution is bounded iff for all states of the execution the number of tokens in all channels is at most some bound.
SDFG bounded iff it has a bounded execution. ((un-)timed) Strictly bounded iff all possible executions are bounded. ((un-)timed) Self-timed bounded iff self-timed execution is bounded. (timed)
Necessary and sufficient conditions for an SDFG to be live in combination with each of the
three definitions of boundedness.
intro sdf definitions boundedness strict bndss self-tmd bndss conclusions
10
Electronic Systems
Liveness and Boundedness
A live SDFG is bounded iff it is consistent. A strongly connected SDFG is live iff it is deadlock free. If one strongly connected component (SCC) in an SDFG G
deadlocks then either G deadlocks or it is unbounded.
A,2 B,1 C,1
33
3
2
211
1
{(A,3), (B, 3), (C, 2)}
An SDFG is live and bounded iff it is consistent and all its SCCs are deadlock free.
1 1
intro sdf definitions boundedness strict bndss self-tmd bndss conclusions
11
Electronic Systems
Liveness and Strict Boundedness
A live SDFG is strictly bounded iff it is consistent and strongly connected.
An SDFG is live and strictly bounded iff it is deadlock free, consistent and strongly connected.
B,1 C,1
33
3
2
2
A,211
15
1 1
intro sdf definitions boundedness strict bndss self-tmd bndss conclusions
12
Electronic Systems
Throughput Definition
Actor throughput:The average number of firings of one actor per time unit in the self-
timed execution.
(Normalized) graph throughput (if SDFG is consistent):
firings of ( ) lim .
end time of these firingsk
k aTh a
( )min .
( )actorsa
Th a
q a
intro sdf definitions boundedness strict bndss self-tmd bndss conclusions
13
Electronic Systems
Local and Normalized Throughput
pa b
c Each firing of a provides tokens for p/c
firings of b.
( , ) ( / ) ( )NTh a b p c Th aNormalized actor throughput of a for b :
a,E
Local actor throughput : ( ) /LTh a x E
x
intro sdf definitions boundedness strict bndss self-tmd bndss conclusions
14
Electronic Systems
Throughput Relation between Actors
Throughput of each actor equals the minimum of its local throughput and normalized throughput of its predecessors.
b
c
d
a,1
14
2 3
2
2
1/2
4/3
1/4
3
Th(b)=1Th(c)=2Th(d)=3
NTh(b,a)=1/4NTh(c,a)=4/3NTh(d,a)=3
LTh(a)=1/2
Th(a)=1/4
intro sdf definitions boundedness strict bndss self-tmd bndss conclusions
15
Electronic Systems
A channel between a and b is self-timed bounded iff
Main Rule for Self-timed Boundedness
pa b
c
Golden Rule
intro sdf definitions boundedness strict bndss self-tmd bndss conclusions
).())()/()(,( bThaThcpbaNTh
16
Electronic Systems
Liveness and Self-timed Boundedness for Acyclic SDFGs
Liveness and self-timed boundedness for an acyclic SDFG: Acyclic SDFGs are live Checking self-timed boundedness for acyclic SDFGs
Calculate the throughput for all actors Sort the graph topologically Calculate the throughput for the source actors (actors without any
predecessors) and propagate the calculation
For each channel between actors a and b check the golden rule.
intro sdf definitions boundedness strict bndss self-tmd bndss conclusions
17
Electronic Systems
Example for Acyclic SDFGs
b
C
d
a,1
14
2 3
2
2
1/4
4/3
1/4
3
Self-timed unbounded !!!
intro sdf definitions boundedness strict bndss self-tmd bndss conclusions
18
Electronic Systems
doesitif
deadlocktdoesnitifKLThxE ii
')(/1)(
Reduction
K1
K2
K3
K4
p4
c4
p3p2
c3
c2
c1p1
x1 x3
x2x4
intro sdf definitions boundedness strict bndss self-tmd bndss conclusions
19
Electronic Systems
Properties of the Reduced SDFG
The reduction preserves Throughput Self-timed boundedness Liveness
intro sdf definitions boundedness strict bndss self-tmd bndss conclusions
20
Electronic Systems
Example for a General SDFG
A,2 B,1 C,1
33
3
2
211
1
x1,6 x2,4
Self-timed bounded
1/6 < 1/4
intro sdf definitions boundedness strict bndss self-tmd bndss conclusions
21
Electronic Systems
Conclusions
Necessary and sufficient conditions for checking Liveness and boundedness of (timed) SDFGs Liveness and strict boundedness of (timed) SDFGs Liveness and self-timed boundedness of timed SDFGs
Throughput calculations for general SDFGs (not necessarily strongly connected!)
intro sdf definitions boundedness strict bndss self-tmd bndss conclusions
22
Electronic Systemsintro sdf definitions boundedness strict bndss self-tmd bndss conclusions
Questions