10.1.1.11.9430

Upload: raffi-sk

Post on 03-Apr-2018

219 views

Category:

Documents


0 download

TRANSCRIPT

  • 7/28/2019 10.1.1.11.9430

    1/6

    B*-Trees: A New Representation for Non-Slicing Floorplans

    Yun-Chih Chang, Yao-Wen Chang, Guang-Ming Wu, and Shu-Wei Wu

    Department of Computer and Information Science, National Chiao Tung University, Hsinchu 300, Taiwan

    AbstractWe present in this paper an efficient, flexible, and effective data struc-ture, B*-trees, for non-slicing floorplans. B*-trees are based on orderedbinary trees and the admissible placement presented in [1]. Inheritingfrom the nice properties of ordered binary trees, B*-trees are very easyfor implementation and can perform the respective primitive tree op-erations search, insertion, and deletion in only

    ,

    , and

    times while existing representations for non-slicing floorplans need atleast

    time for each of these operations, where

    is the number ofmodules. The correspondence between an admissible placement and itsinduced B*-tree is 1-to-1 (i.e., no redundancy); further, the transforma-tion between them takes only linear time. Unlike other representationsfor non-slicing floorplans that need to construct constraint graphs forcost evaluation, in particular, the evaluation can be performed on B*-trees and their correspondingplacements directly and incrementally. Wefurther show the flexibility of B*-trees by exploring how to handle ro-tated, pre-placed, soft, and rectilinear modules. Experimental results on

    MCNC benchmarks show that the B*-tree representation runs about 4.5times faster, consumes about 60% less memory, and results in smallersilicon area than the O-tree one [1]. We also develop a B*-tree basedsimulated annealing scheme for floorplan design; the scheme achievesnear optimum area utilization even for rectilinear modules.

    1 IntroductionDue to the growth in design complexity, circuit sizes are getting

    larger. To cope with the increasing design complexity, hierarchical de-sign and IP modules are widely used. The trend makes module floor-planning/placement much more critical to the quality of a VLSI design.

    A fundamental problem to floorplanning/placement lies in the repre-sentation of geometric relationship among modules. The representationprofoundly affects the operations of modules and the complexity of afloorplan/placement design process. It is thus desired to develop an effi-cient, flexible, and effective representation of geometric relationship forfloorplan/placement designs.

    1.1 Previous WorkFloorplans can be divided into two categories, the slicing struc-ture [12, 15] and the non-slicing structure [1, 6, 9, 14]. A slicing struc-ture can be represented by a binary tree whose leaves denote modules,and internal nodes specify horizontal or vertical cut lines. Wong andLiu proposed an algorithm for slicing floorplan designs [15]. They pre-sented a normalized Polish expression to represent a slicing structure,enabling the speed-up of its search procedure. However, this represen-tation cannot handle non-slicing floorplans. Recently, researchers haveproposed several representations for non-slicing floorplans, such as se-quence pair [6], bounded slicing grid (BSG) [9], and O-tree [1].

    Onodera et al. in [11] used the branch-and-bound method to solvethe module placement problem. This approach has very high time com-plexity and is thus feasible for only small problem sizes. Murata etal. in [6] proposed the sequence-pair representation for rectangular mod-ule placement. The main idea is to use a sequence pair to represent thegeometric relation of modules, place the modules on a grid structure,

    and construct corresponding constraint graphs to evaluate cost. Thisrepresentation requires

    space to encode a sequence pair and

    !

    This work was partially supported by the National Science Council of Tai-wan under Grant No. NSC-89-2215-E-009-055. E-mail:

    "gis87512, ywchang,

    gis85815, gis8867555#

    @cis.nctu.edu.tw.

    there are

    $ '

    combinations in total, where

    is the number of mod-ules. Further, the transformation between a sequence pair and a place-ment takes

    time. Nakatake el al. in [9] presented a grid basedrepresentationBSG. The BSG structure utilizes a set of horizontal andvertical bounded-length lines to cut the plane into rooms and representsa placement by these lines and rooms. BSG incurs redundancies. Itscomplexity is similar to that of the sequence pair. The sequence pairand BSG were then extended to handle pre-placed modules and softmodules in [2, 7, 8, 10].

    Guo et al. in [1] proposed a tree based representation, called O-trees.

    The number of O-tree combinations is only $

    ' 0 2 ' 4 7 8 9

    . Further,the transformation between the representation and a floorplan takes only

    time. However, the tree structure is irregular, and thus some prim-itive tree operations, such as search and insertion, are not efficient. Toreduce the operation complexity, the tree is encoded by a sequence of

    bits and a permutation of

    bits.

    7n

    8n

    9n

    10n

    11n 3n

    4n

    5n

    6n

    1n

    2n

    0n6b

    b0

    b1b2

    b10

    b5

    b3 b4

    11b

    b9

    b7

    b8

    (a) (b)

    Figure 1: (a) An admissible placement. (b) The (horizontal) B*-treerepresenting the placement.

    1.2 Our Contributions

    To handle non-slicing floorplans, we propose in this paper an orderedbinary-tree based representation, called B*-trees. Given an admissibleplacement[1], we can represent it by a unique horizontal and a uniquevertical B*-trees. (See Figure 1(b) for the horizontal B*-tree for the ad-missible placement shown in Figure 1(a).) The admissible placementhere means that it is compacted and can neither move down nor moveleft. Inheriting from the particular characteristics of the ordered binarytree, the B*-tree has many advantages compared with other representa-tions. We summarize the advantages of B*-tree as follows:

    A Based on ordered binary trees, the B*-tree is very fast and easyfor implementation. Since the number of branches in a B*-tree isfixed (i.e., two branches), it can be implemented by either a staticdata structure or a dynamic one. By using static memory, wecan search and insert a node in

    time while the O-tree needs

    time. Note that an O-tree is irregular and its number of

    branches is unpredictable (see Figure 2(b)); thus, it incurs higheroperation complexity and/or significant encoding cost.

    A The B*-tree is very flexible for handling the floorplanning prob-lems with various types of modules (e.g., hard, pre-placed, soft,and rectilinear modules)directly and efficiently. In contrast, otherrepresentation cannot handle some special modules well. Todeal with soft modules using sequence pair, for example, pre-vious work in [8] transformed it to the convex problem (which isNP-hard [13]), processed the soft modules, and then transformedback to the sequence pair.

    A B*-trees do not need to construct constraint graphs for area costevaluation. In contrast, the sequence pair and O-tree representa-

    Permission to make digital/hardcopy of all or part of this work for personal or

    classroom use is granted without fee provided that copies are not made or

    distributed for profit or commercial advantage, the copyright notice, t he title of thepub licati on an d its date appear, and notice is given that copying is by permiss ion of

    ACM, Inc. To copy otherwise, to republish, to post on servers or to redistribute to

    lists, requires prior specific permission and/or a fee.DAC 2000, Los Angeles, California

    (c) 2000 ACM 1-58113-188-7/00/0006..$5.00

  • 7/28/2019 10.1.1.11.9430

    2/6

  • 7/28/2019 10.1.1.11.9430

    3/6

    positions for inserting a node are limited to the external nodes (see Fig-ure 3) to facilitate the update of the encoding tuple. Inserting a node to aposition other than external positions makes the update of the encodingtuple difficult and time-consuming. The inflexibility might cause the O-tree to deviate from the optimal during solution perturbations, and thusinevitably limit the quality of a floorplan design. We consider this in-flexibility a major drawback of the O-tree representation. It will be clearin the next subsection that this deficiency can be fixed by using B*-trees.

    3n

    4n

    5n

    6n7n 8n 9n 10n

    11n

    1n

    2n

    0n

    external node

    internal node

    root

    Figure 3: The internal and external insertion positions. To facilitate theupdate of the encoding tuple, O-trees allow a node to be inserted only atthe external positions.

    3.2 The B*-Tree RepresentationGiven an admissible placement

    u, we can represent it by a unique

    (horizontal) B*-tree . (See Figure 1(b) for the B*-tree representing theplacement shown in Figure 1(a).) A B*-tree is an ordered binary treewhose root corresponds to the module on the bottom-left corner. Simi-lar to the DFS procedure, we construct the B*-tree for an admissibleplacement u in a recursive fashion: Starting from the root, we first re-cursively construct the left subtree and then the right subtree. Let

    U

    denote the set of modules located on the right-hand side and adjacent toI

    U. The left child of the node

    Ucorresponds to the lowest module in

    U

    that is unvisited. The right child of

    U

    represents the module locatedabove and adjacent to

    I U, with its

    v

    -coordinate equal to that ofI U

    andits x -coordinate less than that of the top boundary of the module on theleft-hand side and adjacent to I

    U, if any.

    The B*-tree keeps the geometric relationship between two modulesas follows. If node

    is the left child of node

    U, module I

    must be

    located on the right-hand side and adjacent to module I U in the admissi-ble placement; i.e.,

    v

    E

    v

    U T U. Besides, if node

    is the right childof

    U, module I

    must be located above and adjacent to module IU, with

    thev

    -coordinate ofI

    equal to that ofI

    U

    ; i.e.,v

    E

    v

    U

    . Also, since theroot of represents the bottom-left module, the

    v

    - and x -coordinates ofthe module associated with the root

    v

    P x

    E

    P

    .As shown in Figure 1, we make

    the root of

    sinceI

    is on thebottom-left corner. Constructing the left subtree of

    recursively, wemake

    the left child of

    . Since the left child of

    does not exist, wethen construct the right subtree of

    (which is rooted by

    ). The con-struction is recursively performed in the DFS order. After completingthe left subtree of

    , the same procedure applies to the right subtree of

    . Figure 1(b) illustrates the resulting B*-tree for the placement shownin Figure 1(a). The construction takes only linear time.

    Note that a B*-tree can also be constructed by transforming an O-tree to a binary tree, under several additional construction rules for somespecial module placements to make the theorem to be presented below

    hold. However, constructing a B*-tree in this way is not as efficient asthe aforementioned procedure.

    We have the following lemma which leads to Theorem 1.

    Lemma 1 For a module IU

    in an admissible placement, the correspond-ing node

    Uin its induced B*-tree has a unique parent if

    Uis not the

    root.

    Theorem 1 There is a 1-to-1 correspondence between an admissibleplacement and its induced B*-tree.

    In other words, for an admissible placement, we can construct a uniqueB*-tree, and vice versa. The nice property of the 1-to-1 correspondence

    between an admissible placement and its induced B*-tree prevents thesearch space from being enlarged with duplicate solutions.

    4 Operations on ModulesWe adopt the contour data structure presented in [1] to facilitate the

    operations on modules. The contour structure is a doubly linked listfor modules, describing the contour curve in the current compaction di-rection. A horizontal contour(see Figure 4) can be used to reduce therunning time for finding the x -coordinate of a newly inserted module.Without the contour, the running time for placing a new module wouldbe linear to the number of modules. By maintaining the contour struc-

    ture, however, thex

    -coordinate of a module can be computed in

    time [1]. Figure 4 illustrates how to update the horizontal contour afterinserting a new module.

    0

    1 34

    10

    9

    811

    7

    b b b

    b

    b

    b

    b b

    b

    old contour

    newlyaddedmodule

    new contour

    horizontal contour

    verticalcontour

    Figure 4: Adding a new module on top, we search the horizontal con-tour from left to right and update it with the top boundary of the newmodule.

    To cope with rotated modules, when inserting a deleted node intoa B*-tree, we can perform the operation twice at each position to finda better solution, one for the original orientation, and the other for therotated one. In the following, we shall discuss the floorplanningproblemwith pre-placed, soft, and rectilinear modules.

    4.1 Pre-placed ModulesIntuitively, if there exists a pre-placed module which cannot be lo-

    cated on its fixed positions during compaction, we would discard thissolution. Unfortunately, this approach is not effective. A better ap-proach is to change an infeasible solution to be feasible. Therefore, we

    handle the situation in this way: if there exists a pre-placed module thatcannot be located on its fixed positions during compaction, we exchangethe pre-placed module with another so that the pre-placed module can belocated on its fixed positions. There are two subproblems to be solved:(1) how to choose the module that swaps with the pre-placed module,and (2) how to locate the pre-placed one on its fixed position.

    We say a module to be ahead (behind) another if its bottom-leftv

    -coordinate is smaller (larger) than that of another. Similarly, a moduleis lower (higher) than another if its bottom-left x -coordinate is smaller(larger) than that of another. A coordinate (

    v

    P x ) dominates another co-ordinate (

    v

    P x

    ), denoted by v

    P x

    v

    P x

    , iffv v

    and x

    x

    .

    LetI U

    be a pre-placed module, (v k

    U

    P x

    k

    U

    ) denote its fixed coordinate, andl

    U E G I

    y vk

    U

    P x

    k

    U

    v

    P x

    S . If there are modules ahead or lower

    thanI

    U

    so thatI

    U

    cannot be placed at (v k

    U

    , xk

    U

    ), we would exchangeI

    U

    with the module inl

    Uthat is most close to (

    v k

    U

    P x

    k

    U

    ).To identify the modules in

    l

    U, we first trace back

    from the node

    U

    until detecting a node

    whose corresponding module I

    is dominatedby (

    vk

    U

    P x

    k

    U

    ). We add

    intol

    U . Then, we trace down the subtree of

    and add all modules dominated by (v k

    U

    P x

    k

    U

    ) intol

    U. Note that when

    we trace down the subtree of

    , once we find a node o

    that is not

    dominated by (v k

    U

    P x

    k

    U

    ), all the nodes in the subtree of o

    will not be

    dominated by (v

    k

    U

    P x

    k

    U

    ). Afterl

    Uis determined, the module that is most

    close to (v k

    U

    P x

    k

    U

    ) is chosen for exchange.Figure 5(a) shows a placement with a pre-placed module

    I and its

    fixed position (v k

    , xk

    ). I cannot be placed at (v k

    P x

    k

    ) since the positionhas been occupied by module

    I

    ' . Therefore, we must choose a modulefor exchange with I . Following the aforementioned procedure, we have

  • 7/28/2019 10.1.1.11.9430

    4/6

    66,( )xf fy

    6b

    11bb0

    b1b2

    b10

    b9

    b7

    b5

    b3b4

    b8

    b5

    b1

    b2

    b0

    b36b b4

    b10

    b9

    b8 11b

    b7

    66,( )xf fy

    (a) (b)Figure 5: (a) A placement with a pre-placed module. (b) Place

    I at its

    fixed position (v k

    P x

    k

    ).

    l

    E G I

    7 P

    I

    ' S . SinceI

    ' is most close to (v

    k

    P x

    k

    ), we exchange

    ' and

    in and transform to its corresponding placement. Figure 5(b)shows the resulting exchange of I ' and I , with I being placed at its

    fixed position (v k

    P x

    k

    ). Note that, to save the execution time, we do notidentify all feasible modules (e.g.,

    I

    ) for the exchange.A nice property of the B*-tree lies in the incremental cost update.

    The DFS order of before the exchange is (

    P

    P

    ,

    7 7P

    P

    7

    ,

    7P

    'P

    ,

    P

    9P

    ). The positions of

    I

    P

    I

    P

    I

    P

    I

    7 7P

    I

    P

    I

    7

    , andI

    7

    remain unchanged after the exchange since they are in the front ofI

    ' inthe DFS order. Therefore, we do not need to recompute the area cost

    from scratch.4.2 Soft Modules

    With its area beingfixed, the width and height of a soft module is freeto be changed under its aspect ratio constraint. Our method for handlingsoft modules consists of two stages: the first stage picks a soft modulefor processing (deleting and inserting a node associated with the mod-ule), and the second stage adjusts the shapes of the other soft modules.To insert a node, most existing work tries all possible combinations ofwidths and heights. To avoid the time-consuming process of trying allpossible combinations, we shall find the best shape directly.

    6b

    b0

    b1

    b2

    b10

    b5

    b3 b4

    11b

    b9

    b7

    b8

    (a)

    7n

    8n

    9n

    10n

    11n3n

    4n

    5n

    6n

    1n

    2n

    0n

    (b)

    Figure 6: (a) An admissible placement. (b) The vertical B*-tree repre-senting the placement.

    To compact along the x direction, we introduce the vertical B*-tree

    , and call the B*-tree described in Section 3.2 the horizontal B*-tree,denoted by

    . Given an admissible placement

    u, we can construct a

    unique

    . Let U

    denote the set of modules located above and adjacentto I

    U. The construction is similar to constructing a

    described in Sec-

    tion 3.2 with the only difference in direction. The left child of the node

    U corresponds to the leftmost module in U that is unvisited. The rightchild of

    Urepresents the module located on the right-hand side and ad-

    jacent to IU, with its x -coordinate equal to that of I

    Uand its

    v

    -coordinateless than that of the right boundary of the module below and adjacentto

    IU

    , if any. Figure 6(b) gives the vertical B*-tree for the admissibleplacement shown in Figure 6(a).

    After inserting a node associated with a soft module, we compute itssurplus space in the

    v

    and x directions for stretching its width and height

    under its aspect ratio constraint. Let

    U

    (

    U

    ) denote the set of mod-ules affected by shifting the soft module I

    Uin the horizontal (vertical)

    direction andI

    U

    itself. (Note that we can shift a module either up or right

    in an admissible placement.) The modules in U

    are those associated

    with the nodes in the left subtree of I U in and I U itself. The modulesin

    U

    can be similarly defined in .Let

    q

    x

    U zf

    U

    0P x

    U zf g h t

    (q

    v

    U zf

    U

    0P

    v

    U zf g h t

    ) be the range on the vertical(horizontal) contour that could be affected by pushing I U forward in thehorizontal (vertical) direction. We have

    x

    U zf gi h E ~ G

    x

    W

    y

    I

    p

    U

    S (1)

    x

    U zf

    U

    0

    E ~ G

    x

    y

    I

    p

    U

    S (2)

    and

    v

    U zf g h

    E ~ G

    v

    T

    y

    I

    p

    U

    S (3)v

    U{ z f U

    0

    E ~ G

    v

    y

    I

    p

    U

    S Q (4)

    Let

    v

    (

    x

    ) be the maximumv

    ( x ) coordinate on the vertical (hor-izontal) contour in the range U E

    q

    x

    U z f U

    0 P x

    U z f g h t (q

    v

    U z f U

    0 P

    v

    U z f g h t ),and

    b

    (

    b

    ) denote the distance between

    v

    (

    x

    ) and the maxi-

    mumv

    ( x ) coordinate on the vertical (horizontal) contour. Also, let

    U

    (

    U

    ) be the set of modules on the right-hand (upper) side of IU

    and theirvertical (horizontal) boundaries overlap with the interval

    q

    x

    U

    P x

    U

    W

    Ut

    (q

    v

    U

    P

    v

    U T U t),

    v

    !

    U

    E ~ G

    v

    y

    I

    p

    U

    S ( x!

    U

    E ~ G

    x

    y

    I

    p

    U

    S )

    denote the minimumv

    ( x ) coordinate of the modules in

    U

    (

    U

    ), and

    b

    E

    b

    v

    !

    U

    v

    U

    T U

    P

    b

    U

    E

    b

    P otherwise P

    b

    E

    b

    x

    !

    U

    x

    U

    W

    U

    P

    b

    U

    E

    b

    P otherwise Q

    We have

    T U E

    TU

    b

    P

    b

    e fU

    0

    `

    g

    U

    `

    e f g h

    g

    P

    b

    g

    U

    e fU

    0

    g

    P

    b

    g

    U

    e f g h

    P

    W

    U E

    W

    U

    b

    P

    b

    ef

    U

    0

    `

    U

    g

    `

    ef g h

    X U ef

    U

    0 P

    b

    U

    g

    ef

    U

    0

    XU

    e f g h

    P

    b

    U

    g

    e f g h

    Q

    Modifying the shape of a module, we change its width first, thenchange its height after compacting along the x direction, and compactalong the

    v

    direction at last. Changing width and height at the sametime may cause confusion as there may be surplus space in both of the

    v

    and x directions.After changing the shape of the inserted soft module, we then change

    those of other soft modules. We first compute the surplus space in thev

    and x directions for each soft module. Instead of computing the surplusspace from the contour, we find the space between the soft module andits neighboring ones. After inserting a soft module

    I U, we compute the

    surplus space of a soft moduleI

    in thev

    and x directions from

    and

    respectively.

    Let-

    (-

    ) be the surplus space ofI

    in the horizontal (verti-cal) direction, and

    v

    (

    x ) be the maximumv

    ( x ) coordinate on the vertical(horizontal) contour. We have

    -

    E

    v

    !

    v

    T

    P

    b

    E

    v

    v

    T

    P otherwise P

    -

    E

    x

    !

    x

    W

    P

    b

    E

    x

    x

    W

    P otherwiseQ

    Substituting

    b

    for -

    and

    b

    for -

    , we can obtain thenew

    T

    andW

    similar to the equations shown above.Similar to the processing of the inserted soft module, we change the

    widths and heights of the soft modules one at a time. After changingtheir widths, we compact in the vertical direction. Then we continue tochange their heights and compact in the horizontal direction at last.

  • 7/28/2019 10.1.1.11.9430

    5/6

    b1

    b2

    (a) (d)

    b1 b2

    (c)

    b1

    b2

    (b)

    b1b2

    Figure 7: Four cases of an L-shaped module after rotation. Each is par-titioned into two parts by slicing it along the middle vertical boundary.

    4.3 Rectilinear ModulesWe can partition a rectilinear module into several rectangular sub-

    modules by slicing from left to right along each vertical boundary. Wefirst consider L-shaped modules and then extend to general rectilinearmodules.

    An L-shaped module I can be partitioned into two rectangular sub-modules by slicing

    I along its middle vertical boundary. As shown in

    Figure 7, I 7 and I ' are the sub-modules of I , and we say I 7 P I 'p

    I .During placement, we must guarantee that the two sub-modules

    I

    7 andI

    ' abut, andI

    maintains its original shape. To ensure that the leftsub-module

    I

    7 and the right sub-moduleI

    ' ofI

    abut, we impose thefollowing location constraint(LC for short) for I 7 and I ' :

    : Keep I ' as I 7 s left child in the B*-tree.

    Since modules are placed in the DFS order, keeping I ' as I 7 s leftchild in the B*-tree guarantees that

    I

    7 andI

    ' are placed in sequence.The

    relation ensures that thev

    -coordinate ofI

    ' s left boundaryequals that of I 7 s right boundary. For example, the two sets of sub-modules

    I

    7 P

    I

    ' andI

    P

    I shown in Figure 8(a) abut. The sub-modules

    I

    andI

    are placed at the correct positions whileI

    7

    andI

    '

    are not sinceI

    7 andI

    ' do not conform to their original L shape. We sayI

    7 andI

    ' tobe mis-aligned. To slove the mis-aligned problem, we must adjust the

    x coordinate of I 7 or I ' . For the I 7 and I ' shown in Figure 8(a), forexample,

    I

    7 must be pulled up until the x coordinate ofI

    7 s top (bot-tom) boundary equals that of

    I

    ' s for the L shape shown in Figure 7(a)(Figure 7(d)).

    b1

    0

    1

    2

    b2

    b3b4 b2

    b1

    1

    0

    2

    b3

    b4

    LC relations

    (a) (b)

    Figure 8: Suppose thatI

    7 P

    I

    ' andI

    P

    I are two sets of sub-modules

    corresponding to two L-shaped modules. (a) A placement in whichI

    7P

    I

    ' and I P I abut. However, I 7 and I ' are mis-aligned. (b) Theircorresponding nodes in the B*-tree keep the

    relation betweenI

    7

    andI

    ' (as well asI

    andI

    ).

    For each L-shaped module, there are four orientations after rotation,as shown in Figure 7. Whenever we perform a rotation on an L-shapedmodule, we must repartition it into two sub-modules and maintain theLC relation between them. See Figure 7 for the sub-modules after repar-titioning.

    A rectilinear module is convex if any two points within the modulecan be connected by the shortest Manhattan path which also lies withinthe module; it is concave otherwise. A convex module I can be par-

    titioned into a set of sub-modules I 7 P I ' P Q Q Q P I 0 by slicing I from leftto right along each vertical boundary. Considering the

    relation, wekeep the sub-module I

    U

    7 as IUs left child in the B*-tree to ensure that

    they are placed side by side along thev

    direction, where ` b `

    .To ensure that I 7 P I ' P Q Q Q P I 0 are not mis-aligned, we may need to adjustthe x coordinates of the sub-modules, like what we did for L-shapedmodules. For a concave module, we can fill the concave holes of themodule and make it convex. Then, the operations remain the same asthose for a convex module.

    5 The AlgorithmOur floorplan design algorithm is based on the simulated annealing

    method [4]. The algorithm can consider not only hard modules, but also

    pre-placed, soft, and rectilinear ones.We perturba B*-tree (a feasible solution) to another B*-tree by using

    the following four operations.A Op1: Rotate a module.A Op2: Move a module to another place.A Op3: Swap two modules.A Op4: Remove a soft module and insert it into the best internal or

    external position.

    We have discussed Op1 in Section 4. Op2 deletes and inserts a module.If the deleted node is associated with a rectangular module, we simply

    delete the node from the B*-tree. Otherwise, there will be several nodesassociated with a rectilinear module, and we treat them as a whole andmaintain their

    relations. Op4 deletes a soft module, tries all possibleinternal and external positions, inserts it into the best position, changesits shape and the shapes of the other soft modules (see Section 4.2).Op2, Op3, and Op4 need to apply the

    e andl

    operationsfor inserting and deleting a node to and from a B*-tree. We explain thetwo operations in the following.

    5.1 DeletionThere are three cases for the deletion operation.

    A Case 1: A leaf node.A Case 2: A node with one child.A Case 3: A node with two children.

    In Case 1, we simply delete the target leaf node. In Case 2, we removethe target node and then place its only child at the position of the re-moved node. The tree update can be performed in

    time. In Case

    3, we replace the target node

    by either its right child or left child

    .Then we move a child of

    to the original position of

    . The processproceeds until the corresponding leaf node is handled. It is obvious thatsuch a deletion operation requires

    W

    time, whereW

    is the height ofthe B*-tree. Note that in Cases 2 and 3, the relative positions of themodules might be changed after the operation, and thus we might needto reconstruct a corresponding placement for further processing. Also,if the deleted node corresponds to a sub-module of a rectilinear module

    I

    , we should also delete other sub-modules ofI

    .

    5.2 InsertionWhen adding a module, we may place it around some module, but

    not between the sub-modules that belong to a rectilinear module. Wedefine three types of positions as follows.

    A

    Inseparable position: A position between two nodes associatedwith two sub-modules of a rectilinear module.

    A

    Internal position: A position between two nodes in a B*-tree, but

    is not an inseparable one.A

    External position: A position pointed by a NULL pointer.

    Only internal and external positions can be used for inserting a newnode. For a rectangular module, we can insert it into an internal or anexternal position directly. For a rectilinear module

    I

    consisting of thesub-modules

    I

    7 P

    I

    ' P Q Q Q P

    I

    0 ordered from left to right, the sub-modulesmust be inserted simultaneously, and I

    U

    7 must be the left child of IU

    tosatisfy the

    relation.The simulated annealing algorithm starts by randomly choosing an

    initial B*-tree. Then it perturbs a B*-tree (a feasible solution) to an-other B*-tree based on the aforementioned Op1Op4 until a predefinedfrozen state is reached. At last, we transform the resulting B*-tree tothe corresponding final admissible placement.

    6 Experimental ResultsWe implemented two algorithms in the C++ programming language

    on a 200 MHz SUN Sparc Ultra-I workstation with 256 MB memory.

    One is the iterative, deterministic algorithm used in [1], and the otheris the aforementioned simulated annealing algorithm. The deterministicone is served for the purpose of fair comparison with the O-tree repre-sentation which is the fastest for non-slicing floorplans in the literature.

    We performed two sets of experiments: one was based on the MCNCbenchmark circuits used in [1], and the other on some artificial rectilin-ear modules. Table 2 lists the names of the circuits, the numbers of mod-ules, the runtimes per iteration for the iterative, deterministic algorithm,memory requirements, and chip areas for the cluster refinement algo-rithm [16], the O-tree, the B*-tree based on the iterative algorithm. Wealso tested the total runtimes and areas resulted from using the B*-treebased simulated annealing algorithm. The results show that the B*-treeachieved average speedups (area reductions) of 458 and 4.5 (1.0% and

  • 7/28/2019 10.1.1.11.9430

    6/6