CD.Design, rules: Rope.
RETURNS [msg: Rope.
{
topCellName, fileName: Rope.ROPE;
cifFile: IO.STREAM;
topCellName ← CDDirectory.Name[instance.ob, design];
IF topCellName=NIL THEN RETURN["Impossible to DRC non named objects"];
fileName ← Rope.Cat[topCellName, cifExt];
cifFile ←
FS.StreamOpen[fileName, create !
FS.Error =>
IF error.group#bug
THEN {
msg ← error.explanation;
CONTINUE;
}];
IF msg#NIL THEN GOTO Failed;
TerminalIO.PutRopes["Dracula DRC. CIF file: ", fileName, "\n"];
msg ← CDToCif.WriteCIF[design, instance, cifFile, cifPerLambda, flattenAtomics];
IF msg#NIL THEN GOTO Failed;
msg ← EcadOps.ExecuteRemoteECAD[topCellName, rules];
IF msg#NIL THEN GOTO Failed;
msg ← EcadOps.WaitForOk[topCellName];
IF msg#NIL THEN GOTO Failed;
fileName ← Rope.Cat[topCellName, errExt];
cifFile ←
FS.StreamOpen[fileName, read !
FS.Error =>
IF error.group#bug
THEN {
msg ← error.explanation;
CONTINUE;
}];
IF msg#NIL THEN GOTO Failed;
msg ← CifToCD.ReadFile[cifFile, design, ecadKey, instance.trans];
IF msg#NIL THEN GOTO Failed;
CedarProcess.SetPriority[priority];
CDOps.RedrawInstance[design, instance];
EXITS Failed => {
TerminalIO.PutRope[msg];
CedarProcess.SetPriority[priority];
};
};