StixCompact.mesa
Copyright © 1985 by Xerox Corporation. All rights reserved.
Created by Louis Monier, October 22, 1985 11:08:27 am PDT
Louis Monier, December 5, 1985 6:36:49 pm PST
DIRECTORY
CD, RefTab, Stix;
StixCompact: CEDAR DEFINITIONS =   
BEGIN OPEN Stix;
Open to experimentation (in clear, a tarpit)
Types
CompactProc: TYPE = PROC [cellType: CellType, dr: DRules];
Manipulation procedures
-- Input stix, output CD
SimpleExpand: PROC [from, to: CD.Design, stCell: Object] RETURNS [mosOb: Object];
Virtual grid compaction
-- A group is a collection of StickPtr which are "rigidly attached" and move together during a compaction; a group is always defined with respect to an axis;
-- A StickPtr can be in several groups: during an X compaction, a horizontal wire must be in at least two groups: remember that the wire can be thicker than a contact.
Graph: TYPE = REF GraphRec;
GraphRec: TYPE = RECORD[groups: SEQUENCE size: NAT OF Group];
Arc: TYPE = RECORD [g: Group, dist: NAT];
Groups: TYPE = LIST OF Group; -- sorted by coord
Group: TYPE = REF GroupRec;
GroupRec: TYPE = RECORD [
coord: INT,   -- coordinate of the centerline of the group
nodes: Nodes ← NIL,  -- all nodes in the group
insts: StickPtrs ← NIL,   -- all instances having a node in the group
preds: LIST OF Arc,  -- all the incoming arcs
newCoord: INT ← 0,  -- target coordinate after compaction
hasPinOnexternalEdge: BOOLFALSE -- if the group contains a right pin (X) or top pin (Y)
];
-- Compaction: think about adding constaints!
CompactXCmd: PROC [from, to: CD.Design, stCell: Object] RETURNS [mosOb: Object];
CompactXYCmd: PROC [from, to: CD.Design, stCell: Object] RETURNS [mosOb: Object];
CompactX: CompactProc;
CompactY: CompactProc;
CompactXY: CompactProc;
CompactYX: CompactProc;
END.