A robust channel router - Computer-Aided Design of Integrated ...

3 downloads 0 Views 890KB Size Report
Uzi Yoeli. Abstract-A new robust channel router, with very simple heuristics, is being introduced. It is able to handle two-layer channels, three-layer channels with ...
IEEE TRANSACTIONS ON COMPUTER-AIDED DESIGN, VOL IO, NO. 2. FEBRUARY 1991

212

A Robust Channel Router Uzi Yoeli

Abstract-A new robust channel router, with very simple heuristics, is being introduced. It is able to handle two-layer channels, three-layer channels with two horizontal layers and one vertical layer (HVH),and three-layer channels with two vertical layers and one horizontal layer 0This . router uses the horizontal layers only for horizontal wires, and the vertical layers only for vertical wires. It is robust in the sense that small changes in the input or in the algorithm do not have a major effect on the results, which is a key feature of its ability to support the wide variety of routing models. The presented router achieves extremely good results. For example, it has routed the Deutsch difficult example in 19 tracks (i.e., in its density) with signilicantly less metal than other published results. For the three-layer case, that example was routed in 10 tracks with no stacked vias, which is better than any other three-layer router published so far.

I. INTRODUCTION

C

HANNEL routing [ l ] is one of the most important problems of IC layout. Channel routing lends itself easily to design methodologies such as gate-arrays and standard-cells, in which the basic chip is divided into logic rows, with routing channels in between them. These design methodologies rely heavily on fully automatic place and route software packages. Routing is generally done in two steps. 1) Global routing, which breaks up the routing problem into a series of independent channel routing problems, one for each channel in the design. 2) Channel routing, which applies a channel router to wire the nets in each channel. Channel routing is also very easy to define, has little input, and has relatively simple metrics that compare the quality of the algorithms. Because of the importance of channel routing, and because its simple definition, it has spawned extensive research, and many algorithms have been proposed in the past few years, both for two-layer routing [2]-[6] and for three-layer routing [7]-[ 111. Channel routing has become so advanced that some designs “force” themselves into a channeled architecture, such as full-custom [12] and PLD’s [13]. The main problem with most algorithms is their erratic nature. As Heyns and Van Nieuwenhove have noted in [14], obtaining the published results for these algorithms is not trivial: sometimes changing a “ > ” to a “ 1 ” has a dramatic effect on the results. As they have also noted, reversing the channel, i.e., exchanging between the top terminals and the bottom terminals, results in a completely different routing. This erratic nature forced the use of different algorithms for two-layer routing, vertical-horizontal-vertical (VHV) three-layer routing, and horizontal-vertical-horizontal (HVH) three-layer routing. Manuscript received April 14, 1989; revised September 15, 1989. The review of this paper was arranged by Associate Editor A. E. Dunlop. The author is with Quick Technologies, Advanced Technology Center, Haifa 31015, Israel. IEEE Log Number 9040612.

The first to attack the inherently erratic nature of heuristic algorithms were Reed, Sangiovanni-Vincentelli, and Santomauro, with their YACR2 algorithm [6].That algorithm works in two steps: the first part is the heuristic part, which need not find the solution, but only come close enough. The second part is the clean-up part, which uses maze routers to resolve the routing conflicts left by the first part. This approach made the algorithm much more robust, and suitable for industrial routers

~

1

.

In the implementation of YACR2, the first step applies a modified left-edge algorithm (LEA), which routes the channel “in density,” while heuristically trying to minimize the number of vertical constraint violations (VCV’s). This step only minimizes, but does not eliminate VCV’s. The second step attacks these VCV’s: it attempts to remove them by using various maze routers. Three types of maze routers were proposed. During this step, horizontal wires can be placed on both layers, in order to resolve VCV’s. YACR2 has three major drawbacks. The initial assignment of tracks to nets, which is done by the modified LEA algorithm, is highly heuristic, and still produces a significant amount of VCV’s. The algorithm uses both routing layers for horizontal routing, and even allows some overlap. The cost functions are sensitive, and require further tuning for three-level routing. Chameleon [7], which is the multilayer descendant of YACR2, produces suboptimal results for three-layer problems. The router proposed in this paper overcomes these problems. It is robust in the sense that small changes in the input or in the algorithm do not have a major effect on the results. The algorithm has a very simple heuristic, with only one heuristic parameter. The same algorithm works for all three problems: the two-layer problem, the HVH problem, and the VHV problem, with extremely good results. For example, the Deutsch difficult example, which has a channel density of 19, was routed in 19 tracks on two layers, and in 10 tracks on three layers, with no stacked vias. In all cases, the results were better than previously published results, either in channel density or in the total length of the nets.

I . I . Overview of i%ree-Luyer Routing The ability to route a channel in three layers instead of in two layers has the potential of reducing the total area of the channel by half. This has an enormous effect on the resulting die size. As fabrication methods advance, the ability to use three layers for routing (either two metal layers plus polysilicon, or three metal layers) is becoming more common, and the need for good three-layer algorithms becomes more urgent. There are two common models for three-layer routing, called HVH and VHV.

0278-0070/91/0200-0212$01.00 0 1991 IEEE

213

YOELI: A CHANNEL ROUTER

'The HVH model uses the first and last layers (also referred to as the bottom and top layers) for horizontal tracks, while the middle layer is used for the vertical wires. This model has the potential of decreasing the width of the channel by half: if n horizontal tracks are required for routing, n / 2 can be placed in one horizontal layer, and the other n/2 tracks in the second holrizontal layer. The length of the HVH channel (i.e., the number of columns) is equal to the length in the two-layer channel. The second model, the VHV model, uses the bottom and top layers for vertical wires, while the middle layer is used for the horizontal tracks. The definition of this model is much less clear than the HVH model, and there are several versions in the literature, which define differently how the terminals are connected: One model [8] allows the terminals to be connected either to the first layer or to the third layer, as needed by the muter. Another model allows the terminals to be connected only to the first layer (141. Both these models do not have a significant effect on the size of the channel: the width of the channel does not change significantly, because only one layer is used for all horizontal tracks. The length of the channel does not change either, because the terminals define this length. In this paper, another model for VHV routing is proposed, which can reduce the area of a channel by half, just as the HVH model: in our model, different terminals are connected to the first and third layer. In each column, two different terminals are connected at each side. Thus a VHV channel with n routing columns is equivalent to a two-layer channel with 2n columns (i.e., twice the length).

l . 2 . Dejnition of the Problem A rectangular channel is defined by two parameters: the 13hannel width, which defines how many tracks are in the channel, and the channel length, which defines how many routing columns are in the channel. Typically, columns may not be added to a channel (except possibly for adding columns at the end), but tracks may be added. The number of tracks required to complete the routing is the most important criterion for the quality of the routing. A netlist defines the connections that should be made. The netlist is represented as two vectors, one for the top side of the channel, and one for the bottom side of the channel. The length of each vector is equal to the length of the channel. A positive integer k indicates a terminal of net k. All terminals of the same net should be connected to each other. Fig. 1 shows a small example, with 2 nets and 3 columns, and a sample routing implementation. The density of the channel at any column is the number of nets crossing that column. The maximum density of all columns of the channel is the channel density, which is a lower bound on the channel width. Routing is done in routing layers. One or more layers are used for horizontal wiring (either exclusively, or predominantly), and the rest of the layers are used for vertical wiring (again, either exclusively, or predominantly). We have chosen to work with the model in which layers are used exclusively for wires of one direction. The reasons for selecting this model are as follows.

Netlist:

2

2

top = < 1 0 1 > bottom = < 2 2 1 >

1

Fig. 1 . A sample channel.

technologies, such as GaAs, do not allow overlapping lines because of crosstalk between the signals. 2) Our ability to use the same algorithm for all three problems we solve relies on the fact that wires in each layer are placed exclusively in one direction. 3) This model was used by most other routers, thus comparison is more meaningful.

11. BASICIDEAS Channel routing is well known to be NP-complete [16]. Therefore, some heuristics must be used. Similarly to YACR2, our main algorithm can be roughly divided into two parts, the first part is heuristic, and the second part is a clean-up phase. The first part assigns tracks to nets in a given channel width, in such a way that all horizontal constraints are satisfied, while the number of vertical conflicts is minimized and made easy to resolve. The second part uses a simple maze-router, which includes a very simple rip-up and reroute mechanism, to resolve all remaining vertical conflicts. These parts, while similar to YACR2 in their tasks, differ in their actual implementation. The most significant improvement over YACR2 is in the track assignment phase: our track assignment algorithm is done track by track, and not column by column. This assignment is done from the outside of the channel towards the middle. In this way, there is plenty of meaningful information available during assignment (e.g., which nets have been assigned to previous tracks), and the quality of the assignment is much higher. The details of the assignment phase are described in Section 111. Section IV then describes the implementation of the maze router. Section V describes a postprocessor, which tries to improve the initial solution. Our router does not use doglegs during track assignment; during this phase, a complete net is assigned to a single track. The second phase, which is the maze router, introduces doglegs only where it cannot be avoided. This approach minimizes the number of doglegs, and hence, the number of vias. This has the following advantages over algorithms which introduce doglegs heuristically.

1) Doglegging consumes routing resources. At each column where a dogleg is used, the net is actually occupying two tracks. 2) Doglegging adds a significant amount of vias. This effect has a penalty both in performance and in manufacturing yield. 3) Minimizing the number of vias is very important in finding good solutions to three-layer routing pmblems, because three-layer problems have more constraints on the use of vias than two-layer problems.

111. TRACKASSIGNMENT 1) Some technologies do not allow overlapping of parallel The track assignment algorithm works track by track. The lines in the two metal layers. Most notably, this limitation assignment of nets to a specific track is made in two steps. applies to all technologies that personalize metal which 1) Compute a weight for each net, which was not yet ashas been prefabricated, such as our ONEMASKTECHNOLsigned to a track. O G Y ~and various PLD's. In addition, extremely fast

214

IEEE TRANSACTIONS ON COMPUTER-AIDED DESIGN, VOL. IO, NO. 2, FEBRUARY 1991

2) Select the set of nets with the maximum total weight, which can all fit on a single track (i.e. with no horizontal constraint violation). Tracks are assigned from the outside of the channel toward the center of the channel. Each time, nets are assigned either to the track which is the topmost track of the remaining channel, or to the track which is the bottommost track of the remaining channel. Consistently with the results in [4] and [14], we have found that alternating tracks gives the best results. Therefore, the algorithm first assigns nets to the topmost track, then to the bottommost track, then to the track which is the second from the top, and so on. 3.1. The

Weight F u n c t i o n

The weight function, which assigns a weight to each net, consists of the following. 1) A heuristic part, which is described in Section 111-3.2. 2) For each column in which the number of nets yet unassigned to tracks is exactly equal to the number of remaining tracks, add a large number (compared to the heuristic part of the weight). This large number is called DENSECOL (we used 10 OOO).

Theorem: The track assignment algorithm which uses such a weight function, has the property that density of the “remaining” channel (i.e., the density of the channel formed by all the nets which were not yet assigned to tracks) never exceeds the number of remaining tracks, regardless of the heuristic function used. This means that when the width of the remaining channel is 0 (i.e., all tracks have been assigned), the remaining channel density must be 0 (i.e., all nets have been assigned). In other words, all nets will get assigned to tracks without generating any horizontal constraint violation. Proo$ If the theorem were not true, then at least during one track assignment, the density, which was before the assignment equal to the width of the remaining channel, would not have been reduced. However, this cannot happen because of the following reasoning. 1) There exists an assignment of nets to tracks, where the number of tracks is equal to the channel density, without any horizontal constraint violation (e.g., the LEA algorithm [17]). 2) Examining the set of nets x in an arbitrary track in this assignment, it has a net in each column in which the density of the column is equal to the channel density. This is obvious from the definition of column density and channel density. 3) The weight of the nets in set x is in the order of magnitude of ncols*DENSECOL, where ncols is the number of columns, the density of which is equal to the channel density. We say “order of magnitude” because the effect of the heuristic part of the weight function can be negative, but is far less than DENSECOL. 4) Since the algorithm selects the set of nets with the maximum total weight, which can all fit on a single track (i.e., with no horizontal constraint violation), and since set x does fit on a single track, the weight of the set of nets selected by the algorithm will be at least the weight of the set x . The only way to select a set with a total weight of the order of magnitude of n c o l s * D E N s E c o L is to select a set with a representative in at least ncols columns which

are at channel density. Since there are exactly ncols columns in which the density is equal to the maximum density of the channel, the selected set will reduce the density in all these columns, and hence, reduce the channel density.

3.2. The (Only) H e u r i s t i c F u n c t i o n The heuristic function used when computing the weight of each net is based on the following observations. 1) VCV’s should be avoided as much as possible. 2) Making the vertical lines as short as possible leaves the most space for conflict resolution. 3) Satisfying the above requirements at dense columns is more important than satisfying these requirements at less dense columns. For example, a VCV in a dense area is much less desirable than a VCV in a relatively nondense area. The latter has a greater probability of being resolved by the maze routing routines.

We have tested several functions, based on these observations, and they usually gave very similar results. This again proves the robustness of the concepts presented in this paper. Nevertheless, we shall describe, for the sake of completeness, the specific function used to produce the results shown later in this paper. That function is as follows. 1) For each column in which the net has a terminal on the side of the channel being routed, add the density of that column to the current weight of the net. This serves all three goals stated above. 2) For each column in which the assignment of the current net to the current track will create a VCV, subtract from the current weight the density of the column, multiplied by a parameter, VCVWEIGHT. This serves goals [l] and [3] stated above. VCVWEIGHT is the only parameter of the algorithm. The practical values we have used are in the range of 5-10. All the results shown in Section VI11 were generated with VCVWEIGHT set to 8. This function is very simple, easily understood, and works very well. It works on channels with cyclic constraints with no modification, which is an important feature in fully automatic reallife systems. Determining whether a VCV will be generated if a net is assigned to the track being handled, requires only knowledge of which nets have already been assigned to tracks: if a track from the top of the channel is being assigned, then a VCV will be created if and only if the net enters from the bottom, and the net entering from the top was not assigned to a track yet. A similar reasoning holds when a track from the bottom of the channel is being assigned. Thus the algorithm does not use the vertical-constraint graph at all. The graph need not be constructed by the router, and the handling of cycles in this graph becomes a nonissue. As an example, we shall show how this function is applied to the channel shown in Fig. 1. Let us assume that the first track being assigned is the top track. In this case, the weights will be as follows. 1) Net #1 has two terminals at the top side of the channel: one terminal is at the first column, which has a density of 2. The second terminal is at the third column, which has a density of 1. Therefore, part [ 11 of the weight function will contribute a total of 3 to the weight of net #l.

215

YOELI: A CHANNEL ROUTER

By assigning net #1 to the top track, no VCV will be generated. Therefore, part [2] of the weight function does not contribute anything to the weight of net #1, and the total weight of net #1 is 3.

for( col = 1 ; col < = channel-length ;col = col t 1 ) { for each net which ends at this column (

compute weightnet

+ totalleftcol-l

totalcol = max( totalcol.l, weightnet t totalleftcol-l ) )

2) Net #2 does not have any terminal at the top side of the channel. Therefore, part [l] of the weight function does not contribute anything to the weight of net #2. By assigning net #2 to the top track, a VCV will be generated at the first column, which has a density of 2. Therefore, part [2] of the weight function will subtract ~*VCVWEIGHTfrom the previous value (which is zero), and the total weight of net # 2 is, therefore, -2*VCVWEIGHT. As a further illustration, let us alternatively assume that the first track being assigned is the bottom track, and not the top track. In this case, the weights of the nets will be computed as follows. 1) Net #1 has one terminal at the bottom side of the channel (in the rightmost column). That column has a density of 1. Therefore, part [ 13 of the weight function will contribute 1 to the total weight of net #1. By assigning net #1 to the bottom track of the channel, a VCV is generated in the leftmost column, which has a density of 2. Therefore, part [2] of the weight function will contribute -2*VCVWEIGHT to the weight of net # I , and the total weight Will be 1-2*VCVWEIGHT.

2) Net #2 has two terminals at the bottom side of the channel. The density at both of these columns is 2 . Therefore, part [l] of the weight function contributes a total of 4 to the weight of net #2. By assigning net #2 to the bottom track, no VCV will be generated. Therefore, part [2] of the weight function does not contribute anything to the weight of net #2, and the total weight of net # 2 is 4. The following section explains which nets are selected for a particular track. From the above weights, it is intuitively clear that net #1 should be preferred over net # 2 for the top track, and that net #2 should be preferred over net # 1 for the bottom track. 3.3. Selecting the Set of Nets The set of nets is selected by a dynamic programming technique. The channel is scanned from left to right, and in each column the maximum weight, totalcol,of a group of nets which are left to that column is computed. When the scan completes, it has computed the maximum weight of the set of nets which can be assigned to the track. Then the list of maximum weights is scanned from right to left, and the actual nets which should be selected are found. Fig. 2 shows the pseudocode for the first part of the algorithm, which computes the maximum weight of the set. In this figure, leftcol denotes the leftmost column of a net. The second part scans the list from right to left. At each column where totalcolis more than total,,,.,, the net which ends at that column is selected, and the scan skips until the left column of that net. The scan then resumes at column leftcol-1, and continues towards the left.

)

Fig. 2. Selecting the optimal group of nets for a track.

1

trk 5 trk 4 trk 3

7

2

3

4

7

9 1 0 1 1 1 2

7 5

6

8

E: topedge = botedge =

-1 ( 0 2 2 2 0 0 0 0 0 ( 0 0 0 0 0 0 0 0 0

1 1 0); 0 1 1):

Fig. 3. A sample channel with nonsmooth edges.

3.4. Nonrectangular Channels The actual channels with which the router deals do not have a smooth bottom and top edge. Actual macrocells have varying height. This makes the edges of the channel, which follow the contours of the macrocells, not even, as shown in Fig. 3. A nonrectangular channel is defined with two additional vectors, each the length of the channel. These vectors indicate how many tracks are occupied by the macrocells. Fig. 3 shows a sample channel, and the two “contour” vectors. The semantics of these “contours” is that when nets are being assigned to a track, some columns are “outside” the channel. For example, when assigning nets to track 1 (the bottom-most track), columns 11 and 12 are outside the channel. Any net which spans across these columns may not be assigned to track 1. In order to handle nonrectangular channels, the weights of all nets which may not be assigned to the track being handled are set to zero.

IV. MAZE ROUTING After the track assignment, the vertical wires can be placed at all columns in which there is no vertical constraint violation. In all other columns, a cleanup router must be used to perform the connections. This is done by using a simple maze router. YACR2 originally used three different maze routers, from which we have chosen only one. Maze1 was not used because it places horizontal wires on the layer used for vertical wires, and we have chosen to work with a model which forbids such wires. Maze2 connects one of the two vertical segments directly, and the other vertical segment with a single dogleg. This maze router was selected for our implementation. The reasons are that this type of connection requires the minimum extra space, and is the most effective for conflict resolution. Maze3, which requires two additional tracks in order to resolve a conflict did not prove worthy, and was not included. In addition, we have implemented a very simple, yet effective ripup and retry algorithm. Following the terminology of [6], the vertical constraint being resolved has net n, connected to the top of the channel, and net nb connected to the bottom of the channel. Net n, has been assigned to track s, and net nh has been

IEEE TRANSACTIONS ON COMPUTER-AIDED DESIGN, VOL. 10, NO. 2, FEBRUARY 1991

216

the simplest optimization of this sort would be to move to Metal2 any Metal-1 segments which do not cross over any Metal-2. However, since we have confined ourselves to the model in which horizontal segments are placed only in Metal-1 , and vertical segments are placed only in Metal-2, such an optimization is impossible. Therefore, the number of vias actually used is higher than in systems which do not have this restriction (e.g., YACR2).

VI. HVH THREE-LAYER ROUTING

(C)

(4

Fig. 4. An example of ripup and retry.

assigned to track p , where track s is below track p. Maze2 attempts to connect one of the two nets directly, while using a dogleg for the other net. The following discussion assumes that nb is connected directly, and that a dogleg is attempted for net n,. Maze2 scans all tracks from the top of the channel down till trackp. For each track r, the columns are scanned as long as track r is available, looking for a column from which track r can be connected to the net in the target track. When searching track r for a suitable column, if the beginning of a horizontal segment is found which is connected only to one side of the channel, then our ripup routine will remove that vertical wire and the corresponding horizontal segment, and utilize that column to complete the routing of net n,. The net which has been ripped up is the reconnected one using the same modified maze2 algorithm. Fig. 4 shows an example of maze routing being used to resolve a VCV. In Fig. 4(a), the top terminal of net n, must be connected to track s; the bottom terminal of net nb is connected to trackp. A possible result of the ~ a z e 2router is shown in Fig. 4(b). In Fig. 4(c) another net is shown, which blocks the routing. Our maze router would then rip that net, and reconnect it as shown in Fig. 4(d). If the maze router was not successful, more tracks must be used. Adding tracks is done by the channel router as follows: first, it uses the existing track assignment, adds one track, and then applies the maze router. If this does not succeed, the algorithm restarts from track assignment. V. THE POSTPROCESSOR After a successful routing has been found, a common practice is to use a postprocessor, which makes some local improvements in the result. This is somewhat similar to peephole optimization in compilation. In our implementation, we have used a simple postprocessor, which attempts to improve the metal length, at the possible expense of adding vias. The idea is to try and “push” each horizontal metal segment toward the side of the channel in which its terminals are. For the purpose of optimization, a segment is between two consecutive terminals of the net, and not the entire net. Thus this process can add “doglegs. ” The post-processor is controlled by a parameter, called COST-OF-VIA, which indicates how much metal should be saved to justify the addition of a via. Another postprocessor which is commonly used is one that attempts to minimize vias. Assuming that horizontal segments are in Metal-1, and that vertical segments are in Metal-2, then

An important feature of the proposed algorithm is that it is well suited for three-layer channel routing, in addition to the two-layer routing. The HVH stands for “horizontal-verticalhorizontal,” meaning that the middle layer is used for all vertical wirings, and the other two layers, one below and one above, are used for the horizontal wiring. In the following discussion, these layers will also be referred to as Metal-1 , Metal2, and Metal-3. The Metal-2 layer is the one used for vertical wiring. The conversion of a two-layer solution to a three-layer solution is as follows: take track #1 from the two-layer solution, and make it track #1 of Metal-1 in the three-layer solution. The second track is made track #1 of Metal-3, the third track is made track # 2 of Metal-1, and so on. In general track n, where n is 1 ) / 2 in Metal-1 in the three-layer odd, is made track ( a solution, and track n, when n is even, is made track n / 2 in Metal-3. The final width of the resulting three-layer channel is exactly half of the width of the original two-layer channel. This conversion is possible in general, however, consider the following situation.

+

A via in track r, column c, where r is odd, will become a connection between Metal-1 and Metal-2. A via in the same column, in track r + 1, will become a connection between Metal-2 and Metal-3, which is placed exactly on top of the previous via. The construct is called “stacked vias.” These two vias become shorted together because they use the same Metal-2. Thus the conversion is admissible only if both vias belong to the same net, and the manufacturing processes allows stacking vias one on top of the other. In short, the following is shown. 1) A two-layer solution can be mapped into a HVH threelayer solution, when stacked vias are not allowed, if at no column vias are placed both in track r ( r being odd) and in track r + 1. 2) A two-layer solution can be mapped into a HVH threelayer solution, when stacked vias are allowed, if at no column vias are placed both in track r ( r being odd) and in track r + 1, and the two vias belong to different nets. The modifications required to our algorithm in order to meet the above restrictions are as follows. 1) The definition of a VCV, as used by the heuristic function and by the maze router, is extended as follows to include the case of stacked vias: if at any column, the net which enters the channel from the bottom was assigned to track r ( r being odd), and the net which enters the channel from the top was assigned track r 1, then this is also considered a vertical-constraint violation. This affects the heuristic weight function, which gives a negative value to each VCV.

+

217

YOELI: A CHANNEL ROUTER even cdd

-*-

I

even -t(horizontal) tdd

j

*-*

-*-

(a)

-

-*-

[

(*

even

I 11

A

*

Metal-1 Metal-2 (vertical) Via

(b)

Fig. 5 . Placing vias in a HVH three-layer channel.

2) When doing maze routing, the limitations on the allowed places for vias must be considered. That is, the maze router must obey rule [l] above if stacked vias are not allowed, and must obey rule [2] above if stacked vias are allowed. A very important property of this algorithm is that it never generates stacked vias. While most fabrication processes forbid stacked vias, most known HVH routers generate stacked vias [81,[91. In order to show that the algorithm will not generate stacked vias, we consider the construct in the solution of the two-layer muting problem which will lead to stacked vias in the threelayer version of the solution: the equivalent of stacked vias in the two-layer router is a vertical wire with length of 1 from an odd track to the track immediately above it, as shown in Fig. 5(a). Since the track assignment algorithm does not use doglegs, the only source of such a wire is maze routing. However, in this case, there is no reason to perform maze routing at all: if net nb can reach track j (where j is odd), it can also reach track j 1. The actual routing, which does not require any maze routing, is shown in Fig. 5(b).

+

VII. VHV THREE-LAYERROUTING The proposed algorithm is also well suited for the VHV threelayer channel routing problem. VHV stands for “vertical-horizontal-vertical,” meaning that the middle layer is used for all hlorizontal wirings, and the other two layers are used for the vertical wiring. In the full VHV model, as we have defined it, terminals of the channel appear in both vertical layers (i.e., both in Metal-1 and in Metal-3). In the formal problem definition, the channel is described with two pairs of vectors (i.e., a total of four vectors) which indicate the following: 1) 2) 3) 4)

the Metal-1 the Metal-3 the Metal-1 the Metal-3

terminals terminals terminals terminals

of of of of

the the the the

bottom of the channel, bottom of the channel, top of the channel, top of the channel.

Solving a VHV routing problem can be done as follows. Build an equivalent two-layer problem, by merging the Metal-1 and Metal-3 vectors of each side of the channel into a single vector, which is twice the length. The simplest way to perform the merge is to take the first column of Metal-I as column #1 in the two-layer problem, the first column of Metal-3 as column # 2 of the two-layer problem, and so on. In general, column n from Metal-1 will become column 2n - 1 in the two-layer problem, and column n from Metal-3 will become column 2n. Solve the two-layer problem. Separate back the vertical columns into Metal-1 and Metal-3.

As with the HVH model, the conversion from the two-layer solution to the VHV solution is completely transparent, provided the following situation is taken into consideration.

A via in track r, column c, where c is odd, would become a connection between Metal-1 and Metal-2. A via in the same track, in column c + 1, would become a connection between Metal-2 and Metal-3, which is placed exactly on top of the previous via, i.e., “stacked vias” will be generated. The rules to be obeyed are very similar to the rules used for HVH routing: in the HVH routing model, two vias cannot be on adjacent tracks in the same column (i.e., one above the other), the rules in the VHV model does not allow them to be on adjacent columns in the same track (i.e., side by side). The exact rules are also very similar to the rules which apply to the HVH model. 1) A two-layer solution can be mapped into a VHV threelayer solution, when stacked vias are not allowed, if at no track vias are placed both in column c (c being odd) and in column c + 1. 2) A two-layer solution can be mapped into a VHV threelayer solution, when stacked vias are allowed, if at no track vias are placed both in column c (c being odd) and in column c + 1, and the two vias belong to different nets. The modification required to our algorithm in order to meet the above restrictions are as follows. If a net starts at an even column, it is assumed to start at the odd column which precedes it. Similarly, if a net ends at an odd column, it is assumed to extend one more column. The reason is that two such nets cannot be placed in the same track in the VHV model, because that would cause their two vias to be shorted. This rule is analogous to the first rule in the HVH model: there the term “vertical constraint” was enhanced, and here the term “horizontal constraint” is enhanced. When doing maze routing, the limitations on the allowed places for vias must be considered. That is, depending on whether stacked vias are allowed or not, rule [2] or rule [ l ] above, respectively, must be followed. VIII. ACTUALRESULTS The algorithms have been implemented in C, and are part of our automatic layout system for our ONEMASKTECHNOLO G Y ~ and ~ , for conventional gate arrays. The system runs on Apollo workstations. It has been successfully applied to dozens of applications, with a total of several hundreds of channels. The same algorithm was used to implement both two-layer and three-layer channel routing. It was able to solve the Deutsch difficult example in all combinations. The two-layer problem was solved in 19 tracks, with no horizontal metal on the vertical layer, and with no vertical metal on the horizontal layer. It used significantly less metal length than any other router working in this model, and required only 1.2 CPU seconds on a DN3500. The heuristic part resulted in 12 vertical conflicts. Only one of these conflicts required ripup to be performed. The performed router was tried on all examples in the Yoshimura and Kuh paper [4] and they were all routed in their density, in all three combinations. The total length of nets is significantly less than other published results. For example, the total length of nets we achieved for the channel titled “example 5” is 2517, opposed to their result of 2772.

IEEE TRANSACTIONS ON COMPUTER-AIDED DESIGN, VOL. 10, NO. 2, FEBRUARY 1991

218

TABLE I RESULTSOBTAINED WITH OUR ROBUST CHANNEL ROUTER

HVH 3-layer

2-layer Name

Density

fig1 ex3a ex3b ex3c ex4 ex5 diff

VHV 3-layer

Trks

Cols

Metal

Vias

Trks

Cols

Metal

Vias

Trks

Cols

Metal

Vias

5

5

15 17 18 17 20 19

15 17 18 17 20 19

12 62 61 79 119 119 175

74 1,302 1,604

22 93

3 7.5 8.5 9

12 62 61 79 119 119 175

61 1,091 1,254 1,462 1,965 2,001 3,917

24 93 111 126 191

5 15

20 20

59 884 1,200 1,358 1,754 1,824 3,840

22 93 114 126

155

6 31 31 40 60 60 88

1,855

2,475 2,517 4,961

111

126 186 155 319

8.5

10 10

17 18 17

320

185 155

324

Note: Half a track in the HVH model means that one of the two horizontal layers is not used.

TABLE I1 COMPARISON OF TWO-LAYER DIFFICULT EXAMPLE

Router Robust including Post-Processor Robust without Post-Processor Hierarchical [5] Efficient [4] YACR2 [6] MIGHTY [18]

Netlist:

2

0

Tracks

Horizontal Wires on Both Layers

Vertical Wires on Both Layers

Vias

NetLength

19

No

No

319

4,961

19 19 20 19 19

No No No Yes Yes

No No No No Yes

313 336 308 287 303

5,021 5,023 5,075 5,020 4,838

top = < 1 1 2 > bottom = < 2 0 1 >

1

Fig. 6. An example with a cyclic constraint. Fig. 8. 10-track HVH routing of the Deutsch difficult example.

Fig. 7. 19-track routing of the Deutsch difficult example. Fig. 9. 20-track VHV routing of the Deutsch difficult example.

Table I shows the results of our router for all the examples in Yoshimura and Kuh’s paper, as well as the difficult example. The results for the difficult example are compared with other routers in Table 11. It can be seen that the Robust Router performed better than any other router which also limits each layer to a specific direction, but some routers which do not conform to this limitation achieve better results. Fig. 7 shows our 19track routing for that example, Fig. 8 shows our 10-track threelayer HVH routing, and Fig. 9 shows our 20-track three-layer VHV routing. Comparing these three figures shows a high similarity in the results, which again comes to prove the robustness of the algorithms. Handling Cyclic Constraints: As an example of handling cyclic constraints, we have taken the simplest example, as it appears in 14, fig. 31. In this example, track assignment was

done using two tracks, which is the channel’s density. However, the maze router did not succeed with two tracks, so a third track was added using the previous track assignment. The router then generated the correct result, as shown in Fig. 6. Testing the Robustness of the Algorithm: In order to test the robustness, we have taken a large “real-life” channel, from one of the devices we have done. The length of the channel is 288 columns, and there are 157 nets to be routed. In this channel, we have swapped adjacent terminals on one side of the channel. This seems like a minor change in the input, but it completely alters the vertical-constraint graph. A total of 100 variants have been tested. The height of the vertical-constraint graph was between 10 and 17. Six of the variants had cycles in the vertical-constraint graph, with the longest cycles containing 8 nets. In all these examples, the channel was routed at density.

219

YOELI: A CHANNEL ROUTER

TABLE I11 COMPARISON OF NUMBER OF TRACKS REQUIRED FOR THREE-LAYER EXAMPLES Name ex3a ex3b ex3c diff

Density

Robust

15

7.5 8.5 9

17 18 19

10

Cham [7]

C,W&L Feature

Robust

[IO1

Uje horiz. layer for vertical wires Stacked vias Number of vias Total metal length

No None 320 3,917

Yes 3 360

-

Note:

“-”

-

181

8

8

10

10

10 11

9 14

TABLE IV OF THREE-LAYER DIFFICULT EXAMPLE COMPARISON

-

C&L

J,L&W [ I 11 Yes 330 4,009

means unknown to author.

Moreover, the standard deviation in the total metal length was only 0.16%, and the standard deviation in the number of vias used was 0.4%. Three-Layer Routing: A significant improvement can also be seen in the HVH three-layer routing, as shown in Tables 111 and I V . Our router has been able to route all the examples in Yoshiniura and Kuh’s paper in their density, as well as the difficult example. Two algorithms recently published, one by Cong, Wong, and Liu [IO] and one by Jou, Lee, and Wand [ 111 obtain similar results in terms of channel densities. However, both tnese routers use the horizontal layers for vertical routing. In addition, the quality of our routing is much better, as seen in Table IV.

Greedy [91

C, W & L [lo1

J, L & W [ I 11

8 10 10 11

7.5 8.5 9

8 9 9 10

10

[8] Y. K. Chen and M. L. Liu, “Three-layer channel routing,” IEEE Trans. Computer-Aided Design, vol. CAD-3, pp. 156-163, 1984; [9] P. Bruell and P. Sun, “A ’greedy’ three-layer channel router, in Proc. 1985 Int. Con$ Computer-Aided Design, 1985, pp. 298300. [lo] J. Cong, D. F. Wong, and C . L. Liu, “A new approach to the three layer channel routing problem,” in Proc. 1987 Int. Con6 Computer-Aided Design, 1987, pp. 378-381. [ I l l J. M. Jou, J. Y. Lee, and J. F. Wang, “A new three-layer detailed router for VLSI layout,” in Proc. 1987 Int. Conf. Computer-Aided Design, 1987, pp. 382-385. [12] M. Rose et a l . , “Dense, performance directed, auto place and route,” in Proc. 1988 Custom Int. Circuit Conf., 1988, pp. 11.1.1-11.1.4. [13] A. El Gama1 et a l . , “An architecture for electrically configurable gate arrays,” in Proc. 1988 Custom Int. Circuit Conf.,1988, pp. 15.4.1-15.4.4. [I41 W . Heyns and K. Van Nieuwenhove, “Recursive channel router,” in Proc. 25th Design Automation Conf.,1988, pp. 178182. [15] C. H. Ng, “An industrial world channel router for non-rectangular channels,” in Proc. 23rd Design Automation Conf.,1986, pp. 490-494. [16] T. G. Szymanski, “Dogleg channel routing is NP-complete,” IEEE Trans. Computer-Aided Design, vol. CAD-4, pp. 31-41, Jan. 1985. [I71 A. Hashimoto and J. Stevens, “Wire routing by optimizing channel assignment,” in Proc. 8th Design Automation Conf., 1971, pp. 214-224. [I81 H. Shin and A. Sangiovanni-Vincentelli, “MIGHTY: A ‘rip-up and reroute’ detailed router,” in Proc. 1986 Int. Conf. Computer-Aided Design, 1986, pp. 2-5.

REFERENCES M. Burstein, “Channel routing,” in Layout Design and Veri$Amsterdam, The Netherlands: North Holland, 1986, pp. 133-167. D. Deutsch, “A dogleg channel router,” in Proc. 13th Design Automation Conf.,1976, pp. 425-433. R. L. Rivest and C. M. Fiduccia, “A ‘greedy’ channel router,” in Proc. 19th Design Automation Conf., 1982, pp. 418-424. T. Yoshimura and E. S. Kuh, “Efficient algonthms for channel routing,” IEEE Trans. Computer-Aided Design, vol. CAD-1, pp. 25-35, 1982. M . Burstein and R. Pelavin, “Hierarchical channel router,” in Proc. 20th Design Automation Conf., 1983, pp. 591-597. J. Reed, A. Sangiovanni-Vincentelli,and M. Santomauro, “A new symbolic channel router: YACR2,” IEEE Trans. ComputerAided Design, vol. CAD-4, pp. 208-219, July 1985. D. Braun et al., “Chameleon: A new multi-layer channel router,” in Proc. 23rd Design Automarion Conf., 1986, pp. 495502.

cation, T. Ohtsuki, Ed.

* Uzi Yoeli received the B.Sc. degree in computer science in 1977 from the Technion, Israel Institute of Technology. He was with Intel Israel from 1982 till 1987, where he was responsible for the development of several C and PL/M compilers. Since 1987 he has been with Elron’s Microelectronic Operations, now called Quick Technologies, which specializes in rapid prototyping of gate arrays. As manager of software development and IC design, he is responsible for the development of place and route software, as well as for the design of gate array families.