Post on 18-Jan-2018
description
CSE 248 Skew 1 Kahng, UCSD 2011
CSE248Spring 2011
Skew
CSE 248 Skew 2 Kahng, UCSD 2011
Agenda Special trees (H, Y, X)
Zero-skew tree problem and DME (BK92, CHHBK92) BST-DME (bounded-skew trees)
Lower bounds (Charikar et al.) and provably good ZST construction (Zelikovsky-Mandoiu)
Planar zero-skew trees (ZD94, KT96)
Prescribed or useful distance – and LP (OPP96)
CSE 248 Skew 3 Kahng, UCSD 2011
λ-Geometry Routing
Introduced by [Burman et al. 1991]• λ uniformly distributed routing directions• Approximates Euclidean routing as λ approaches infinity
λ = 2Manhattan “M”
λ = 4Octilinear “X”
λ = 3Hexagonal “Y”
CSE 248 Skew 4 Kahng, UCSD 2011
Y Trees
Distance between adjacent sinks = 1
N-level clock tree: path length =
total wire length =
Covers all slots
CSE 248 Skew 5 Kahng, UCSD 2011
Y Clock Tree on Square Mesh
N-level clock tree: path length =
21% less than H-tree total wire length =
9% less than H tree, 3% less than X tree
No self-overlapping between parallel wire segments
CSE 248 Skew 6 Kahng, UCSD 2011
Y Clock Tree on Hexagonal Mesh
N-level clock tree: path length =
total wire length =
Covers 3/4 of slots
CSE 248 Skew 7 Kahng, UCSD 2011
Some Clock Tree Types
CSE 248 Skew 8 Kahng, UCSD 2011
Agenda Special trees (H, Y, X)
Zero-skew tree problem and DME (BK92, CHHBK92) BST-DME (bounded-skew trees)
Lower bounds (Charikar et al.) and provably good ZST construction (Zelikovsky-Mandoiu)
Planar zero-skew trees (ZD94, KT96)
Prescribed or useful distance – and LP (OPP96)
CSE 248 Skew 9 Kahng, UCSD 2011
Zero-Skew Tree (ZST) Problem Zero Skew Clock Routing Problem (S,G): Given a set S of sink
locations and a connection topology G, construct a ZST T(S) with topology G and having minimum cost.
Skew = maximum value of |td(s0,si) – td(s0,sj)| over all sink pairs si, sj in S.
Td = signal delay (from source s0)
Connection topology G = rooted binary tree with nodes of S as leaves Edge ea in G is the edge from a to its parent |ea| is the (assigned) length of edge ea
Cost = total edge length
CSE 248 Skew 10 Kahng, UCSD 2011
Zero-Skew Example (555 sinks, 40 Obstacles)
CSE 248 Skew 11 Kahng, UCSD 2011
Manhattan Arcs, TRRs and Merging Segments Manhattan Arc: line segment with
slope +1 or –1
Tilted Rectangular Region (TRR): collection of points within a fixed distance of a Manhattan arc Core = Manhattan arc Radius = distance
Merging segment = locus of feasible locations for a node v in the topology, consistent with minimum wirelength If v is a sink, then ms(v) = {v} If v is an internal node, then ms(v) is
the set of all points within distance |ea| of ms(a), and within distance |eb| of ms(b)
CSE 248 Skew 12 Kahng, UCSD 2011
Bottom-Up: Tree of Merging Segments
Goal: Construct a tree of merging segments corresponding to topology G Merging segment of a node depends on merging segment of
its children bottom-up construction Let a, b be children of v. We want placements of v that allow
TSa and TSb to be merged with minimum added wire while preserving zero skew
Merging cost = |ea| + |eb|
Lemma: The intersection of two TRRs is also a TRR and can be found in constant time.
CSE 248 Skew 13 Kahng, UCSD 2011
Tree of Merging Segments Constant time per each new merging segment linear
time (in size of S) to construct entire tree
CSE 248 Skew 14 Kahng, UCSD 2011
Top-Down: Embedding Nodes of Topology Goal: Find exact locations
(“embeddings”) pl(v) of internal nodes v in the ZST topology.
If v is the root node, then any point on ms(v) can be chosen as pl(v)
If v is an internal node other than the root, and p is the parent of v, then v can be embedded at any point in ms(v) that is at distance |ev| or less from pl(p) Detail: create square TRR trrp with
radius ev and core equal to pl(p); placement of v can be any point in ms(v) trrp
CSE 248 Skew 15 Kahng, UCSD 2011
Find_Exact_Placements Each instruction executed at most once for each node
in G, and TRR intersection is O(1) time Find_Exact_Placements is O(n) DME is O(n)
CSE 248 Skew 16 Kahng, UCSD 2011
Facts About DME Construction
DME produces a ZST under linear delay model with minimum cost over all ZSTs with topology G and sink set S
For any sink set S and topology G, DME will construct a ZST with minimum feasible source-sink delay, equal to one-half the diameter of S (Theorem 2, BK92)
Corollary: We know the merging segments top-down!
CSE 248 Skew 17 Kahng, UCSD 2011
Vertex Loci in a Bounded-Skew Tree
skew0 2 4 6
2
4
6
0246
2
4
6
skew
v
s4
va b
s1 s2 s3
Topologys0 b
a
Given a skew bound, where can internal nodes of the given topology (e.g., a, b, v) be placed?
CSE 248 Skew 18 Kahng, UCSD 2011
BST-DME Bottom-Up Phase
s4
va b
s1 s2 s3
Topology
s0
s1
s3
s4
s2
mr(a)mr(b)mr(v)
B = 4
Bottom-Up: build tree of merging regions corresponding to given topology
s0
CSE 248 Skew 19 Kahng, UCSD 2011
BST-DME Top-Down Phase
s4
va b
s1 s2 s3
Topology
s0
s1
s3
s4
s2
a bv
B = 4
s0
CSE 248 Skew 20 Kahng, UCSD 2011
Agenda Special trees (H, Y, X)
Zero-skew tree problem and DME (BK92, CHHBK92) BST-DME (bounded-skew trees)
Lower bounds (Charikar et al.) and provably good ZST construction (Zelikovsky-Mandoiu)
Planar zero-skew trees (ZD94, KT96)
Prescribed or useful distance – and LP (OPP96)
CSE 248 Skew 21 Kahng, UCSD 2011
ZST Approximation
Charikar et al. [CKKRST99]• NP-hard for general metric spaces• factor 2e ~ 5.44 approximation
Zelikovsky-Mandoiu [ZM02] (J. Disc. Math.)• factor 4 approximation for general metric spaces• factor 3 approximation for rectilinear plane
CSE 248 Skew 22 Kahng, UCSD 2011
ZST Lower-Bound
R
rrNOPT0
d)( (CKKRST 99)
N(r)=min. # of balls of radius r that cover all sinks
CSE 248 Skew 23 Kahng, UCSD 2011
ZST Lower-Bound
R
rrNOPT0
d)( (CKKRST 99)
N(r)=min. # of balls of radius r that cover all sinks
CSE 248 Skew 24 Kahng, UCSD 2011
ZST Lower-Bound
R
rrNOPT0
d)( (CKKRST 99)
N(r)=min. # of balls of radius r that cover all sinks
CSE 248 Skew 25 Kahng, UCSD 2011
ZST Lower-Bound
R
rrNOPT0
d)( (CKKRST 99)
N(r)=min. # of balls of radius r that cover all sinks
CSE 248 Skew 26 Kahng, UCSD 2011
ZST Lower-Bound
R
rrNOPT0
d)( (CKKRST 99)
N(r)=min. # of balls of radius r that cover all sinks
CSE 248 Skew 27 Kahng, UCSD 2011
Constructive Lower-Bound
Computing N(r) is NP-hard, but …
Lemma: For any ordering of the terminals, if
},...,{MinDist21
1 ittr
ntt ,...,1
irN )( then
Where MinDist{A} = minu,v in A, u != v d(u,v)
Explanation: If r is less than half the minimum separation of any two of the first i terminals, then at least i balls are needed to cover the terminal set. In particular, at least i balls are needed to cover just the first i terminals in the ordering.
CSE 248 Skew 28 Kahng, UCSD 2011
Constructive Lower Bound
R
rrNOPT0
d)(
r
N(r)
2
n
n-1
{i = 2 to n} ½ MinDist{t1, …, ti}
½ MinDist{t1, …, tn} ½ MinDist{t1, t2}
Explanation: From the previous lemma, N(r) is at least i when r < ½ MinDist(t1,…, ti). So, we are making a lower sum for the given integral. The original version of this slide was missing the ½ factor above.
CSE 248 Skew 29 Kahng, UCSD 2011
Stretching Rooted Spanning Trees
• ZST root = spanning tree root
)(rootdelayT
where = max path length from to a leaf of
)(rootdelayT• ZST root-to-leaf path length =
)(vdelayT v vT
T
CSE 248 Skew 30 Kahng, UCSD 2011
Stretching Rooted Spanning Trees
T
)(rootdelayTLoop length =
)(rootdelayT
CSE 248 Skew 31 Kahng, UCSD 2011
Stretching Rooted Spanning Trees
T
)(rootdelayTSum of loop lengths =
)(rootdelayT
CSE 248 Skew 32 Kahng, UCSD 2011
Zero-Skew Spanning Tree Problem
)()( TdelayTlength
Theorem: Every rooted spanning tree can be stretched to a ZST of total length
where
T
)()()(
TVv T vdelayTdelay
Zero-Skew Spanning Tree Problem: Find rooted spanning tree minimizing )()( TdelayTlength T
CSE 248 Skew 33 Kahng, UCSD 2011
How Good are MST and Min-Star?
)(Nlength
.
..
MST: min length, huge delay
)( 2Ndelay
0
1
2
N-1
3
N-2
)log( NNOPT
)(Nlength …
…
Star: min delay, huge length
)1(delay
)1(OPT
CSE 248 Skew 34 Kahng, UCSD 2011
The Rooted-Kruskal Algorithm
• While 2 roots remain:• Initially each terminal is a rooted tree; d(t)=0 for all t
• Pick closest two roots, t & t’, where d(t) d(t’)
t’ t
• t’ becomes child of t, root of merged tree is t• d(t) max{ d(t), d(t’) + dist(t ,t’) }
t’ t
CSE 248 Skew 35 Kahng, UCSD 2011
The Rooted-Kruskal Algorithm
• While 2 roots remain:• Initially each terminal is a rooted tree; d(t)=0 for all t
• Pick closest two roots, t & t’, where d(t) d(t’) • t’ becomes child of t, root of merged tree is t• d(t) max{ d(t), d(t’) + dist(t ,t’) }
CSE 248 Skew 36 Kahng, UCSD 2011
How Good is Rooted-Kruskal?
• While 2 roots remain:• Initially each terminal is a rooted tree; d(t)=0 for all t
• Pick closest two roots, t & t’, where d(t) d(t’) • t’ becomes child of t, root of merged tree is t• d(t) max{ d(t), d(t’) + dist(t ,t’) }
Lemma: delay(T) length(T)
• Initially each terminal is a rooted tree; d(t)=0 for all t
• d(t) max{ d(t), d(t’) + dist(t ,t’) }
At the end of the algorithm, d(t)=delay (t )TT
• Pick closest two roots, t & t’, where d(t) d(t’)
• Initially each terminal is a rooted tree; d(t)=0 for all t
At the end of the algorithm, d(t)=delay (t )
When edge (t ,t’) is added to T:• length(T) increases by dist(t ,t’)• delay(T) increases by at most dist(t ,t’)
CSE 248 Skew 37 Kahng, UCSD 2011
How Good is Rooted-Kruskal?
• While 2 roots remain:• Initially each terminal is a rooted tree; d(t)=0 for all t
• Pick closest two roots, t & t’, where d(t) d(t’) • t’ becomes child of t, root of merged tree is t• d(t) max{ d(t), d(t’) + dist(t ,t’) }
Lemma: length(T) 2 OPT
• Pick closest two roots, t & t’, where d(t) d(t’)
Number terminals in reverse order of becoming non-roots
N
iitt
21 },...,{MinDistlength(T) =
Explanation: Kruskal is adding connections which, in reverse order, give the MinDist’s of the latest I+1 terminals in the tree. For example, the last connection is the MinDist of the latest two terminals. The first connection is the MinDist of all n terminals. The summation is exactly twice the lower bound from Slide 30.
CSE 248 Skew 38 Kahng, UCSD 2011
Factor 4 Approximation
• Length after stretching = length(T) + delay(T)• delay(T) length(T)• length(T) 2 OPT
ZST length 4 OPT
Algorithm: Rooted-Kruskal + Stretching
CSE 248 Skew 39 Kahng, UCSD 2011
Agenda Special trees (H, Y, X)
Zero-skew tree problem and DME (BK92, CHHBK92) BST-DME (bounded-skew trees)
Lower bounds (Charikar et al.) and provably good ZST construction (Zelikovsky-Mandoiu)
Planar zero-skew trees (ZD94, KT96)
Prescribed or useful distance – and LP (OPP96)
CSE 248 Skew 40 Kahng, UCSD 2011
Planar Zero-Skew Tree (ZST) Problem Planar Zero Skew Clock Routing Problem (S,G): Given a set S of
sink locations and a connection topology G, construct a ZST T(S) with topology G and having minimum cost, which is embeddable in the plane with no crossing edges.
Zhu-Dai 1992: Iteratively: (1) Connect free sink to its minimal balance point (shortest wire, maintaining exact zero pathlength skew); (2) Choose the “free” (unused) sink whose minimum balance distance is maximized.
CSE 248 Skew 41 Kahng, UCSD 2011
Planar Zero-Skew Tree (ZST) Problem Planar Zero Skew Clock Routing Problem (S,G): Given
a set S of sink locations and a connection topology G, construct a ZST T(S) with topology G and having minimum cost, which is embeddable in the plane with no crossing edges.
Enabling observations: Theorem 2 of BK92 allows us to build the tree of merging
segments top-down Binary tree topology = recursive bipartitioning of the sink set S
Planar-DME: Can achieve planarity by choosing the sink partitions and edge embeddings carefully Topology is constructed on the fly (it is not prescribed a priori)
CSE 248 Skew 42 Kahng, UCSD 2011
Planar Zero-Skew Tree (ZST) Problem Planar Zero Skew Clock Routing Problem (S,G): Given
a set S of sink locations and a connection topology G, construct a ZST T(S) with topology G and having minimum cost, which is embeddable in the plane with no crossing edges.
Enabling observations: Theorem 2 of BK92 allows us to build the tree of merging
segments top-down “Single-Pass DME” Binary tree topology = recursive bipartitioning of the sink set S
Planar-DME: Can achieve planarity by choosing the sink partitions and edge embeddings carefully Topology is constructed on the fly (it is not prescribed a priori)
CSE 248 Skew 43 Kahng, UCSD 2011
Top-Down, Single-Pass Partitioning+Embedding
Entire routing region Pa is divided into convex polygons until only one sink lies within each convex polygon
Boundaries of polygons are given by thick dashed lines and tree edges
Tree of merging segments is given by thin dotted lines
CSE 248 Skew 44 Kahng, UCSD 2011
Embedding Rules
In each recursive call, given: a subset of sinks S’,
contained in convex polygon P(S’)
a point p inside P(S’) which is the embedding of the parent of the root of the subtree over S’
Must connect p to a point v on ms(v) = center(S’)
“Embedding Rules” ensure that we find an embedding point for v in O(1) time
CSE 248 Skew 45 Kahng, UCSD 2011
Partitioning Rules
Goal: find a splitting line Divides P(S’) into two convex polygons (thus partitioning the sink set
between the two subtrees of v) Allows the routing from p to v to be on the boundary between the two
polygons
“Partitioning Rules” ensure that we find the splitting line in Theta(|S’|) time
CSE 248 Skew 46 Kahng, UCSD 2011
Agenda Special trees (H, Y, X)
Zero-skew tree problem and DME (BK92, CHHBK92) BST-DME (bounded-skew trees)
Lower bounds (Charikar et al.) and provably good ZST construction (Zelikovsky-Mandoiu)
Planar zero-skew trees (ZD94, KT96)
Prescribed or useful distance – and LP (OPP96)
CSE 248 Skew 47 Kahng, UCSD 2011
Prescribed Delays by Linear Programming Oh, Pyo, Pedram 1996
Topology and sink locations are given Use LP to determine edge lengths ( implicitly determining
Steiner point locations)Notes. (1) Having path lengths greater than or equal to lower bounds (= endpoint to endpoint distances) is a sufficient condition for there to exist Steiner point locations that satisfy the pathlength bounds. (2) Solving for the Steiner point locations in the straightforward way (i.e., as (x,y) coordinates) does not work, but solving for the locations implicitly does work.