GCPrivate.mesa
Copyright © 1986 by Xerox Corporation. All rights reserved.
by Bryan Preas, January 15, 1987 11:46:28 am PST
DIRECTORY
CD, GC, D2Orient, IPCTG, HashTable, IPTop, Rope, Route, RouteDiGraph, RTBasic, RTStructure;
GCPrivate: CEDAR DEFINITIONS
IMPORTS RTBasic =
BEGIN
nameProp: ATOM;
TopologicalOrder: TYPE = RouteDiGraph.Graph;
IntersectionType: TYPE = {normal, inverted}; -- indicates method to connect el or order breaking tee intersections
Channel: TYPE = REF ChannelRec;
ChannelRec: TYPE = RECORD [
name: Rope.ROPENIL,        -- the channel name
connections: HashTable.Table ← NIL,     -- pins and exits on channel per net
width: CD.Number ← 0,         -- actual channel with after routing, estimate before routing
position: CD.Position ← [0, 0],       -- position in coordinate system of containing object
direction: RTBasic.Direction ← horizontal,   -- direction of the channel
lowerIntType, upperIntType: IntersectionType ← normal,
ch: IPCTG.Channel ← NIL,
result: Route.RoutingResult ← NIL,
cdObject, chanShell, bottomOrLeftShell, topOrRightShell, bottomOrLeftExitShell, topOrRightExitShell: CD.Object ← NIL,
topoOrder: RouteDiGraph.Node ← NIL
];
NetDesc: TYPE = REF NetDescRec;       -- channel.connections entry
NetDescRec: TYPE = RECORD [
bottomOrLeftExit, topOrRightExit: BOOLEANFALSE, -- TRUE iff net has exit on indicated side
pinList: LIST OF PhyPinDesc ← NIL      -- physical pins on channel sides to be connected
];
PhyPinDesc: TYPE = REF PhyPinDescRec;    -- physical pin descriptor
PhyPinDescRec: TYPE = RECORD [
instance: RTStructure.Instance ← NIL,
oPin: RTStructure.ObjectPin ← NIL,
pPin: RTStructure.PhysicalPin ← NIL
];
FindTopologicalOrder: PROC [topology: IPTop.Ref] RETURNS [topologicalOrder: TopologicalOrder];
Determine order in which to route channels.
EnumerateChannelsInTopologicalOrder: PROC [context: GC.Context, eachChannel: EachChannelAction] RETURNS [quit: BOOLEAN];
Enumerate routing channels in route order.
EachChannelAction: TYPE = PROC[context: GC.Context, channel: Channel] RETURNS [quit: BOOLEANFALSE];
AssignCoordinates: PROC [context: GC.Context];
Assign locations to all channels and components.
DoDetailRoute: PROC [context: GC.Context] RETURNS [result: GC.Result];
DoInitialGlobalRoute: PROC [context: GC.Context];
CDOrien: PROCEDURE[num: INT] RETURNS [orien: CD.Orientation];
LowerChannelPosition: PROCEDURE[channel: Channel] RETURNS [position: CD.Position] = INLINE {RETURN[RTBasic.PQToXY[channel.direction, LowerChannelPQ[channel]]]};
find lower left position of a channel
UpperChannelPosition: PROCEDURE[channel: Channel] RETURNS [position: CD.Position] = INLINE {RETURN[RTBasic.PQToXY[channel.direction, UpperChannelPQ[channel]]]};
find upper right position of a channel
LowerChannelPQ: PROCEDURE[channel: Channel] RETURNS [pq: RTBasic.PQPos];
find lower left position of a channel in PQ space
UpperChannelPQ: PROCEDURE[channel: Channel] RETURNS [pq: RTBasic.PQPos];
find upper right position of a channel in PQ space
ChannelLimits: PUBLIC PROCEDURE[channel: Channel] RETURNS [lower, upper: INT];
find limits of width of a Phoenix channel
CreateChannels: PROC [context: GC.Context];
create channels for the context
DestroyChannels: PUBLIC PROC [context: GC.Context];
destroy channels for the context
PinOnList: PUBLIC PROC [netDesc: GCPrivate.NetDesc, phyPin: GCPrivate.PhyPinDesc] RETURNS [onList: BOOLEANFALSE];
onList ← TRUE iff phyPin is on the global routing list for net
IncludeOb: PUBLIC PROC [cell: CD.Object, ob: CD.Object,
position: CD.Position←[0, 0], orientation: D2Orient.Orientation←original] RETURNS [application: CD.Instance];
include an object in a cell; position refers to base of interest rect
END.