<> <> <> <> DIRECTORY CD, DABasics, RTBasic, SC, SCPrivate; SCNewRoutePinsUtil: CEDAR DEFINITIONS = { ConnectionType: TYPE = {left, interior, right, unconnected}; PinClass: TYPE = {isPin, isExit}; PinList: TYPE = LIST OF PinInChan; PinInChan: TYPE = REF PinInChanRec; PinInChanRec: TYPE = RECORD[ layer: SC.Layer, net: SCPrivate.Net _ NIL, chanNet: ChanNetDat _ NIL, min, max, depth: SC.Number, pinClass: PinClass _ isPin, chanSide: RTBasic.Side _ bottom, nextPinInChan, prevPinInChan: PinInChan _ NIL, pinConn: ConnectionType _ unconnected, nextPinInNet, prevPinInNet: PinInChan _ NIL, localDensity: INT _ 0 , alwaysUse: BOOLEAN _ FALSE, chanNum: NAT _ 0, component: NAT _ 0, -- for union-find operation adjList: REF ANY _ NIL, dfsLabel: NAT _ 0]; NetDat: TYPE = REF NetDatRec; NetDatRec: TYPE = ARRAY SCPrivate.MaxChanSr OF ChanNetDat _ ALL[NIL]; ChanNetDat: TYPE = REF ChanNetDatRec; ChanNetDatRec: TYPE = RECORD[ net: SCPrivate.Net, firstPin, lastPin: PinInChan _ NIL, -- for all the pins in the net leftmost, rightmost: PinInChan _NIL, -- for net segmet exits: ARRAY SCPrivate.LRSide OF PinInChan _ ALL[NIL], pinCount: INT _ 0]; <> ChanNetList: TYPE = LIST OF ChanNetDat; ChanDat: TYPE = REF ChanDatRec; ChanDatRec: TYPE = RECORD [ head, tail: PinInChan]; <> InitGetChanPins: PROCEDURE [handle: SC.Handle, rowChan: SCPrivate.RowChan]; <> TermGetChanPins: PROCEDURE [handle: SC.Handle, rowChan: SCPrivate.RowChan]; <> EnterPin: PROCEDURE[rowChan: SCPrivate.RowChan, min, max, depth: SC.Number, layer: SC.Layer, net: SCPrivate.Net, side: SCPrivate.TBSide, alwaysUse: BOOLEAN] RETURNS[pinInChan: SCNewRoutePinsUtil.PinInChan]; <> EnterExit: PROCEDURE[rowChan: SCPrivate.RowChan, pos: SC.Number, layer: SC.Layer, net: SCPrivate.Net, side: SCPrivate.LRSide] RETURNS[pinInChan: SCNewRoutePinsUtil.PinInChan]; <<>> <> <> CreateNetDat: PROCEDURE [handle: SC.Handle, rowChan: SCPrivate.RowChan]; <> EnterANetSegInChan: PROCEDURE[handle: SC.Handle, rowChan: SCPrivate.RowChan, net: SCPrivate.Net, pinProc: PinProc, exitProc: ExitProc]; PinProc: TYPE = PROC [min, max, depth: SC.Number, side: SC.Side, layer: SC.Layer, net: SCPrivate.Net]; ExitProc: TYPE = PROC [side: SCPrivate.LRSide, layer: SC.Layer, net: SCPrivate.Net]; <> EnterAllNetSegInChan: PROCEDURE[handle: SC.Handle, rowChan: SCPrivate.RowChan, pinProc: PinProc, exitProc: ExitProc]; <> MoveAPinInChan: PROCEDURE[rowChan: SCPrivate.RowChan, pin: PinInChan, deltaX: SC.Number] RETURNS [scan: BOOLEAN]; <> EnumPinsInNetChan: PROCEDURE[chanNetDat: ChanNetDat, side: DABasics.Side, doEachNetPin: EachNetPinProc]; <> EnumAllPinsInNetChan: PROCEDURE[chanNetDat: ChanNetDat, doEachNetPin: EachNetPinProc]; EachNetPinProc: TYPE = PROC[chanNetDat: ChanNetDat, pin: PinInChan]; <> EnumPinsInChan: PROCEDURE[rowChan: SCPrivate.RowChan, doEachPin: EachPinProc]; EachPinProc: TYPE = PROC[rowChan: SCPrivate.RowChan, pin: PinInChan]; }.