CreateCoreTiny:
PROC []
RETURNS [CoreCompose.Context, Core.CellType] =
Create a Core design
BEGIN
context: CoreCompose.Context ← CoreCompose.CreateContext[];
nandWires: CoreCompose.WireSequence ← CoreCompose.CreateWires[context, "InA, InB, Out"];
nand: Core.CellType ← CreateRecordCell[context, "NAND", nandWires, NIL, NIL];
invWires: CoreCompose.WireSequence ← CoreCompose.CreateWires[context, "In, Out"];
inverter: Core.CellType ← CreateRecordCell[context, "Inverter", invWires, NIL, NIL];
nandInst: CoreClasses.CellInstance ← CreateInstance[context, "InA, InB, NOut", nand, "nandInst"];
invInst: CoreClasses.CellInstance ← CreateInstance[context, "NOut, Out", inverter, "invInst"];
pubWires: CoreCompose.WireSequence ← CoreCompose.CreateWires[context, "InA, InB, Out"];
privWires: CoreCompose.WireSequence ← CoreCompose.CreateWires[context, "NOut"];
SCTest: Core.CellType ← CreateRecordCell[context, "SCTest", pubWires, privWires, LIST[nandInst, invInst]];
IF debug
THEN {
out:
IO.
STREAM ← ViewerIO.CreateViewerStreams[
name: "Core: SCTest",
viewer: NIL,
editedStream: FALSE].out;
CoreClasses.RecordPrint[NARROW[SCTest.data], out]};
RETURN [context, SCTest];
END;
CreateCoreSmall:
PROC []
RETURNS [CoreCompose.Context, Core.CellType] =
Create a Core design
BEGIN
context: CoreCompose.Context ← CoreCompose.CreateContext[];
nandWires: CoreCompose.WireSequence ← CoreCompose.CreateWires[context, "InA, InB, Out"];
nand: Core.CellType ← CreateRecordCell[context, "NAND", nandWires, NIL, NIL];
nandInst11: CoreClasses.CellInstance ← CreateInstance[context, "Col1, Row1, nandInst11W", nand, "nandInst11"];
nandInst12: CoreClasses.CellInstance ← CreateInstance[context, "Col2, nandInst11W, nandInst12W", nand, "nandInst12"];
nandInst13: CoreClasses.CellInstance ← CreateInstance[context, "Col3, nandInst12W, nandInst13W", nand, "nandInst13"];
nandInst14: CoreClasses.CellInstance ← CreateInstance[context, "Col4, nandInst13W, nandInst14W", nand, "nandInst14"];
nandInst15: CoreClasses.CellInstance ← CreateInstance[context, "Col5, nandInst14W, nandInst15W", nand, "nandInst15"];
nandInst21: CoreClasses.CellInstance ← CreateInstance[context, "Col1, Row2, nandInst21W", nand, "nandInst21"];
nandInst22: CoreClasses.CellInstance ← CreateInstance[context, "Col2, nandInst21W, nandInst22W", nand, "nandInst22"];
nandInst23: CoreClasses.CellInstance ← CreateInstance[context, "Col3, nandInst22W, nandInst23W", nand, "nandInst23"];
nandInst24: CoreClasses.CellInstance ← CreateInstance[context, "Col4, nandInst23W, nandInst24W", nand, "nandInst24"];
nandInst25: CoreClasses.CellInstance ← CreateInstance[context, "Col5, nandInst24W, nandInst25W", nand, "nandInst25"];
nandInst31: CoreClasses.CellInstance ← CreateInstance[context, "Col1, Row3, nandInst31W", nand, "nandInst31"];
nandInst32: CoreClasses.CellInstance ← CreateInstance[context, "Col2, nandInst31W, nandInst32W", nand, "nandInst32"];
nandInst33: CoreClasses.CellInstance ← CreateInstance[context, "Col3, nandInst32W, nandInst33W", nand, "nandInst33"];
nandInst34: CoreClasses.CellInstance ← CreateInstance[context, "Col4, nandInst33W, nandInst34W", nand, "nandInst34"];
nandInst35: CoreClasses.CellInstance ← CreateInstance[context, "Col5, nandInst34W, nandInst35W", nand, "nandInst35"];
nandInst41: CoreClasses.CellInstance ← CreateInstance[context, "Col1, Row4, nandInst41W", nand, "nandInst41"];
nandInst42: CoreClasses.CellInstance ← CreateInstance[context, "Col2, nandInst41W, nandInst42W", nand, "nandInst42"];
nandInst43: CoreClasses.CellInstance ← CreateInstance[context, "Col3, nandInst42W, nandInst43W", nand, "nandInst43"];
nandInst44: CoreClasses.CellInstance ← CreateInstance[context, "Col4, nandInst43W, nandInst44W", nand, "nandInst44"];
nandInst45: CoreClasses.CellInstance ← CreateInstance[context, "Col5, nandInst44W, nandInst45W", nand, "nandInst45"];
nandInst51: CoreClasses.CellInstance ← CreateInstance[context, "Col1, Row5, nandInst51W", nand, "nandInst51"];
nandInst52: CoreClasses.CellInstance ← CreateInstance[context, "Col2, nandInst51W, nandInst52W", nand, "nandInst52"];
nandInst53: CoreClasses.CellInstance ← CreateInstance[context, "Col3, nandInst52W, nandInst53W", nand, "nandInst53"];
nandInst54: CoreClasses.CellInstance ← CreateInstance[context, "Col4, nandInst53W, nandInst54W", nand, "nandInst54"];
nandInst55: CoreClasses.CellInstance ← CreateInstance[context, "Col5, nandInst54W, nandInst55W", nand, "nandInst55"];
pubWires: CoreCompose.WireSequence ← CoreCompose.CreateWires[context, "Row1, Row2, Row3, Row4, Row5, Col1, Col2, Col3, Col4, Col5, nandInst15W, nandInst25W, nandInst35W, nandInst45W, nandInst55W"];
privWires: CoreCompose.WireSequence ← CoreCompose.CreateWires[context, "nandInst11W, nandInst12W, nandInst13W, nandInst14W, nandInst21W, nandInst22W, nandInst23W, nandInst24W, nandInst31W, nandInst32W, nandInst33W, nandInst34W, nandInst41W, nandInst42W, nandInst43W, nandInst44W, nandInst51W, nandInst52W, nandInst53W, nandInst54W"];
SCTest: Core.CellType ← CreateRecordCell[context, "SCTest", pubWires, privWires, LIST[nandInst11, nandInst12, nandInst13, nandInst14, nandInst15, nandInst21, nandInst22, nandInst23, nandInst24, nandInst25, nandInst31, nandInst32, nandInst33, nandInst34, nandInst35, nandInst41, nandInst42, nandInst43, nandInst44, nandInst45, nandInst51, nandInst52, nandInst53, nandInst54, nandInst55]];
IF debug
THEN {
out:
IO.
STREAM ← ViewerIO.CreateViewerStreams[
name: "Core: SCTest",
viewer: NIL,
editedStream: FALSE].out;
CoreClasses.RecordPrint[NARROW[SCTest.data], out]};
RETURN [context, SCTest];
END;
libName: Rope.ROPE ←"ArbiterParts.dale";