# Compaction on the torus (VLSI layout) - Computer-Aided Design of

Document Sample

```					IEEE TRANSACTIONS ON COMPUTER-AIDED DESIGN. VOL. 9. NO. 4. APRIL 1990                                                                              389

Compaction on the Torus
KURT MEHLHORN                AND    WOLFGANG RULLING

Abstract-In this paper we introduce a general framework for com-
paction on a torus. This problem comes up whenever an array of iden-
tical cells has to be compacted. We instantiate our framework with
several specific compaction algorithms: one-dimensional compaction
without and with automatic jog insertion and two-dimensional com-
paction.

I. INTRODUCTION                                                              Fig. 1. A toroidal sketch.

A    COMPACTER takes as input a VLSI layout and pro-
duces as output an equivalent layout of smaller area.
An effective compaction system frees the designer from
the details of the design rules, and hence, increases his
productivity and on the other hand produces high quality
layouts. For these reasons, compaction algorithms have
gained widespread attention in the VLSI literature [4], [7],
[9], [lo], [12], [15], [17], and are the basis for several
computer-aided circuit design systems [2], [4], [ 1 11, [ 191,
[211.
Regular layouts composed of one- or two-dimensional
arrays of identical cells arise frequently in practice, e.g.,
bit slice architecture or systolic arrays. Let S be the cell
to be replicated. We address the following problem.
Compact S into a cell S’ such that cell S’ still can be
used to tile the plane (or an infinite strip).
This problem is called the compaction problem on the
torus, because a layout S can be used to tile the plane iff
its left and right, and top and bottom boundaries are com-
patible, i.e., if the cell S can be drawn on a torus, cf. Fig.            Fig. 2 . Part of a large accumulator consisting of identical cells. This lay-
out has been computed by toroidal compaction without jog insertion.
1. The compaction problem on a torus is interesting for
three reasons: 1) row-like and array-like arrangements of
a single cell arise frequently in practice. In such an ar-                paction on a torus was called for. Several simple-minded
rangement it is desirable to compact all instances of the                 approaches failed. Compacting a single cell does not
cell identically, 2) to guarantee identical electrical behav-             guarantee tileability , compacting the layout using the al-
ior of all instances, and 3) to allow further hierarchical                gorithm for hierarchical compaction by Lengauer [ 13)
processing.                                                               does not guarantee that the instances stay identical, and
Our own interest in compaction on a torus was stimu-                   compacting a single cell and insisting that the boundary
lated by a Kulisch-arithmetic-chip designed by Lichter                    stays rectangular wastes area, although it guarantees tile-
[ 141. A central component of this design is an accumu-                   ability. A first algorithm for toroidal compaction was pre-
lator consisting of 1152 identical cells which are arranged               sented by Eichenberger/Horowitz in [3]. However, in that
into a 36 by 32 array, cf. Fig. 2. The fully instantiated                 paper only the special case of one-dimensional compac-
layout overstrained the compacter of the HILL-system                      tion without jog insertion is considered and the complex-
(although it can handle 100 000 rectangles) and so com-                   ity of the algorithm is not analyzed.
In this paper we describe a framework for compaction
Manuscript received September 6, 1988;revised March 10, 1989.This      on a torus. It can be combined with several known com-
work was supported by the DFG under Grant SFB 124,TP B2. This paper       paction algorithms, e.g., one-dimensional compaction [4],
was recommended by Associate Editor R . H. J . M . Otten.                 [ 121, one-dimensional compaction with automatic jog in-
The authors are with the Department of Computer Science, Universitat
des Saarlandes, D 6600 Saarbriiken, Germany.                              sertion [ 151, [ 171, and two-dimensional compaction [7],
IEEE Log Number 8932831.                                               to yield specific compaction algorithms.

0278-0070/90/0400-0389\$01 0 1990 IEEE
.OO
390                                                        IEEE TRANSACTIONS ON COMPUTER-AIDED DESIGN, VOL. 9, NO. 4. APRIL 1990

Our approach is very simple. Let the cell S have length
L and height H. We draw S on a cylinder of circumference
L and height H. If S is supposed to tile the plane (instead
of a strip) then we also identify the upper and lower rim
of the cylinder and obtain a torus. We now let the circum-
ference shrink. In this way the features of the cell will
move closer together until a tight cut, i.e., two features
reaching their minimum separation, arises. These two
features are keDt at their minimum seuaration from now
on. We continue in this fashion until a cycle of saturated          Fig. 3. A typical cylindrical sketch ( F , W ,P, L ) and its representation in
the plane. Dark points and line segments are features, light lines are
cuts around the cylinder (or torus) arises. At this point we          conceptual module boundaries. Formally, the connected components
have minimized the x-width of the cell but still guarantee            formed by dark and light lines are the blocks of the partition P. Wires
that it can tile a strip (or the plane).                              are shown as wiggled lines.
In Section I11 we describe our approach in more detail
and fill in some algorithmic details. We stay, however,             used. We consider only the grid model in this paper; our
on the generic level. In Section IV we instantiate our              results extend, however, to any polygonal wiring norm.
framework in three specific cases: one-dimension com-               In the grid model wires are rectilinear paths with a mini-
paction without jog insertion (Section IV-4. l), one-di-            mum vertical and horizontal separation of 1.
mensional compaction with jog insertion (Section IV . 2 ) ,            Of course, in practice, we have to consider different
and two-dimensional compaction (Section IV-4.3). Fi-                separation widths between wires and modules depending
nally, in Section V we demonstrate our approach of to-              on the used layers. However, to simplify notation we first
roidal compaction by an example.                                    ignore the layer assignment. In Section V we will explain
how to extend our framework to more realistical processes
11. DEFINITIONS RESULTS
AND                           and we also give some more details about the implemen-
To give a precise definition of the cylindrical compac-          tation.
tion problem we introduce the notation of layout sketches.             A cut C is any open line segment connecting two points
It turns out to be an adequate terminology for the speci-           of the sketch, say p and q , and not intersecting any fea-
fication of layout optimization problems in different               ture. The density of cut C is the number of crossings of
models. Similar notations have already been used in sev-            C by wires which are enforced by the topology of the
eral other papers on compaction and routing [5], [6], [8],          sketch, cf. Fig. 4. Crossings of C which can be removed
[15], [16]. Since from now on we describe a cell S by its           by deforming the wires do not contribute to the density.
sketch, we also use the symbol S to denote the sketch.              The capacity of a cut in the grid model is given by max { x-
A cylindrical sketch is a quadruple (F, W , P, L ) con-          length ( C ), y-length ( C ) } - 1, where x-length ( C ) ( y-
sisting of a cylinder Z of circumference L, a finite set F          length ( C ) ) is the length of C in horizontal (vertical) di-
of features, which are points ( = point feature) and                rection, cf. Fig. 4. A cut is called safe if its density does
straight line segments ( = line features) on the surface of         not exceed its capacity and it is called tight or saturated
Z, a finite set W of wires, which are simple paths on the           if its density is equal to its capacity. The following theo-
surface of Z, and a partition P of the features F. Each             rem was proved by Cole/Siegel [ l ] and Leiserson/Maley
block of the partition is called a module. Fig. 3 shows an          [8] for the grid model.
example of a sketch. The features and wires of a sketch
must satisfy the following conditions.                                Theorem I : A sketch has a routing iff all cuts of the
sketch are safe.
1) Distinct features do not intersect and the endpoints
of each line feature are point features.                               Actually, the results are slightly stronger. Let us call a
2) No wire may cross itself.                                     cut p 4 critical, if either p and q are point features or at
3) Each wire touches exactly two features, which are             most one of them lies on a line feature and the line seg-
point features lying at the endpoints of the wire. They are         mentpq is perpendicular to that line feature. Then a sketch
called the terminals of the wire.                                   is routable iff all critical cuts are safe.
A point in a sketch is a point lying on a feature. Mod-             With every cylindrical sketch S we can associate an in-
ules form the rigid part of a layout and wires represent the        finite planar sketch S” as follows. Let R be any vertical
flexible interconnections.                                          line on the cylinder. Then S” is obtained by unrolling the
Sketches comprise the information of placement and               cylinder and then tiling a strip with the unrolled cylinder,
global routing. A (detailed) routing of a sketch (F, W, P,          cf. Fig. 5(a).
L), w = {P,, *          , p , } , is a sketch (F, W’, P, L ) , W’      We are now ready to define the one-dimensional cylin-
= {SI, *    -  , qm} , such that ql is homotopic to p I and q,     drical compaction problem. The goal of compaction is to
have the same endpoints and p I can be transformed con-             displace the modules in the x-direction such that the re-
tinuously into q1without moving its endpoints and without           sulting sketch is routable and has minimal period, cf. Fig.
allowing its interior to touch a feature in F, such that the        5(b). Let S = (F, W , P, L ) be a routable cylindrical sketch
q,’s satisfy the constraints of the particular wiring model        and let S” be the associated planar sketch. We denote the
MEHLHORN A N D RULLING: COMPACTlON ON THE TORUS                                                                                          39 1

Note that the pair (0, L), where 0 is the zero-vector,
belongs’to C ( S ), since the sketch S is assumed to be rout-
able. Also note that the sketch S” (2 ) can be wrapped
around a cylinder of circumference 6, and hence, gives
rise to a cylindrical sketch which we denote S ( d , 6).
(
The essential conjguration space CO S ) of a sketch S
consists of that connected component of C ( S ) which con-
tains the pair (0, L), i.e., a configuration ( d , 6 ) belongs
to CO S ) if the cylindrical sketch S ( d, 6 ) can be obtained
(
from S = S(0, L ) by continuously shrinking the cylinder
x-length of cut C = W                           and deforming the layout drawn on its surface while main-
Fig. 4. A portion of a sketch with cut p4. The flow across f i is I .   taining the routability of the sketch. With this notation we
can state the compaction problem in the following way.
De\$nition: One-dimensional cylindrical compaction
problem.
Input: A routable cylindrical sketch S = (F, W , P ,
L).
Output: A configuration ( d , 6 ) E CO( S ) such that 6
is minimal.
Theorem 2. Let S = (F, W, P, L ) be a routable cylin-
drical sketch. Then the essential conjiguration space
(
CO S ) of the sketch S is a convex polyhedron.

1!2i        +A‘-
(b)
...                      Proofi In [15] the analogous result for planar
sketches was proved. Because of the correspondence be-
tween cylindrical sketches and periodic planar sketches
described above the result carries over.
Fig. 5 . (a) A cylindrical sketch S with circumference A, its embedding in
the plane and its unrolled version 3”. The shown cut C has density 2 and      We now state our main results. Let m = 1 F I be the
wrapping number 1 . (b) The same sketch after cylindrical compaction.       number of features.
The circumference A has been reduced to A‘.
Theorem 3: (Cylindrical Compaction with Automatic
Jog Insertion). In the grid model the cylindrical compac-
different instances of a feature f b y j , i E Z . A displace-                tion problem can be solved in time
ment (or configuration) of S” is given by a vector d E
RIFxZ;     a(fl)
is the displacement of featureJ.                                     W’,,, log m
O(m3               + K log m ) = O(m4W’,,,      log m )
Of course, not all displacements make sense. Firstly,
where W,,, = 1 + LH/Amln , H is the height of the
J
features in the same module must be displaced by the same
amount, and therefore, we must have                   a(J)
= d ( g i ) for
sketch S,Aminis the period of the compacted layout, and
K is the number of times a feature moves across a critical
any two feature instances in the same module. Secondly,                       cut during compaction.
features should not cross over during compaction and we,
therefore, must have x,, +             a(&)
< x, + 2 ( g j ) for any                    The quantity K is a measure of how much the sketch
two points p = ( x p , y p ) and q = ( x q , y,) where x,, < xq               changes during compaction. We believe that the bound K
and y, = y, and p lies on a featureJ and q lies on a feature                   5 m4W’,,, which we derive in Section IV is overly pes-
gj.                                                                           simistic.
Let d be a configuration satisfying the two constraints                       Compaction without jog insertion is a special case of
above. We can now define the sketch S” ( d ) in a natural                     theorem 3. Let us assume that wires are specified as rec-
way. A pointp on feature instanceJ with coordinates (x,,,                     tilinear polygonal paths; view vertical wire pieces as
y p ) in the sketch S” has coordinates ( x p + d ( f l ) , y p ) in           modules and horizontal wire pieces as wires in the sense
S”(2) and the wires in S”(2) have the “same” homo-                            of the definition of a sketch, cf. Fig. 6. Then the com-
topies as in S”;see [15] for a more precise definition.                       paction of such a sketch is tantamount to compaction
We now have to restrict the configuration space C ( S”)                    without jog insertion.
of infinite sketches in the plane to cylindrical sketches.                       Theorem 4: (Cylindrical Compaction without Auto-
This can be done by adding a third constraint enforcing
matic Jog Insertion). Cylindrical compaction without jog
the periodicity of the sketch. The conjguration space
insertion can be solved in time 0 ( m2 log m ).
C ( S ) G R F X R of a cylindrical sketch S consists of all
pairs ( d , 6), d E, R F , 6 E W, such that the configuration                   Cylindrical compaction without jog insertion was pre-
2 E R F X Z with d ( J ) = d ( f) i6, f E and i E 22,
+             F,                viously considered by Eichenberger/Horowitz [3]. They
satisfies the two constraints above and S” ( d ) is routable.                 did not analyze their algorithm.
392                                                                IEEE TRANSACTIONS ON COMPUTER-AIDED DESIGN. VOL. 9, NO. 4. APRIL 1990

I                      I

I                        I                   L         -        1
Fig. 6. A sketch for compaction without jog insertion. Vertical wire seg-
ments are treated as modules.                              -A+

A’=A   ~   6

Fig      The effect of shrinking the circumference A by f > 0 in the ex-
Our approach can also handle maximum and minimum                           aniplc of Vie. 8. Since w ( h . A ) = I . feature h moves to the right by an
distance constraints which are specified by the user as long                 amount o E . Note that the cut gh may be tight in S ( A ) but it is not tight
f
in S(A - e ) .
as the constraints are satisfied by the initial layout S. Since
toroidal compaction amounts to cylindrical compaction in                    refer to w ( f,A ) as the wrapping number off and to d ( f,
the presence of equality constraints between the upper and                  A ) as the distance from R to f in S(A ).
the lower cell boundary our algorithms carry over to to-                         With these concepts it is now easy to define the sketch
roidal compaction with unchanged running time. Finally,                     S ( A - E ) . The positionp(f, A - E ) of featurefin S ( A
we want to mention that the algorithm underlying Theorem                     - E ) is given by d ( f , A) mod (A - E ) . The wire homo-
4 can be used for Kedem/Watanabe-like two-dimensional                       topy in S( A - E ) is defined in the natural way by consid-
compaction [7].                                                             ering the continuous transformation ( E grows starting at
0) from the positions p ( f, A) to the positions p ( f,A -
111. COMPACTION A TORUS:THE FRAMEWORK
ON
E ) , f E F.
In this section we describe the general framework for                         Shrinking the circumference of the cylinder can be vis-
compaction on a torus. For simplicity, we deal only with                    ualized as follows. We cut the cylinder at the reference
the cylinder. Let S = ( F , W , P , L ) be the cylindrical                  line R and obtain a single copy of the sketch with left
sketch to be compacted and let A = L . Then we have to                      boundary R and right boundary R’. We then move each
compute an equivalent sketch with circumference 6 ’                         feature f to the right by an amount E * w ( f,6 ) and move
smaller than 6. Intuitively this can be done by shrinking                   R’ to the left by E , cf. Fig. 9. For small E no feature will
the cylinder as shown in Fig. 5 . Since the approach of                     cross R’, and hence, a cylindrical layout is obtained by
shrinking is the main concept of our framework we have                      identifying R and R‘ .
to give an exact definition of shrinking before we can de-
rive the new compaction algorithm.                            Lemma 1.
Let S( A) be the sketch obtained for the circumference     a) Let C =fg be a cut and l e t x ( C , A) : = p ( g , A) -
A of the cylinder and let R be a vertical line on the cyl- p ( f , A)                     +
w(C, A ) A be the x-length of C in S(A).
inder which we call the reference line. For a feature f let Then the x-length of C in S ( A - E ) is given by x ( C , A
p ( f,A) be the distance fromfto the reference line when - e ) = x ( C , A )                          +
E(W(g,A) - w ( f , A ) - w ( C , A ) ) .
going to the left starting inf, cf. Fig. 7. The local mean-    b) If T ( A) exists then S( A - E ) is legal for E > 0
ing of “left” and “right” is defined by viewing the cyl- sufficiently small.
inder from the outside. We refer to p ( f, A) as the posi-
Pro08 a) Let Ar = A - E . Then
tion off in the sketch S( A). For a cut C let the wrapping
number w( C , A) be the number of intersections between       x ( C , A r ) = p ( g , A’) - p ( f , A’)             w(C, A’) A’   +
C and the reference line R .
We extend the concept of wrapping number to features                      = (p(g, A)                          +
w(g, A) A) mod A’
A
as follows. Consider an auxiliary digraph G with vertex
set F U { R 1. For every feature f there is an edge ( R , f )
of cost 0 and for every saturated cut C with endpoints f                                          +
w(C, A r ) * A’
and g , where the left-to-right orientation is from f to g ,                 = (p(g,A) + w(g,A). ~)modA’
there is an edge (f, ) of cost w( C , A). We denote such
g
a cut C byfg; note that this notation is ambiguous since
only the endpoints together with the wrapping number                             + w(C, A’) * A - w(C, A’) * E .
identify a cut. First let us assume that the auxiliary graph
G is acyclic; the other case is treated in the proof of
A                                                            Let us assume for simplicity that p ( g , A) + w( g, A)
lemma 3.                                                       E < A‘ a n d p ( f , A) + w(f, A) * E < A‘; the other
We then can compute a longest path tree T(A) with case is similar and left to the reader. Then w( C , Ar ) =
root R in the auxiliary graph GA. Let w( f,A) be the length w ( C , A > , a n d h e n c e , x ( C , A ’ )= x ( C , A ) + E ( w ( g , A )
of a longest path from R to f i n GAand let d ( f,A) = A - W (. “ A) - w ( C , A ) ) .
f,
w(f, A) + p ( f,A), cf. Fig. 8 for an illustration. We      b) Let d = f g b e any’cut. Clearly, if C is not tight in
MEHLHORN A N D RULLING: COMPACTION ON THE TORUS                                                                                                  393

b) The number of iterations is bounded by m2Wmdx
(Amln)where Amlnis the period of the final sketch.
Proof: a) The bounds 0 Iw ( f , A ) and w ( f , A ) 5
m W,,, ( A ) follow immediately from the definition of
L 2 - A                       -i
R
4               wrapping numbers. We show next that w ( f , A ) is non-
(a)                     (b)                     (C)                  decreasing for every f . Consider any S ( A ) and let E be
Fig. 8. (a) Apart ofa cylindrical sketch S ( A ) with featuresf, g, and h .       maximal such that S ( A - E ) is legal. Then there must be
The cuts fg and gh have wrapping number 0 and cut jh has wrapping
number 1. (b) The unrolled version of the sketch. (c) The auxiliary graph       a cut C = & which is tight in S ( A - E ) and oversaturated
CAwith the longest paths to all features assuming that the three cuts fg.       in S ( A - E - 6 ) for 6 > 0. Thus by lemma la) we obtain
3,  and f h are saturated. From the graph GA we obtain the wrapping
w ( g , A ) - ~ ( f A ) - w ( C , A ) < 0.
,
numbers of features: w ( f , A ) = w ( g, A ) = 0 and w ( h , A ) = I .
Now consider the layouts S( A - 6 ) where 0 5 6 < E .
In these layouts exactly the cuts D = hk with w ( k , A ) =
S ( A ) then C is not tight in S(A - E ) for E sufficiently                       w ( h , A ) + w ( D , A ) are tight. This follows from Lemma
small. If C is tight in S ( A ) then there is an edge ( f , g )                   l a and the definition of E . In particular, all cuts in T ( A )
of cost w ( C , A ) in the auxiliary graph, and hence, w ( g ,                    stay tight. Moreover, the tree T ( A - 6 ) , 0 I6 < E , is
A ) 1 w( f, A )      +w ( C , A ) by the definition of wrapping                   independent of 6. This can be seen as follows. As we in-
number. Thus x ( C , A - E ) 2 x ( C , A ) . Since the                            crease 6 from 0 to E , the wrapping number of a feature h
y-coordinates of the features do not change during shrink-                        increases by one whenever h moves across the reference
ing, the capacity of C does not go down when passing                              line R on the cylinder. Note that in this case the wrapping
from S ( A ) to S ( A - E ) . Also, the density of C does not                     number of all cuts incident to h and leaving h to the left
change for E sufficiently small. Thus S ( A - E ) is legal                        goes up by one and the wrapping number of the cuts leav-
for E sufficiently small.                                     rn                  ing h to the right goes down by one. Thus the longest path
Lemma 1 is the basis for our compaction algorithm. If                          tree does not change. The argument also shows that the
T ( A ) exists, then the shrinking process yields a legal                         quantity w ( g , A - 6 ) - w ( A A - 6 ) - w ( C , A - 6 )
sketch of smaller period. This leads to the following al-                         is a constant independent of 6.
gorithm.                                                                             In S ( A - E ) that cut C becomes tight and is added to
A      w; S ( A )   +     S ( * the initial sketch S has period w              the auxiliary graph. Since w ( g, A - 6 ) - w ( f, A - 6 )
- w ( C ,A - 6 ) = w ( g , A ) - ~ ( f A ) - w ( C ,A ) <
,
*)
while T ( A ) exists                                                           0, and hence, w ( f , A - 6 ) + w ( C , A - 6 ) > w ( g , A
- 6 ) for all 6, 0 5 6 < E , there is now a longer path to
do let E > 0 be maximal such that S ( A                  - E)      is legal;
compute S ( A - E ) and T ( A - E ) ;                                        g in the auxiliary graph. Thus we obtain T ( A - E ) by
A c A - 6 ;                                                                  replacing in T ( A ) the edge ( = cut) currently ending in g
od;                                                                            by an edge corresponding to C. Also, w ( g , A - E ) =
~ ( fA - E)+ w(C, A - E).
,
It remains to prove termination (Lemma 2) and correct-                             b) We have shown in part a) that the values w ( f,A )
ness (Lemma 3). We, therefore, define(,,
,"    A ) to be the                         are nondecreasing, that at least one such value is in-
maximal wrapping number of any cut that cannot be re-                             creased in each iteration and that 0 Iw ( f , A ) Im             -
placed by a sequence of tight cuts of smaller wrapping                             W ( A m l n ) .Thus the number of iterations is bounded by
number.                                                                           m2maxr n a x ( A m i n ) *
W

wrnax(A)     =   max     { W(C,    A);                                           Lemma 3.
The algorithm constructs a sketch of minimum period.
C   =   fs is a tight cut                                     Proof: Let Sfin the final sketch. It is clearly reach-
be
and there is no sequence f o ,    * * ,f k                   able (the algorithm shows how) from the initial sketch S
-                                     by a continuous transformation which only passes through
f = fo, g = f k , C, = J J + I is tight for                  legal configurations. Thus Sfin= S ( do, Ao) for some (do,
O ~ i < k ,                                                  A,) E Co(S).
Since the algorithm stops with a cyclic auxiliary graph
and w ( C , A ) =       c w ( C j ,A ) } .
I
we obtain a cyclic sequence of tight cuts running around
the torus. Because of this sequence further shrinking be-
We prove upper bounds for W,,, in various compaction                              comes impossible. More formally, in Sfin        there must be a
models in Section IV. In particular, W,,,(A) = 1 for                              sequence&,__* ,fk of features such thatfo = h Dand the
*
compaction without jog insertion and W,,,(A) I 1 +                                cuts C, = J J + I , 0 I i < k , are tight. Let x , be the
L H / A J for compaction with jog insertion in the grid                          x-length of C, and let w, be its wrapping number. Since
model.                                                                            the cuts form a cycle, we obtain xo      +        + ~ k - 1 = A0
Lemma 2.                                                                        -   (WO   +   * *   -+   Wk-,).
a) 0 Iw ( f , A ) Im W,,,,,(A) for a l l f a n d A and                            Let S' = S ( d , 6 ) with ( d , 6 ) E C o ( S )be arbitrary. For
w ( f , A ) is nondecreasing for every f.                                         0 5 A I1 consider the configuration ( d ( A ) , 6 ( A ) ) with
394                                                               IEEE TRANSACTIONS ON COMPUTER-AIDED DESIGN. VOL. 9. NO. 4. APRIL 1990

d ( A ) = ( l -X)do+Xdand6(h)=(l -h)Ao+h6.
Then ( d ( A ) , 6 ( A ) ) E Co(S) since Co(S) is convex by
Theorem 1. Next observe that the cuts C, exist in S( d ( A),
6 ( A ) ) for X sufficiently small and that their density is the
same as in Sfin.     Thus their capacity must be no smaller
than in Sfin, hence, their x-length must be no smaller
and                                                                                      (a1                         (b’
than in Sfin. Their total x-length is 6 ( X ) ( wo      *
+   +             Fig. 9     (a) h moves to the left relauve t o the cutfX_and hits this cut in S(A
Wk-l), and hence, 6 ( h ) IA for X small. Thus 6 IA
.                            .              - c ).  The cutfg will then disappear. If the cutfg is tight then both cuts
and Sfin   have minimal period.                                               5 a n d 5 will be tight in S(A   - c ) , and hence. cases 1 and 3 . 1 . ar&
together. (b) /Lalso moves to the left with respect to theline segment fg.
At this point we have proved termination and correct-                      Thus the cut fg will arise, say in_S( A --E).   The cut fg cannot be satu-
rated because otherwise the cutsf.? and hg would be saturated in S(A -
ness of our generic compaction algorithm. We fill in some                     E ) , and hence,f.? would be oversaturated in S(A - e - 6 ) for 6 > 0
more algorithmic detail next. The data structures are the                     small. Thus (f, ) E T ( A - E ) and g would never become visible from
h
longest path tree T = T ( A) and the set A = A ( A ) of cuts.                 f.
With every cut C E A we associate the minimal value E ( C )                          IV. SPECIFIC COMPACTION   ALGORITHMS
of E such that C becomes tight in S( A - E ) . The value                       In this section we derive specific compaction algo-
E ( C ) is easily computed from the density and the capacity
rithms from the general framework of Section 111.
o f C i n S ( A ) u s i n g L e m m a l a ) . LetEl = m i n { ~ ( C ) ; C
E A } . For every feature f let E ( f ) be the minimal value
4. I . One-Dimensional Compaction Without Jog
of E such t h a t p ( f , A - E ) mod (A - E ) = 0, i . e . , f
moves across the reference line in S(A - E ) . Let €2 =                     Insertion
m i n { E ( f ) ; f E F } . Finally, let e 3 = min{E; A(A - E )               We assume that wires are specified as rectilinear polyg-
# A ( A ) } and let E = min(E,, c 2 , c 3 ) . We distinguish               onal paths in the input sketch S. We treat vertical wire
three cases according to whether E = E , , E = c 2 , or E =                 segments as modules and horizontal wire segments as
t 3 .The three cases are not mutually exclusive.                            wires in the sense of the definition of sketch. The only
cuts which have to be considered are horizontal cuts con-
Case I . E = E , : Let E = E ( C ) =           fs.
Let T8 be the                       necting pairs of features which are visible from each other.
subtree of T rooted at g. We perform the following ac-                      Thus there are only O ( m ) critical cuts, the set A of cuts
tions.                                                                      does not change and W,,, = 1 since no cut can wrap
1) I f f € Tg then STOP, T(A - E ) does not exist.                       around twice.
2) I n c r e a s e w ( h ) b y w ( f ) + w ( C ) - w(g)forevery             For a feature h , let deg ( h ) be the number of cuts in-
feature h E Tg; here w ( h ) denotes the current wrapping                   cident to h . Since all cuts are running horizontally there
number of feature h E Tg.                                                   are no crossings between cuts. Thus the set of cuts defines
3) Delete the current edge ending in g from T and add                     a planar graph on the set of features and we have
the edge ( f,g 1.
4) Recompute E ( D ) for every cut D incident to a fea-                            2 x number of cuts =              c deg ( h ) = O ( m )
heF
ture h E T,, recompute E ( h ) for every h E Tg and rqcom-
pute e l , c 2 , and e 3 .                                                  for example, the number of cuts is linear in the number
Case2.    E   = c2: Let E = c ( f ) , f ~ F .                            of features. For an illustration see Fig. 7. Also, actions 4
and 5 of our algorithm are executed at most m times for
5) Increase w( f ) and w( C ) by one. For all cuts C                     each h by Lemma 2a), and hence, the total cost is &,EF m
leaving f to the left increase w ( C ) by one and for all cuts
leaving f t o the right decrease w ( C ) by one. Update E ( f )
-
deg ( h ) log m = O ( m 2log m ) ; the log m factor results
from the fact that a change of E ( D )requires a heap op-
and c 2 .                                                                   eration. This proves Theorem 4.
Case 3 , E = e3: A either grows or shrinks at A - E .
Case 3. I.: A shrinks, say cut C disappears, cf. Fig.                   4.2. One-Dimensional Compaction With Job Insertion
10.
6) Delete C from A. Update          E,   and e 2 .                          As mentioned in Section 11, the idea of compaction with
automatic jog insertion presented in [15] is to replace a
Case 3 . 2 . : A grows, say cut C appears, cf. Fig. 10.               given layout by a routable sketch and then to compact the
sketch preserving routability . Finally a routing algorithm
7) Add C to A, compute E ( C ) and update c l and             €3.
like the one given in [8] is used to add the final local
Remark: In the high level description of the algorithm,                   routing. The main advantage of this method is that no spe-
Cases 2 and 3 did not appear because case 2 does not                        cial treatment of jogs has to be done when computing the
change the longest path tree and the values E ( C ) . Case                  optimal position of modules.
3.1 either removes an unsaturated cut or occurs together                       To apply our generic algorithm of Section I11 to cylin-
with Case 1. Case 3.2 creates only unsaturated cuts, cf.                    drical compaction with automatic jog insertion we need a
Fig. 10.                                                                    bound on the maximal wrapping number W,,, of critical
LvIcnLnUKIY   A N U KULLIIYU: C U M Y A C I I U N U N   I HI2 I U K U S                                                                                       5Y3

u(C,A) mfcmou Linr
fs                                      f5                       f6
(a)                                      (b)

(a)                                       (b)
Fig. 1 1 . (a) A cut C = 2  with wrapping number w ( C, A ) > I + H/A
in the unrolled version of a sketch S ( A ) . g‘ is the feature at distance A
Fig. Io l a ) A sketch with line featuresf;. . . . .f6. The arrows denote cuts          left of g. (QA feature hinside the triangle V (f, g’) specifying two
g,
used for compaction without jog insertion. The sketch of ( a ) specifies             cuts D’ = jh and D” = hg.
the planar graph of cuts given in (b).

Let K be the number of times actions 6 and 7 are per-
formed. Then the running time is O ( K log m            m .          +
cuts and we need a way to handle the set A of cuts. The                            (mW,,,)        (mW,,, log m ) ) since the maximal wrapping
upper bound of W,,, is given by the following lemma.                                                                      -
number of any feature is m W,,, by lemma 2 and since
Lemma 4.                                                                        the maximal number of critical cuts incident to any fea-
Let S be a cylindrical sketch of height H and period A .                        ture is m W,,,; note that for each feature g there can be up
Let W,,, be the maximal wrapping number of any tight                               to W,,, different cuts with endpointsfand g.
cut which cannot be replaced by a sequence of shorter                                Finally, note that K I3m4 W;,,. This can be seen as
tight cuts. Then W,,, I1 + L H / A 1 in the grid model.                            follows. Consider a pair ( f,g ) of features and one of the
W,,, possible cuts C with endpointsf and g. Any feature
Proofi We use the concept of shadowing, cf. [l],                             h can cross C at most 3m W,,, times since between con-
fs
[16]. Let C = be a saturated cut with w ( C , A ) > 1                          +   secutive crossings the wrapping number of at least one of
H / A , cf. Fig. 1 l(a) and let g’ be the feature in S” lying                      the three features must have been increased. Thus the run-
at distance A left of g. Then we consider the triangle V ( f,
g , g’) with sides C =        fs,   g and
C’ = f ’ C ” =             If there    2.              ning time is O ( K log m                    +
m3 W;,, log m ) =
O ( m4         log m ) and Theorem 3 is proved. We believe
are no features inside this triangle we define h = g ’ ; oth-                      that our bound on K is overly pessimistic.
erwise we chose a feature h inside the triangle such that
the line segments D‘ = @ and D” =            are both cuts and                     4.3. Two-Dimensional Compaction Without Jog
the triangle V (f,g , h ) contains no features, cf. Fig.                           Insertion
ll(b).                                                                                Finally, we describe how two-dimensional compaction
Since there is no feature inside triangle V ( f,g, h ) , all                   can be done on the torus. Since it is well known that this
nets that have to cross cut C also have to cross cuts D’ or
problem is NP-hard, we cannot expect to obtain a poly-
D” or they are terminating at feature h , cf. Fig. Il(c).                          nomial-time algorithm to compute an optimal solution.
Therefore, we obtain for the densities of the cuts dens
Therefore, we propose to extend the method of Kedem/
( C ) Idens (D’ ) + dens ( D ”)                  +
1. For the capacities
Watanabe described in [7] to toroidal compaction. This
we have cap ( C ) = cap (D’ )                +
cap ( D ”)     1 because    +                method for two-dimensional compaction in the plane is
D‘ and D” both have slope at most 1. Since cut C is sat-
based on a branch and bound approach with exponential
urated (cap ( C) = dens ( C ) ) we can conclude that cuts
running time and it uses a one-dimensional compaction
D’ and D” are both tight. For this reason D’ and D” can
algorithm to compute the lower bounds in the bound step.
replace the longer cut C . This means that whenever we
When we replace the used one-dimensional compaction
preserve cuts D’ and D” from becoming oversaturated cut
algorithm by our algorithm for cylindrical compaction
C will be save, too. Therefore, all cuts with wrapping
(Theorem 4), we obtain a natural extension of the com-
number greater than 1             +
H / A can be replaced by a se-                        paction method from the plane to the torus. The main ad-
quence of shorter cuts and we conclude w,,, I 1                                +   vantage of this extension is that two-dimensional com-
H/A.                                                                               paction of large arrays of processors can be done with a
We store the set of cuts as in [17], i.e., for each point                       running time that only depends on the complexity of one
feature f we store the set of critical cuts incident to f in                      processor. We now give some more details about this ap-
clockwise order in a balanced tree. Therefore, we can use                         proach.
the results of [ 171 to derive the running time of the generic                       The difficulty of two-dimensional compaction is the in-
algorithm presented at the end of Section 111.                                    teraction between horizontal and vertical movement of
The algorithm consists of several operations labeled by                         features. For example, one has to decide whether it is bet-
numbers 1 to 7. Actions 1 to 5 take time O ( deg ( h ) log                        ter to separate two featuresfand g by a horizontal or ver-
m ) for each feature h whose wrapping number is in-                               tical cut, cf. Fig. 12. Therefore, in the compaction method
creased where deg ( h ) is the number of cuts incident to h                       presented in [7], decision variables df,g E { 0, 1 } are in-
and actions 6 and 7 take time O(log m ) each.                                     troduced for every pair of interacting features. The value
396                                                               IEEE TRANSACTIONS ON COMPUTER-AIDED DESIGN. VOL. 9, NO. 4. APRIL 1990

onstrate the program we compact the accumulator layout
mentioned in Section I. It consists of 1152 identical cells
each containing about 1000 elementary rectangles. For
this example cylindrical compaction is done as follows.
First we create the set A of cuts. Since the HILL design
system uses a hierarchical description of symbolical lay-
Fig. 12. Sketch (a) gives an example of two interacting featuresfand g .
Feature g can either be moved to the left (b) or downwards (c). The
outs that is similar to rectilinear stickdiagrams, the cuts
decision variable d,8 determines which kind of movement has to be used   can be computed by an extension of the plane sweep
for two-dimensional compaction.                                          method presented in [lo]. This only takes about 15 CPU
seconds for one direction because only one single proces-
sor has to be investigated. Our compaction algorithm then
of df,.Kdetermines whether a horizontal or vertical sepa-                  needs 8 CPU seconds to compute the minimal period A and
ration betweenfand g has to be used. Let d denote the                      to compute legal coordinates for all features and wire seg-
vector of all decision variables. Then for every fixed d the               ments.
two-dimensional compaction problem can be solved by                           Finally we apply the wire length minimization algo-
separately applying one-dimensional compaction in the                      rithm presented in [20] for further layout optimization.
horizontal and vertical direction. This works on the torus                 This can be done within 17 s of CPU time. A part of the
as well as in the plane. The remaining problem of com-                     produced layout is shown in Fig. 2. Similar results were
puting the optimal decision vector d can be solved by the                  obtained for several other arrays of processors. All men-
branch-and-bound algorithm. By this method one starts                      tioned programs are implemented in PASCAL and are
with all decision variables being undefined, and then tries                running in a UNIX environment on a VAX 8700 com-
to fix the variables in such a way that the layout area pro-               puter.
duced by the two passes of one-dimensional compaction                         Again please note that the time and space requirements
will be minimal. Essentially this is done by investigating                 of cylindrical compaction only depends on the complexity
a decision tree and pruning away subtrees that cannot im-                  of one single cell of the accumulator. For this reason, in-
prove the objective function. For this purpose we need                     stead of the pessimistic time bound derived in Section IV
lower bounds and upper bounds of the layout area. To                       we expect that also cylindrical compaction with automatic
obtain a lower bound we compute the minimal horizontal                     jog insertion will be practicable.
period A :
\$    and the minimal vertical period A::,“,“’ by one-
dimensional cylindrical compaction of the given sketch,                                        ACKNOWLEDGMENT
5
ignoring cuts corresponding to decision variables that
are not yet fixed. Obviously, the product A: \$)            -is               The authors wish to thank M. Jermm, St. “her and
Th. Schilz for many helpful discussions. M. Jerrum sug-
a lower bound of the compacted layout area. Upper
bounds can be obtained by inserting a horizontal or ver-                   gested that toroidal compaction is the adequate approach
tical cut for every unfixed decision variable. This way the                to compacting regular structures.
branch-and-bound method can be used for two-dimen-
sional compaction on the torus.                                                                        REFERENCES
[ I ] R. Cole and A . Siegel, “River routing every which way, but loose,”
V. DETAILS    ABOUT   THE IMPLEMENTATION      AND                            in Proc. 25th Ann. Symp. on Foundations of Computer Science, pp.
65-73, Oct. 1984.
EXPERIMENTAL     RESULTS                                  [2] A. E. Dunlop, “SLIP: Symbolic layout of integrated circuits with
In the previous sections we have used some simplifi-                           compaction,” Computer Aided Design. vol. IO, no. 6. pp. 387-391,
1978.
cations to introduce our framework of toroidal compac-                      [ 3 ] P. Eichenberger and M. Horowitz, “Toroidal compaction of sym-
tion. However, to implement the presented algorithms one                          bolic layouts for regular structures,” in Proc. ICCAD 1987, pp. 142-
has to take care of several technical problems. Some of                            145, 1987.
[4] M. Y . Hsueh, “Symbolic layout and compaction of integrated cir-
them are mentioned below.                                                         cuits,” Ph.D. dissertation EECS Division, Univ. of Calif., Berkeley,
For example, we have to handle multiple layers and                            1979.
we have to respect the minimal separation widths speci-                      [5] S. Gao, M . Jerrum, M. Kaufmann, K. Mehlhorn, W. Riilling, and C .
Storb, “On homotopic river routing,” presented at BFC’87, Bonn,
fied by a set of design rules. This can be done by creating                       Germany, 1987.
cuts for all relevant pairs of layers separately and then                    [6] M. Kaufmann and K. Mehlhorn, “Local routing of two-terminal
joining all cuts to obtain the set A used in our algorithm.                        nets,” in Proc. 4th STACS’87, LNCS 247, pp. 40-52, 1987.
[7] G . Kedem and H. Watanabe, “Optimization techniques for IC layout
To avoid changes of layers within one net we treat                           and compaction,” Tech. Rep. 117, Comput. Sci. Dep., Univ. of
contacts as modules.                                                               Rochester, N Y , 1981.
For compaction with jog insertion the definition of                    [8] C. E. Leiserson and F. M. Maley, “Algorithms for routing and test-
ing routability of planar VLSI layouts,” in Proc. 17th Ann. ACM
capacity and density has to be modified to handle the width                        Symp. on Theory of Computing, pp. 69-78, 1985.
of wires.                                                                    191 C. E. Leiserson and R. Y . Pinter, “Optimal placement for river rout-
. _
Until now we have only implemented cylindrical com-                             ing,” SIAM J . Computing, vol. 12, no. 3 , pp. 447-462, 1983.
[IO] T. Lengauer, “Efficient algorithms for the constraint generation for
Paction without jog insertion and we are using it as Pan                           integrated circuit layout compaction,” in Proc. 9th Workshop on
of the VLSI design environment HILL ([ 1 13). To dem-                              Graphtheoretic Concepts in Computer Science, pp. 2 19-230, 1983.
MEHLHOKN A N D RULLING: COMPACTION ON THE TORUS                                                                                                    J7I

[ 1 I] T. Lengauer and K . Mehlhorn, “The HILL system: A design envi-                                Kurt Mehlhorn received the Ph.D. degree in
ronment for the hierarchical specification. compaction. and simula-                            computer science from Cornell University, Ith-
tion for integrated circuit layouts,” in Proc. Con5 011 Advunced Rr-                           aca, NY in 1974.
search in VLSI. 1984.                                                                             In 1975 he became a full professor at the Uni-
[ 121 T. Lengauer. “On the solution of inequality systems relevant to IC                             versity of the Saarland in Saarbriicken. There he
layout,’’ J . Algorithms. vol. 5 , no. 3, pp. 408-421. 1984.                                   is currently chairman of the Computer Science
[ 131-.     “The complexity of compacting hierarchically specified layouts                           Department. His main research interests are in the
area of data structures, computational geometry,
of integrated circuits,” in Proc. 1982 FOCS, pp. 358-368, 1982.
[I41 P. Lichter, “Ein Schaltkreis fur die Kulischarithmetik,” Diplomar-                              parallel algorithms and VLSI design.
beit. Universitat des Saarlandes, 1988.                                                           In 1986 Dr. Mehlhorn received the Leibnitz-
[I51 F. M. Maley, “Compaction with automatic jog insertion,” presented                               Award from the Deutsche Forschungsgemein-
at 1985 Chapel Hill Conference on VLSI. 1985.                          schaft.
[I61 -.     “Single-layer wire routing.” Ph.D. dissertation. MIT, 1987.                                         *
[I71 K. Mehlhorn and S . Naher, “A faster compaction algorithm with au-
tomatic jog insertion,” in Proc. 1988 MIT VLSI Conf,, pp. 297-314,                             Wolfgang Rulling received the Dr. rer. nat. de-
1988.                                                                                         gree in computer science from the University of
[I81 R. Y. Pinter, “The impact of layer assignment methods on layout                                 Darmstadt in 1983.
algorithms for integrated circuits,” Ph.D. dissertation Dep. Elect.                               In 1984 he joined the Computer Science De-
Eng. Comput. Sci., MIT, 1982.                                                                  partment at the University of Saarland in Saar-
[ 191 W . Rulling, “Einfuhrung in die Chip-Entwurfssprache HILL,”                                    briicken to work in a research project on VLSI de-
Techn. Bericht 04/1987, SFB124, Universitat des Saarlandes. 1987.                              sign systems. Since 1989 he has been a professor
[20] C . Storb, “Minimierung der gewichteten Weglange eines Graphen,”                                at the Department of Computer Engineering and
Diplomarbeit, FB10, Informatik, Universitat des Saarlandes, Saar-                              Microelectronics of the Fachhochschule Furtwan-
briicken, 1985.                                                                                gen. His main research interests in the area of
[21] J . D.Williams, “STICKS-A graphical compiler for high level LSI                                 VLSI design are layout generators, layout opti-
.     -
design,” in Proc. Nut. Computer Conf.. pp. 289-295, 1978.              mization techniques. and design for testability.

```
DOCUMENT INFO
Shared By:
Categories:
Stats:
 views: 6 posted: 6/15/2010 language: English pages: 9
How are you planning on using Docstoc?