ebook img

Practical Slicing and Non-slicing Block-Packing without Simulated Annealing PDF

31 Pages·2012·0.5 MB·English
by  
Save to my drive
Quick download
Download
Most books are stored in the elastic cloud where traffic is expensive. For this reason, we have a limit on daily download.

Preview Practical Slicing and Non-slicing Block-Packing without Simulated Annealing

Practical Slicing and Non-slicing Block-Packing without Simulated Annealing HaywardH.Chan andIgorL.Markov [email protected],[email protected] March26,2004 Abstract We propose a new block-packer BloBB based on multi-level branch-and-bound. It is competitivewithannealersintermsofruntimeandsolutionquality. Weempiricallyquantify the gap between optimal slicing and non-slicing(cid:3)oorplans by comparingoptimal packings and best seen results. Most ongoing work deals with non-slicing packings, and implicitly assumes that best slicing packings are highly sub-optimal. Contrary to commonbelief, we showthatthegapinoptimalslicingandnon-slicingpackingsisverysmall. Optimalslicing andnon-slicingpackingsforapte,xeroxandhparereported. BloBBtotheblock-packerCompaSS,thathandlessoftblocks. Optimalslicingpackings for soft versions of apte, xerox and hp are reported. We discover that the soft versions of allMCNCbenchmarks,exceptforapte,andallGSRCbenchmarkscanbepackedwithzero dead-space.Moreover,theaspectratiobound[0.5,2]turnsouttobenotveryrestrictive,when area is concerned. Our heuristic slicing block-packeris able to pack with zero dead-space inmostcaseswhenwerestricttheaspectratioboundto[0.57,1.70]. CompaSSimprovesthe bestpublishedresultsfortheami49 Xbenchmarkssuite,outperformingtheleadingmultilevel annealerinruntime,solutionqualityandscalability. Additionally, realistic (cid:3)oorplans often have blocks with similar dimensions, if design blocks, such as memories, are reused. We show that this greatly reduces the complexity ofblack-packing. Contents 1 Introduction 3 2 OptimalNon-slicingPacking 4 2.1 TheO-treeRepresentation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4 2.2 Branching . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 2.3 LowerBoundsandPruning . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 3 OptimalSlicingPacking 8 3.1 NormalizedPolishExpressions (NPEs) . . . . . . . . . . . . . . . . . . . . . . 8 3.2 Branching . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9 3.3 LowerBoundsandPruning . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10 4 Hierarchical SlicingPacking 11 4.1 ConquerOperations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11 4.2 DivideOperations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 5 PackingSoftBlocks 13 5.1 TheShape-CurveRepresentation . . . . . . . . . . . . . . . . . . . . . . . . . . 13 5.2 OptimalSlicingSoftBlockPacking . . . . . . . . . . . . . . . . . . . . . . . . 14 5.3 Hierarchical SoftBlockPacking . . . . . . . . . . . . . . . . . . . . . . . . . . 14 5.4 Post-processing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14 6 ExperimentalResults 15 6.1 OptimalBlock-Packing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 6.2 Hierarchical Block-Packing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16 7 ConclusionsandOngoingWork 17 A Proofs 22 B RealizingaSlicingPacking 24 2 1 Introduction Floorplanning is increasingly important to VLSIlayout as ameans to manage circuit complexity and deep-submicron effects. It is also used to pack dice on a wafer for low-volume and test-chip manufacturing, where all objectives and constraints are in terms of block area and shapes [10]. Abstract formulations involve blocks of arbitrary dimensions and are commonly NP-hard, but in practice many blocks have identical or similar dimensions, and designers easily (cid:2)nd good (cid:3)oor- plansbyaligningthoseblocks. Annealing-based algorithmsthatcurrentlydominatethe(cid:2)eldtend to ignore such shortcuts. Moreover, research is currently focused on (cid:3)oorplan representations rather than optimization algorithms. Slicing (cid:3)oorplans, represented by Polish expressions and slicing trees [15],areconvenient, butmaynotcapture best solutions. Non-slicing representations include sequence-pair [11] and bounded slicing grid [12], O-Tree [5], B*-Tree [3], and TCG-S [9]. Corner block list [6] and twin binary tree [17] are proposed to represent mosaic (cid:3)oorplans. Interestingly, manyVLSIdesigners andEDAtoolsstillrelyonslicingrepresentations whichlead to faster algorithms and produce (cid:3)oorplans with hierarchical structure, more amenable to incre- mentalchangesandECOs. Reported optimal branch-and-bound algorithms for (cid:3)oorplanning [13] run out of steam at around 6 blocks, and those for placement at 8-11 blocks [2]. Their scalability can be improved through clustering at the cost of losing optimality. However, a known algorithm that minimizes area bottom-up, by iteratively re(cid:2)ning clusters appears very slow [16]. A top-down hierarchical framework based on annealing reported in [1] is facilitated by (cid:2)xed-outline (cid:3)oorplanning. Their implementation is faster than a (cid:3)at annealer and (cid:2)nds better (cid:3)oorplans with hundreds and thou- sandsofblocks. Itisalsoshownthatconventionalannealersfailtosatisfythe(cid:2)xed-outlinecontext, andnewtechniques arerequired. Wepropose adeterministic bottom-up block-packer BloBBbased onbranch-and-bound. Itis faster and more scalable than (cid:3)at annealers, but produces comparable results. Unlike annealers, it takes advantage of blocks with similar dimensions and can optimally pack the three smallest MCNCbenchmarks. BloBB can optimize additional objectives that can be computed incremen- tally, such as wirelength. Unlike annealers, it runs faster with additional constraints, e.g., the (cid:2)xed-outline constraint. SinceBloBBcanproduceoptimalpackings,wecanempiricallyquantifythegapbetweenop- timal slicing and non-slicing (cid:3)oorplans. To this end, [4] evaluates the sub-optimality of existing (cid:3)oorplanners by constructing benchmarks with zero dead-space. However, most realistic exam- ples with hard blocks cannot be packed without dead-space, so an optimal block-packer allows one to use more realistic benchmarks for evaluating sub-optimality. BloBB is extended to a soft block-packer, CompaSS.SimilartoBloBB,ithandles largeinstances hierarchically andproduces near-optimalpackings. Despiteitssub-optimality, itisabletopackthesoftversionsofallMCNC benchmarks, exceptforapte,andallGSRCbenchmarks withzerodead-space. Hence,thebench- marks in [4] appear less attractive. Moreover, we empirically show that the aspect ratio bound [0:5;2:0] is not very restrictive by producing zero-dead-space packings under tighter aspect ra- tio constraints. We also outline how one can apply our techniques to handle multi-project reticle (cid:3)oorplanning [10]. Wemakethefollowing conventions intherestofthepaper. Thetermnon-slicing means(cid:147)not necessarilyslicing(cid:148). Allsetsareordered. Apermutationofordernisjustanorderedn-elementset, typically ofblocks B ;:::;B . Thisde(cid:2)nes aprecedence relation onblocks, which areoften 1 n f g (cid:30) referred tobyindices, e.g.,2maydenote block B . Toknowthewidthw andheight h ofblock 2 B B B,oneneedstoknowitsorientation. LocationofBmeanslocationofitsbottom-leftcorner. Given 3 a set of rigid rectangular blocks M = B ;:::;B , a packing of M de(cid:2)nes, for every block B , 1 m i f g its orientation q and planar location (x;y). No two blocks may overlap. The rectangle packing i i i problem is tominimize the area ofthe bounding box ofthe (cid:3)oorplan. Inalternative formulations [1], all blocks need to (cid:2)t into a given bounding box, after which other design objectives, such as wirelength, can be minimized. As we will see, although we design block-packers for the former formulation,thealgorithms canbeextended toaddress thelattereasily. Therestofthepaperisorganized asfollows. Sections2,3,4and5describe our optimalnon- slicing, optimal slicing, hierarchical and soft-block packers respectively. We discuss empirical results in Section 6 and conclude in Section 7. The appendix provides proofs and more details aboutslicing (cid:3)oorplans. 2 Optimal Non-slicing Packing Inthis section, webuild ablock-packer that explores the space ofpartial packings by adding and removing blocks one by one. It maintains a partial packing at a given point of time, and returns theonewiththesmallestbounding boxastheresult. 2.1 The O-treeRepresentation A rooted ordered tree with n+1 nodes can be represented by a bit-vector of length 2n, which records a DFStraversal of the tree. 0 and 1 record downward and upward traversals respectively (Fig.1a). AnO-Treefornblocksisatriplet(T;p;q)whereT isabit-vectoroflength2nspecifying the tree structure, p is a permutation of order n listing the blocks as they are visited in DFS, q is a bit-vector of length n with block orientations (0 for (cid:147)not rotated(cid:148) and 1 for (cid:147)rotated by p=2(cid:148)). (T;p;q) represents a packing by sequencing its blocks according to p. The x-coordinate x of a B newly-added block Bis 0 if its parent Pis the root of T, or else x +w , the sum of the width of P P P(implied byq)anditsx-coordinate. They-coordinate y isthesmallest non-negative value that B preventsoverlapsbetweenBandblocksappearing beforeBinp(Fig.1b). ApackingisL-compact(B-compact)iffnoblockcanbemovedleft(down)whileotherblocks are(cid:2)xed. ApackingisLB-compactiffitisbothL-compactandB-compact. ThepackinginFig.1b is LB-compact. Every LB-compact packing can be represented by an O-Tree, and all packings speci(cid:2)edbyanO-Treeareobviously B-compact. The contour data structure is central to O-Tree related representations since it allows O(n) time for packing realization. A contour of a packing is simply a contiguous sequence of line segmentsthatdescribes theshapeoftheupperedgeofthepacking. Suchlinesegmentsarecalled contour line segments. Fig.1c is an example. Using this data structure while realizing an O-tree, onecan(cid:2)ndthey-coordinate foreachblockinamortizedO(1)time,facilitating therealization of anO-TreewithnblocksinO(n)time[5]. We choose the O-Tree representation because no known representation achieves a smaller amountofredundancy. ApartialO-Treede(cid:2)nesapartialpackingthatcanbeextendedtocomplete packings,andthispropertyfacilitates effectivepruning. WhileB*-treesareequivalent toO-Trees insomesense,wepreferO-treesbecauseoftheirconvenient bit-vectorrepresentation. According to[3],thetwopotentialdisadvantagesofO-Treesare(i)thevaryingnumbersofchildrenpernode, and (ii) the use of constraint graphs to compact non-L-compact packings. However, in our work wedonotexplicitly trackchildren throughparents anddonotusecompaction. 4 (/).*-+, 8?R9>o:=o(cid:6)(cid:6)tzD;<zDggss01Dz01Dz01DzzDzD(())66//))..FF**--++,,(cid:127)(cid:127)QmvvooQm01Qm10Qm10QmQm(((//66///??)))...***---+++,,,vv 01 (66/).*-+,vv 10 (66/).*-+, BB61B5 B7B3B8 B2 B4 BB16B5 B7B3B8 B2 B4 (a) (b) (c) Figure1: TheO-TreeRepresentation. (a) The tree represented by T = 0010001111001101; (b) the packing (T;p;q) where p= B ;B ;B ;B ;B ;B ;B ;B ; (c) the contour of U: 5 3 8 2 4 6 7 1 f g (0;0);(0;3);(3;7);(7;11);(11;12);(12;15);(15;¥) f g 2.2 Branching We adopt a branching schedule in Table 1 such that at each layer of the search tree, we de(cid:2)ne 2 bitsofT,1blockofp,or1bitofq. Ourbasicframeworkisadepth-(cid:2)rstsearch. Table1: BranchingSchedule TreeT: 1 4 7 2bitseachtime (cid:1)(cid:1)(cid:1)(cid:1)(cid:1)(cid:1) Permutationp: 2 5 8 1blockeachtime (cid:1)(cid:1)(cid:1)(cid:1)(cid:1)(cid:1) Orientationq: 3 6 9 1biteachtime (cid:1)(cid:1)(cid:1)(cid:1)(cid:1)(cid:1) A bit-vector identi(cid:2)es a rooted ordered tree iff it has equal numbers of 0’s and 1’s and every pre(cid:2)x has at least as many 0’s as 1’s. Hence, a partial bit-vector t with i 0’s and j 1’s can be extended to one representing arooted ordered tree withnnodes iff(1) i j and (2) i n. These (cid:21) (cid:20) feasibility conditions can be easily checked in O(1) time upon every incremental change to the bit-vector. Infeasible bit-vectors are pruned, and we may get a new feasible bit-vector t at every searchnodeofdepth4i. Suppose (T;p;q) is extended from (t;s;d). Since t has at least i 0’s, the positions of all blocks in s in T are set. Furthermore, since d is as long as s, the orientations of all blocks in s are determined. The position of a block in (T;p;q) depends only on itself and its preceding blocks in p[5]. Wecan then determine the locations of all blocks in s before we explore deeper and (t;s;d)determines apartial packing (Fig.2a). Bykeeping areversible contour structure that supports incremental addition and deletion, the addition and deletion of a block take amortized O(1)time[5]. Wesay(T;p;q)tobeextended from(t;s;d)ifft,s,anddarepre(cid:2)xesofT,p,and qrespectively. Itisanextended packingof(t;s;d). 2.3 LowerBounds and Pruning Insubsequent discussions, weconsiderapartial packingU =(t;s;d)ofiblocksandanextended packing (T;p;q) of n blocks. Let m be the length of the shorter edge (min-edge) of block k for k k=1:::n. WedonotdistinguishbetweenT andthetreepresentedbyT. Similarlyfort. Foreach partialpacking,weapplythefollowingdead-space estimations. MinimumBoundingRectangle. As the positions of the (cid:2)rst i blocks are (cid:2)xed, the bounding rectangle of U is fully contained in any extended packing. Thus, the bounding rectangle offersalowerboundforarea. 5 permanent dead space extended dead space B8 (a) B8 (b) B8 (c) B5 B3 B2 B4 B5 B3 B2 B4 B5 B3 B2 B4 Figure2: MinimumandExtendedDead-Space. (a) A partial packing (t;s;d) with t =0010001111 and s= B ;B ;B ;B ;B . Fig.1b shows a 5 3 8 2 4 f g compatible complete packing; (b) Every block whose x-span intersects with that of B lies above 8 B ,hencetheshowndead-spaceispermanent;(c)thedead-spaceshownispermanentsinceunused 8 blockscannotrestonB . 2 B7 (Lstart, Lend) B7 x5 x8 x2 x4xright B8 B8 B8 B5 B3 B2 B4 B5 B3 B2 B4 B5 B3 B2 B4 (a) (b) (c) Figure3: MaximumMin-edgeEstimation. (a) Lstart x <Lend, (b) enforcing x =Lstart does not increase coordinates of B , (c) a lower 7 7 7 (cid:20) bound can be computed from x-coordinates shown; x can be ignored because the upper edge of 8 B islowerthanthatofB ,andsocanbex . 5 8 4 MinimumDead-Space. Once theposition of ablock Binsisset, no block appearing after Bin pwhosex-span overlapswiththatofBwouldliebelowB. Therefore,alldead-space below everyblock inthepartialpackingispermanent. Thisisillustrated inFig.2b. ExtendedDead-Space. SupposethecontourlinesegmentaboveblockBisshorterthanmin m k=s k 2 and has upper edge lower than its neighbors (e.g. B in Fig.2c), then no unused block can 2 restonit,andthedead-space aboveBispermanent. MaximumMin-EdgeEstimation. ConsiderablockA =s. Inallextendedpackings,Aislocated 2 above the contour of U. A lower bound for area can be produced by considering several alternativelocationsforAabovethecontour. Indeed,letAhaveorientation0in(T;p;q)and x-coordinate x ,suchthatx isbetweenend-points ofsomecontour linesegmentL. IfAis A A movedleftsuchthatx isthebeginning ofL,itsxandycoordinates donotincrease. Hence A thebounding rectangle of(t;s;d)withAinthatlocation isnot greaterthanthatof(T;p;q) (Fig.3). Therefore, weonly have to consider the cases for each contour line segment (even fewer cases need to be considered as shown in Fig.3c). The minimum of areas of all such rectangles,a ,isalowerboundforareaofcompletepackingswithAhavingorientation0. A 0 similarlowerbounda correspondstoorientation1,andleadstoalowerboundmin(a ;a ). 1 0 1 As a trade-off between the pruning ratio and immediate computational overhead, we only consider theblock whoseshorteredgeismax m . k=s k 2 f g MinimumMin-EdgeEstimation. Ift has j 0’s and shas i blocks, then j i. If j>i, then we (cid:21) can locate the next (j i) unused blocks in T. We de(cid:2)ne the minimum square of s as a (cid:0) square with side min m . A lower bound for area can be computed by placing (j i) k=s k 2 f g (cid:0) minimum squares onto the partial packing according the locations speci(cid:2)ed by t (Fig.4). Thismethodisjusti(cid:2)edinAppendix A. 6 d4 d1 d2 d3 D4 D1 D2 D3 Figure4: MinimumMin-edgeEstimation. If the locations of next 4 blocks int are known, we place minimum squares d according to t; d i i occupiesthesameposition int asD . i Symmetry-breaking dramatically shrinks the size of the solution space. While symmetry- breakingisoftennotsuitableforlocalsearchalgorithms[14],itprovidesstrongerboundingcrite- riaforourbranch-and-bound algorithm. LB-CompactnessandO-TreeRedundancy. Some packings represented by O-Trees are not L- compact,andsomeofthemcanbespeci(cid:2)edbymultipleO-Trees. ToprunesuchO-treeswe require that the y-span of each block overlap with that of its parent. The soundness of this pruningcriterion isprovedinAppendix A. Moreover, if B has overlapping y-span with multiple adjacent blocks in the left, then we require the parent of B to be the lowest of these. For example in Fig.1b, we require B to 7 haveparentB insteadofB . 6 1 Dominance. The bounding rectangle of apacking can be inone ofeight orientations. It suf(cid:2)ces toanalyzeonlyoneofthoseorientations. Weformalize thenotions ofcornerasfollows. In thepackingU,ablockislower-leftiff(i)noblockslyingbelowhaveanoverlappingx-span, and (ii) no blocks lying on the left have an overlapping y-span. Similarly for lower-right, upper-left andupper-right. Ablockisacornerblock ifitisoneoftheabove. InFig.1b,B 5 islower-left,B isupper-left, B islower-right, B andB areupper-right. 1 4 4 7 To facilitate pruning, observe that an LB-compact packing always contains unique lower- left, lower-right and upper-left blocks, and at least one upper-right block. We declare the rightmost upper-right block to be the upper-right block. In Fig.1b, B is the upper-right 4 block. Toavoiddominated packings, weimposedominance-breaking constraints: (1) thelower-leftblockB hasorientation 0, lower left (cid:0) (2) B RforeverycornerblockR. lower left (cid:0) (cid:22) Appendix A proves that one can transform any packing to one satisfying (1-2) without increasingarea. Fig.5a-dshowanexample. LetM =max k andI betheindexofthe s k=s lr 2 f g current lower-right block. The index of the lower-right block is at most I =max(I ;M ). lr s Since lower-left block in the partial packing must remain the lower-left block in any of its extended packings, we require B B . Similarly for upper-left and upper-right bottom left I (cid:0) (cid:22) blocks. Wecanimposeevenstrongercriteria inthefollowingspecialcases. Whentherearemorethanoneblock,theupper-leftandlower-rightblocksaredistinct. (cid:15) Hence,wecanrequireB SwhereShasthesecondlargestindexamongthe lower left (cid:0) (cid:22) unpacked blocks. When the current contour is a straight line, we can (cid:3)ip/rotate the partial packing. (cid:15)(cid:15) Therefore, we can require B to have index not greater than all corner blocks lower left (cid:0) ofthispartial packing. 7 (a) P (b) P’ (c) P’’ (d) P’’’ 3 3 5 4 2 1 4 1 1 3 4 2 4 3 2 5 5 1 5 2 Figure5: Dominance-Breaking. Thepacking Psatis(cid:2)es (2.2)butnot(2.1). Whenweapplyana-transformation to getP ,P does 0 0 not satisfy (2.2) anymore. Thus we apply a b-transformation to get P by (cid:3)ipping P to P and 000 0 00 thencompacting toP . Precisede(cid:2)nitions foraandb-transformations aregiveninAppendixA. 000 When there is only one block in the contour, we can (cid:3)ip/rotate the partial packing (cid:15) under that block. Similarly to the above, we require B to proceed all corner lower left (cid:0) block of that partial packing. Moreover, we require B to have index smaller lower left (cid:0) thanthetop-mostblock. BlockswithSameHeightorWidth. If two adjacent blocks B and B0 have the same height and y-coordinate, the cluster formed by B and B can be (cid:3)ipped. We break this symmetry by 0 requiring B B ifBistotheleft ofB,andsimilarly, foradjacent blocks withsamewidth 0 0 (cid:30) andx-coordinate,e.g.,B andB inFig.1b. IftwoblocksB andB inphavethesamewidth 1 6 i j and height (i< j), they are interchangeable and we require B to appear (cid:2)rst in s. These i constraints are compatible with constraints (1-2). since the index of lower-left block does notgrowwhilethoseofothercornerblocksdonotdecrease after(cid:3)ipsintroduced above. 3 Optimal Slicing Packing In this section, we build an optimal block-packer that contains slicing packings only. Unlike the non-slicing packer, it maintains a series of slicing sub-(cid:3)oorplans, and consistently merging or dissembling them. 3.1 NormalizedPolishExpressions(NPEs) A slicing (cid:3)oorplan is a rectangle area recursively sliced by horizontal and/or vertical cuts into rectangularrooms[7]. Apackingisslicingifitsboundingrectangleisaslicing(cid:3)oorplanandeach rectangular room contains exactly a block. Slicing packings can be represented by slicing trees. Each leaf node of a slicing tree represents a block and each internal node represents a horizontal or vertical cut (Fig.6). We can also consider each internal node to be a supermodule, consisting of the two blocks or supermodules represented by its children and merged in the way speci(cid:2)ed by itself. Given a slicing tree T, its Polish expression is the sequence of nodes visited in a post- order traversal of T. It is normalized if it does not contain consecutive +’s or ’s. For example, (cid:3) the expression in Fig.6c is normalized, but that in Fig.6b is not. The set of normalized Polish expressions of length 2n 1 is in a 1-1 correspondence with the set of slicing (cid:3)oorplans with n (cid:0) blocksandhenceitisnon-redundant [15]. Givenaslicing treeT andtheorientations oftheblocks,theslicing packing ofT isapacking speci(cid:2)ed by T such that no vertical (horizontal) cuts can be moved to the left (down), and each block is placed at the bottom-left corner of the room (Fig.6a). Operators + and act on the (cid:3) set of blocks 1;:::;n and supermodules such that A+B (A B) is the supermodule obtained f g (cid:3) by placing B on top of (to the right of) A. Polish expressions use the post(cid:2)x notation for such 8 4 56 (cid:7)(cid:7)(cid:7)(cid:7)(cid:7)(cid:7)(cid:7)+7777777 (cid:7)(cid:7)(cid:7)(cid:7)(cid:7)(cid:7)(cid:7)+7777777 1 2 3 (a) (cid:20)(cid:20)(cid:20)(cid:20)(cid:20)(cid:20)(cid:3)****** (cid:20)(cid:20)(cid:20)(cid:20)(cid:20)(cid:20)(cid:3),,,,,, (b) (cid:20)(cid:20)(cid:20)(cid:20)(cid:20)(cid:20)(cid:3)****** (cid:20)(cid:20)(cid:20)(cid:20)(cid:20)(cid:20)(cid:3),,,,,, (c) 4 5 6 1 (cid:20)(cid:20)(cid:20)(cid:20)(cid:20)(cid:20)(cid:3)++++++ 4 (cid:19)(cid:19)(cid:19)(cid:19)(cid:19)(cid:19)+++++++ (cid:20)(cid:20)(cid:20)(cid:20)(cid:20)(cid:20)(cid:3)****** 3 4 (cid:19)(cid:19)(cid:19)(cid:19)(cid:19)+(cid:19) ++++++ 1 2 3 2 3 5 6 1 2 5 6 Figure6: SlicingFloorplan,SlicingPacking,SlicingTreesandPolishExpressions. (a)Aslicing(cid:3)oorplanandaslicingpacking;(b)aslicingtreerepresenting(a),itsPolishexpression is123 456+ +;(c)anequivalent slicingtreewhosePolishexpression is12 3 456+ +. (cid:3)(cid:3) (cid:3) (cid:3) (cid:3) (cid:3) operators. To evaluate a (cid:3)oorplan, we can simply compute the supermodule that contains all blocks by recursively merging blocks and supermodules. This procedure can be implemented in O(n) time and will be explained later on. Note that we do not keep track of the locations of the blocks throughout the search, but realize the packing after it. The realization procedure for n blocks can be implemented in O(n) time (Appendix B). We compute the locations of the blocks onceafterthebranch-and-bound process andthecomputation takesnegligible timeinpractice. 3.2 Branching A slicing packing of n blocks can be speci(cid:2)ed by (P;q) where P is a Polish expression of length 2n 1andqisabit-vectoroflengthn,storingtheorientationsoftheblocksasdescribedinSection (cid:0) 2.1. WemaintainagrowingPolishexpression pandbit-vectord. Table2: Branchingschedule towards(124 5+;0111) (cid:3) expressionp: 1 3 5 7 8 10 orientationd: 2 4 6 9 We explore symbols of p one by one. If a given symbol is an operand, we explore a bit of d,otherwise another symbol of pis explored (Table 2). Weuse the following characterization of Polish expression [15]. A sequence p over 1;:::;n;+; of length m 2n 1 can be extended f (cid:3)g (cid:20) (cid:0) to a normalized Polish expression iff (1) for every i=1;:::;n, i appears at most once in p, (2) p has more operands than operators and (3) there are no consecutive +’s and ’s in p. The above (cid:3) sequencesarecalledpartialPolishexpressions,andcanbetestedforinO(1)timeperincremental change. Wemaintainaseriesofblocksandsupermodulesusingtwostacks: thebundleandthestorage. Whenwepushanoperandanditsorientationto panddrespectively,wepushtherespectiveblock (withwidthandheightspeci(cid:2)ed) intothebundlestack. Whenwepushanoperator ato p,weare guaranteed to have at least two blocks or supermodules in the bundle. We pop the two top-most blocks in the bundle, A and B, and push them in this order into the storage. We compute the supermodule formed by merging A and B in the way speci(cid:2)ed by a. When we pop an operand b and its orientation from p and q respectively, we pop the top element of the bundle, which is necessarilyb. Whenwepopanoperatorafrom p,wepopthetopelementofthebundle,andpush thetwotop-mostblocksorsupermodules fromthestoragetothebundle(Fig.7). 9 During incremental changes to p and d, stack updates take O(1) time. When we reach a leaf ofthesearchtree,thesupermoduleinthebundleistheboundingrectanglespeci(cid:2)edbyacomplete solution(P;q). 3.3 LowerBounds and Pruning Fortwosupermodules(orblocks)MandN,wede(cid:2)neM NifB B whereB andB arethe M N M N (cid:30) (cid:30) bottom-leftblocksofM andN respectively. Fortwosupermodules (orblocks)AandB,wede(cid:2)ne A+Basthesupermodule formedbyplacingBontopofA,andA BasthatformedbyplacingB (cid:3) intherightofA. WhenweconsidertwopartialPolishexpressions,weimplicitlyassumethatthey areassociated withthesamebit-vector dandhencerepresent twopackings. MinimumDead-Space. The rectangles A+B and A B cannot be changed after A and B are (cid:3) merged. Therefore, the dead-space inside A+Band A Bis permanent. This is illustrated (cid:3) inFig.8a. ExtendedDead-Space. LetR ;:::;R beinthebundlewhereR isatthebottom,andR isatthe 1 m 1 m top and m 2. The next block or supermodule M that R merges with must contain m 1 m 1 (cid:21) (cid:0) (cid:0) R . HencethewidthandheightofM arenotgreater thanthoseofR respectively. m m 1 m (cid:0) Similarly, i=1:::m 1, thenext block M that R merges withmustcontain R :::R . i i i+1 m 8 (cid:0) Hence the widthof M isnot smaller than the maximumof widths ofR for j=i+1:::m. i j Similarlyforitsheight. IncaseswhenboththewidthandheightofR aresmallerthanthose i ofM,wecanlower-bound thedead-space whenR mergeswithM (Fig.8b). i i i Commutativity. A+M is equivalent to M+A, and A M to M A. To break this symmetry (cid:3) (cid:3) whenmergingsupermodulesAandM,onecanrequireA M. Weproposeabetterpruning (cid:30) mechanismbelow. expression: 1 2 1 2 4 1 2 4 * bundle: B B B B B B M 1 2 1 2 4 1 24 (cid:3) storage: B B 4 2 (a) (b) (c) Figure7: Incremental ChangeswithBundleandStorage. (a)Theoriginal con(cid:2)guration; (b)adding 4to(a);(c)adding to(b); removing from(c)yields (cid:3) (cid:3) (b);removing4from(b)yields(a). a a 1 5 3 1 a* 4 2 3 a 6 8 a4 N2 2 7 R2 M B M M (R1 4) * (R2) 3( R5 +) 6 * (R7 8) + R2 a+ 1 2 3 4 (a) (b) Figure8: MinimumandExtendedDead-Space. (a)Thebundle for14 235+6 78+ withregionsofpermanent dead-space a ,a ,a and a ;(b) 1 2 3 4 (cid:3) (cid:3) when R is merged with M , M must contain R and R and hence N ; a (a ) is a lower bound 2 2 2 3 4 2 + (cid:3) fordead-space inR +M (R M )andhence min(a ;a )isalowerboundfordead-space. 2 2 2 2 + (cid:3) (cid:3) 10

Description:
Annealing-based algorithms that currently dominate the field tend .. and height (i < j), they are interchangeable and we require Bi to appear first in σ. of elements per cluster to guarantee that branch-and-bound finishes quickly.
See more

The list of books you might like

Most books are stored in the elastic cloud where traffic is expensive. For this reason, we have a limit on daily download.