DAUserCmdsImpl.mesa
Copyright © 1986 by Xerox Corporation. All rights reserved.
Last Edited by: Louis Monier January 7, 1987 8:15:20 pm PST
DIRECTORY CD, CDMenus, CDSequencer, Core, CoreFlat, CoreOps, CoreProperties, IO, PW, PWCore, SinixOps, Sisyph, Static, TerminalIO;
DAUserCmdsImpl: CEDAR PROGRAM
IMPORTS CDMenus, CoreFlat, CoreOps, CoreProperties, IO, PW, PWCore, SinixOps, Sisyph, Static, TerminalIO
= BEGIN
ExtractAndLayout: PROC [comm: CDSequencer.Command] = {
ob: CD.Object;
root, cellType: Core.CellType;
[root: root, cell: cellType] ← SinixOps.SelectedCellType[comm.design, Sisyph.mode];
IF root=NIL THEN RETURN; -- Extraction ended in error, message already printed
PW.WriteF["\nGenerating layout for %g.\n", IO.rope[CoreOps.GetCellTypeName[cellType]]];
ob ← PWCore.Layout[cellType];
[] ← PW.Draw[ob];
};
-- We use the cutsets specified by Logic
ExtractAndStatic: PROC [comm: CDSequencer.Command] = {
root, cellType: Core.CellType;
[root: root, cell: cellType] ← SinixOps.SelectedCellType[comm.design, Sisyph.mode];
IF root=NIL THEN RETURN; -- Extraction ended in error, message already printed
PW.WriteF["\nStatic checking %g.\n", IO.rope[CoreOps.GetCellTypeName[cellType]]];
Static.CountDirectConnections[cellType, Static.CheckCount, IF CoreProperties.GetCellTypeProp[cellType, Static.staticCutSetProp]=NIL THEN CoreFlat.CreateCutSet[labels: LIST["Logic", "LogicMacro"]] ELSE NIL];
PW.WriteF["Finished static checking %g.\n", IO.rope[CoreOps.GetCellTypeName[cellType]]];
};
-- Entry goes in Sisyph Menu
CDMenus.ImplementEntryCommand[
menu: $OtherProgramMenu,
entry: "Sisyph Extract and Layout",
p: ExtractAndLayout,
key: $CoreRosemaryExtractSelectedObjAndLayout];
CDMenus.ImplementEntryCommand[
menu: $OtherProgramMenu,
entry: "Sisyph Extract and Static",
p: ExtractAndStatic,
key: $CoreRosemaryExtractSelectedObjAndStatic];
END.