1. Stack: $Stack and RawStack - One dimensional assembly.
Two layout atoms are registered for specifying a Stack:
$Stack derives layout information from schematic geometry with its attribute proc.
$RawStack assumes a record of type StackForm under the cellType property $StackForm.
The cellType must be either a stack in X or Y. This is determined by looking at the schematic geometry and checking that all cells overlap in X and not Y (by more than one line width) or vice versa.
The record cellType instances are reordered to reflect their order in the stack.
The layout geometry of schematic abutting subcells is examined to determine if the pins on their adjoining sides match exactly (wire, layer, size and spacings). An exact match means that the subcells may be abutted. The size the subcells' interest rectangle (either schematic or layout) at the abutting edge need not be the same.
A routing channel is included in the stack between each pair of non-abutting subcells as well as those subcell pairs which although schematically abutting, do not have matching layout interfaces. A routing channel will be put at the end of the stack if end wires are drawn such that they exit the side of the stack.
The layout size of the subcells is examined to determine what extensions, if any, are required to justify the sides.
Justify: $BestFit tries to position the cells on either side of a channel to (approximately) minimize the size of the channel. Use this mode with cells which could almost be abutted if it were not for some rogue signals requiring a channel.
If a subcell needs a side extension or makes up one side of a channel, the signals which get extended or routed are controlled by the schematic except that implicit globals (parent and subcell publics which do not appear is the schematic) are automatically included.
For $Stack, several properties may be placed on the schematic:
$VerticalMetal: ATOM or ROPE denoting a layer. ($Metal1 or $Metal2).
$FastRoute: when non-NIL implies a faster (possibly less compact) route.
$TrustMe: when non-NIL disables detailed layout interface checks.
$Justify: ATOM specifies $TopRight, $BottomLeft, $BestFit
$TotalLength: INT specifies overall desired length of stack (last channel is widened as rqd.)
$HorizontalStack, REF specifies when non-NIL a horizontal stack. This is used only in the degenerate case of a stack containing just one subcell. It essentially determines which ends of the subcell can have channel routes.
And one property may be placed on the schematic wires:
$w: a REF INT, specifies a larger than default channel trunk wire width.