Corrected dereferencing of cell dependencies, which was being applied
only at the time of running the command "load". But cells are generally loaded only on an as-needed basis, so the dereferencing option must be saved as a flag in the cell and honored whenever its subcells are expanded or otherwise read at a later time.
This commit is contained in:
parent
67866c7991
commit
82e33248f2
|
|
@ -746,8 +746,11 @@ calmaProcessDef(def, outf)
|
||||||
|
|
||||||
/* Read the cell in if it is not already available. */
|
/* Read the cell in if it is not already available. */
|
||||||
if ((def->cd_flags & CDAVAILABLE) == 0)
|
if ((def->cd_flags & CDAVAILABLE) == 0)
|
||||||
if (!DBCellRead(def, (char *) NULL, TRUE, FALSE, NULL))
|
{
|
||||||
|
bool dereference = (def->cd_flags & CDDEREFERENCE) ? TRUE : FALSE;
|
||||||
|
if (!DBCellRead(def, (char *) NULL, TRUE, dereference, NULL))
|
||||||
return (0);
|
return (0);
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Output the definitions for any of our descendants that have
|
* Output the definitions for any of our descendants that have
|
||||||
|
|
|
||||||
|
|
@ -312,7 +312,8 @@ cifOut(outf)
|
||||||
/* Read the cell in if it is not already available. */
|
/* Read the cell in if it is not already available. */
|
||||||
if ((def->cd_flags & CDAVAILABLE) == 0)
|
if ((def->cd_flags & CDAVAILABLE) == 0)
|
||||||
{
|
{
|
||||||
if (!DBCellRead(def, (char *) NULL, TRUE, FALSE, NULL)) continue;
|
bool dereference = (def->cd_flags & CDDEREFERENCE) ? TRUE : FALSE;
|
||||||
|
if (!DBCellRead(def, (char *) NULL, TRUE, dereference, NULL)) continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Add any subcells to the stack. This must be done before
|
/* Add any subcells to the stack. This must be done before
|
||||||
|
|
|
||||||
|
|
@ -3650,7 +3650,7 @@ cmdDumpParseArgs(cmdName, w, cmd, dummy, scx)
|
||||||
{
|
{
|
||||||
Point childPoint, editPoint, rootPoint;
|
Point childPoint, editPoint, rootPoint;
|
||||||
CellDef *def, *rootDef, *editDef;
|
CellDef *def, *rootDef, *editDef;
|
||||||
bool hasChild, hasRoot, hasTrans;
|
bool hasChild, hasRoot, hasTrans, dereference;
|
||||||
Rect rootBox, bbox;
|
Rect rootBox, bbox;
|
||||||
Transform *tx_cell, trans_cell;
|
Transform *tx_cell, trans_cell;
|
||||||
char **av;
|
char **av;
|
||||||
|
|
@ -3750,7 +3750,8 @@ cmdDumpParseArgs(cmdName, w, cmd, dummy, scx)
|
||||||
* looked for then no new error message will be printed.
|
* looked for then no new error message will be printed.
|
||||||
*/
|
*/
|
||||||
def->cd_flags &= ~CDNOTFOUND;
|
def->cd_flags &= ~CDNOTFOUND;
|
||||||
if (!DBCellRead(def, (char *) NULL, TRUE, FALSE, NULL))
|
dereference = (def->cd_flags & CDDEREFERENCE) ? TRUE : FALSE;
|
||||||
|
if (!DBCellRead(def, (char *) NULL, TRUE, dereference, NULL))
|
||||||
return (FALSE);
|
return (FALSE);
|
||||||
DBReComputeBbox(def);
|
DBReComputeBbox(def);
|
||||||
dummy->cu_def = def;
|
dummy->cu_def = def;
|
||||||
|
|
|
||||||
|
|
@ -130,7 +130,11 @@ CmdEdit(w, cmd)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
else if (!(EditCellUse->cu_def->cd_flags & CDAVAILABLE))
|
else if (!(EditCellUse->cu_def->cd_flags & CDAVAILABLE))
|
||||||
DBCellRead(EditCellUse->cu_def, (char *)NULL, TRUE, FALSE, NULL);
|
{
|
||||||
|
bool dereference = (EditCellUse->cu_def->cd_flags & CDDEREFERENCE) ?
|
||||||
|
TRUE : FALSE;
|
||||||
|
DBCellRead(EditCellUse->cu_def, (char *)NULL, TRUE, dereference, NULL);
|
||||||
|
}
|
||||||
|
|
||||||
if (EditCellUse->cu_def->cd_flags & CDNOEDIT)
|
if (EditCellUse->cu_def->cd_flags & CDNOEDIT)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -288,6 +288,7 @@ cmdFlushCell(def)
|
||||||
CellDef *def;
|
CellDef *def;
|
||||||
{
|
{
|
||||||
CellUse *parentUse;
|
CellUse *parentUse;
|
||||||
|
bool dereference;
|
||||||
|
|
||||||
/* Disallow flushing a cell that contains the edit cell as a child */
|
/* Disallow flushing a cell that contains the edit cell as a child */
|
||||||
if (EditCellUse && (EditCellUse->cu_parent == def))
|
if (EditCellUse && (EditCellUse->cu_parent == def))
|
||||||
|
|
@ -309,7 +310,8 @@ cmdFlushCell(def)
|
||||||
}
|
}
|
||||||
DBCellClearDef(def);
|
DBCellClearDef(def);
|
||||||
DBCellClearAvail(def);
|
DBCellClearAvail(def);
|
||||||
(void) DBCellRead(def, (char *) NULL, TRUE, FALSE, NULL);
|
dereference = (def->cd_flags & CDDEREFERENCE) ? TRUE : FALSE;
|
||||||
|
(void) DBCellRead(def, (char *) NULL, TRUE, dereference, NULL);
|
||||||
DBCellSetAvail(def);
|
DBCellSetAvail(def);
|
||||||
DBReComputeBbox(def);
|
DBReComputeBbox(def);
|
||||||
DBCellSetModified(def, FALSE);
|
DBCellSetModified(def, FALSE);
|
||||||
|
|
|
||||||
|
|
@ -188,7 +188,10 @@ dbCellTileSrFunc(scx, fp)
|
||||||
if (!DBDescendSubcell(scx->scx_use, fp->tf_xmask))
|
if (!DBDescendSubcell(scx->scx_use, fp->tf_xmask))
|
||||||
return 0;
|
return 0;
|
||||||
if ((def->cd_flags & CDAVAILABLE) == 0)
|
if ((def->cd_flags & CDAVAILABLE) == 0)
|
||||||
if (!DBCellRead(def, (char *) NULL, TRUE, FALSE, NULL)) return 0;
|
{
|
||||||
|
bool dereference = (def->cd_flags & CDDEREFERENCE) ? TRUE : FALSE;
|
||||||
|
if (!DBCellRead(def, (char *) NULL, TRUE, dereference, NULL)) return 0;
|
||||||
|
}
|
||||||
|
|
||||||
context.tc_scx = scx;
|
context.tc_scx = scx;
|
||||||
context.tc_filter = fp;
|
context.tc_filter = fp;
|
||||||
|
|
@ -307,7 +310,10 @@ dbCellUniqueTileSrFunc(scx, fp)
|
||||||
if (!DBDescendSubcell(scx->scx_use, fp->tf_xmask))
|
if (!DBDescendSubcell(scx->scx_use, fp->tf_xmask))
|
||||||
return 0;
|
return 0;
|
||||||
if ((def->cd_flags & CDAVAILABLE) == 0)
|
if ((def->cd_flags & CDAVAILABLE) == 0)
|
||||||
if (!DBCellRead(def, (char *) NULL, TRUE, FALSE, NULL)) return 0;
|
{
|
||||||
|
bool dereference = (def->cd_flags & CDDEREFERENCE) ? TRUE : FALSE;
|
||||||
|
if (!DBCellRead(def, (char *) NULL, TRUE, dereference, NULL)) return 0;
|
||||||
|
}
|
||||||
|
|
||||||
context.tc_scx = scx;
|
context.tc_scx = scx;
|
||||||
context.tc_filter = fp;
|
context.tc_filter = fp;
|
||||||
|
|
@ -418,7 +424,10 @@ DBNoTreeSrTiles(scx, mask, xMask, func, cdarg)
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
if ((def->cd_flags & CDAVAILABLE) == 0)
|
if ((def->cd_flags & CDAVAILABLE) == 0)
|
||||||
if (!DBCellRead(def, (char *) NULL, TRUE, FALSE, NULL)) return 0;
|
{
|
||||||
|
bool dereference = (def->cd_flags & CDDEREFERENCE) ? TRUE : FALSE;
|
||||||
|
if (!DBCellRead(def, (char *) NULL, TRUE, dereference, NULL)) return 0;
|
||||||
|
}
|
||||||
|
|
||||||
filter.tf_func = func;
|
filter.tf_func = func;
|
||||||
filter.tf_arg = cdarg;
|
filter.tf_arg = cdarg;
|
||||||
|
|
@ -526,7 +535,10 @@ DBTreeSrLabels(scx, mask, xMask, tpath, flags, func, cdarg)
|
||||||
ASSERT(def != (CellDef *) NULL, "DBTreeSrLabels");
|
ASSERT(def != (CellDef *) NULL, "DBTreeSrLabels");
|
||||||
if (!DBDescendSubcell(cellUse, xMask)) return 0;
|
if (!DBDescendSubcell(cellUse, xMask)) return 0;
|
||||||
if ((def->cd_flags & CDAVAILABLE) == 0)
|
if ((def->cd_flags & CDAVAILABLE) == 0)
|
||||||
if (!DBCellRead(def, (char *) NULL, TRUE, FALSE, NULL)) return 0;
|
{
|
||||||
|
bool dereference = (def->cd_flags & CDDEREFERENCE) ? TRUE : FALSE;
|
||||||
|
if (!DBCellRead(def, (char *) NULL, TRUE, dereference, NULL)) return 0;
|
||||||
|
}
|
||||||
|
|
||||||
for (lab = def->cd_labels; lab; lab = lab->lab_next)
|
for (lab = def->cd_labels; lab; lab = lab->lab_next)
|
||||||
{
|
{
|
||||||
|
|
@ -627,7 +639,10 @@ dbCellLabelSrFunc(scx, fp)
|
||||||
ASSERT(def != (CellDef *) NULL, "dbCellLabelSrFunc");
|
ASSERT(def != (CellDef *) NULL, "dbCellLabelSrFunc");
|
||||||
if (!DBDescendSubcell(scx->scx_use, fp->tf_xmask)) return 0;
|
if (!DBDescendSubcell(scx->scx_use, fp->tf_xmask)) return 0;
|
||||||
if ((def->cd_flags & CDAVAILABLE) == 0)
|
if ((def->cd_flags & CDAVAILABLE) == 0)
|
||||||
if (!DBCellRead(def, (char *) NULL, TRUE, FALSE, NULL)) return 0;
|
{
|
||||||
|
bool dereference = (def->cd_flags & CDDEREFERENCE) ? TRUE : FALSE;
|
||||||
|
if (!DBCellRead(def, (char *) NULL, TRUE, dereference, NULL)) return 0;
|
||||||
|
}
|
||||||
|
|
||||||
if (fp->tf_tpath != (TerminalPath *) NULL)
|
if (fp->tf_tpath != (TerminalPath *) NULL)
|
||||||
{
|
{
|
||||||
|
|
@ -741,8 +756,11 @@ DBTreeSrCells(scx, xMask, func, cdarg)
|
||||||
if (!DBDescendSubcell(cellUse, xMask))
|
if (!DBDescendSubcell(cellUse, xMask))
|
||||||
return 0;
|
return 0;
|
||||||
if ((cellUse->cu_def->cd_flags & CDAVAILABLE) == 0)
|
if ((cellUse->cu_def->cd_flags & CDAVAILABLE) == 0)
|
||||||
if (!DBCellRead(cellUse->cu_def, (char *) NULL, TRUE, FALSE, NULL))
|
{
|
||||||
|
bool dereference = (cellUse->cu_def->cd_flags & CDDEREFERENCE) ? TRUE : FALSE;
|
||||||
|
if (!DBCellRead(cellUse->cu_def, (char *) NULL, TRUE, dereference, NULL))
|
||||||
return 0;
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
context.tc_scx = scx;
|
context.tc_scx = scx;
|
||||||
context.tc_filter = &filter;
|
context.tc_filter = &filter;
|
||||||
|
|
@ -787,8 +805,11 @@ dbTreeCellSrFunc(scx, fp)
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if ((use->cu_def->cd_flags & CDAVAILABLE) == 0)
|
if ((use->cu_def->cd_flags & CDAVAILABLE) == 0)
|
||||||
if (!DBCellRead(use->cu_def, (char *) NULL, TRUE, FALSE, NULL))
|
{
|
||||||
|
bool dereference = (use->cu_def->cd_flags & CDDEREFERENCE) ? TRUE : FALSE;
|
||||||
|
if (!DBCellRead(use->cu_def, (char *) NULL, TRUE, dereference, NULL))
|
||||||
return 0;
|
return 0;
|
||||||
|
}
|
||||||
result = DBCellSrArea(scx, dbTreeCellSrFunc, (ClientData) fp);
|
result = DBCellSrArea(scx, dbTreeCellSrFunc, (ClientData) fp);
|
||||||
}
|
}
|
||||||
return result;
|
return result;
|
||||||
|
|
@ -1039,8 +1060,12 @@ DBCellSrArea(scx, func, cdarg)
|
||||||
context.tc_scx = scx;
|
context.tc_scx = scx;
|
||||||
|
|
||||||
if ((scx->scx_use->cu_def->cd_flags & CDAVAILABLE) == 0)
|
if ((scx->scx_use->cu_def->cd_flags & CDAVAILABLE) == 0)
|
||||||
if (!DBCellRead(scx->scx_use->cu_def, (char *) NULL, TRUE, FALSE, NULL))
|
{
|
||||||
|
bool dereference = (scx->scx_use->cu_def->cd_flags & CDDEREFERENCE) ?
|
||||||
|
TRUE : FALSE;
|
||||||
|
if (!DBCellRead(scx->scx_use->cu_def, (char *) NULL, TRUE, dereference, NULL))
|
||||||
return 0;
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
/* In order to make this work with zero-size areas, we first expand
|
/* In order to make this work with zero-size areas, we first expand
|
||||||
* the area by before searching the tile plane. DbCellSrFunc will
|
* the area by before searching the tile plane. DbCellSrFunc will
|
||||||
|
|
@ -1215,7 +1240,10 @@ DBCellEnum(cellDef, func, cdarg)
|
||||||
filter.tf_func = func;
|
filter.tf_func = func;
|
||||||
filter.tf_arg = cdarg;
|
filter.tf_arg = cdarg;
|
||||||
if ((cellDef->cd_flags & CDAVAILABLE) == 0)
|
if ((cellDef->cd_flags & CDAVAILABLE) == 0)
|
||||||
if (!DBCellRead(cellDef, (char *) NULL, TRUE, FALSE, NULL)) return 0;
|
{
|
||||||
|
bool dereference = (cellDef->cd_flags & CDDEREFERENCE) ? TRUE : FALSE;
|
||||||
|
if (!DBCellRead(cellDef, (char *) NULL, TRUE, dereference, NULL)) return 0;
|
||||||
|
}
|
||||||
if (TiSrArea((Tile *) NULL, cellDef->cd_planes[PL_CELL],
|
if (TiSrArea((Tile *) NULL, cellDef->cd_planes[PL_CELL],
|
||||||
&TiPlaneRect, dbEnumFunc, (ClientData) &filter))
|
&TiPlaneRect, dbEnumFunc, (ClientData) &filter))
|
||||||
return 1;
|
return 1;
|
||||||
|
|
|
||||||
|
|
@ -73,8 +73,12 @@ DBDescendSubcell(use, xMask)
|
||||||
|
|
||||||
case CU_DESCEND_NO_SUBCKT:
|
case CU_DESCEND_NO_SUBCKT:
|
||||||
if ((use->cu_def->cd_flags & CDAVAILABLE) == 0)
|
if ((use->cu_def->cd_flags & CDAVAILABLE) == 0)
|
||||||
if (!DBCellRead(use->cu_def, (char *) NULL, TRUE, FALSE, NULL))
|
{
|
||||||
|
bool dereference = (use->cu_def->cd_flags & CDDEREFERENCE) ?
|
||||||
|
TRUE : FALSE;
|
||||||
|
if (!DBCellRead(use->cu_def, (char *) NULL, TRUE, dereference, NULL))
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
}
|
||||||
return (DBIsSubcircuit(use->cu_def)) ? FALSE : TRUE;
|
return (DBIsSubcircuit(use->cu_def)) ? FALSE : TRUE;
|
||||||
|
|
||||||
case CU_DESCEND_NO_LOCK:
|
case CU_DESCEND_NO_LOCK:
|
||||||
|
|
|
||||||
|
|
@ -37,6 +37,7 @@ static char rcsid[] __attribute__ ((unused)) = "$Header: /usr/cvsroot/magic-8.0/
|
||||||
*/
|
*/
|
||||||
struct expandArg
|
struct expandArg
|
||||||
{
|
{
|
||||||
|
bool ea_deref; /* TRUE if root def dereference flag is set */
|
||||||
int ea_xmask; /* Expand mask. */
|
int ea_xmask; /* Expand mask. */
|
||||||
int (*ea_func)(); /* Function to call for each cell whose
|
int (*ea_func)(); /* Function to call for each cell whose
|
||||||
* status is changed.
|
* status is changed.
|
||||||
|
|
@ -81,7 +82,8 @@ DBExpand(cellUse, expandMask, expandFlag)
|
||||||
def = cellUse->cu_def;
|
def = cellUse->cu_def;
|
||||||
if ((def->cd_flags & CDAVAILABLE) == 0)
|
if ((def->cd_flags & CDAVAILABLE) == 0)
|
||||||
{
|
{
|
||||||
if (!DBCellRead(def, (char *) NULL, TRUE, FALSE, NULL))
|
bool dereference = (def->cd_flags & CDDEREFERENCE) ? TRUE : FALSE;
|
||||||
|
if (!DBCellRead(def, (char *) NULL, TRUE, dereference, NULL))
|
||||||
return;
|
return;
|
||||||
/* Note: we don't have to recompute the bbox here, because
|
/* Note: we don't have to recompute the bbox here, because
|
||||||
* if it changed, then a timestamp violation must have occurred
|
* if it changed, then a timestamp violation must have occurred
|
||||||
|
|
@ -142,9 +144,13 @@ DBExpandAll(rootUse, rootRect, expandMask, expandFlag, func, cdarg)
|
||||||
int dbExpandFunc(), dbUnexpandFunc();
|
int dbExpandFunc(), dbUnexpandFunc();
|
||||||
SearchContext scontext;
|
SearchContext scontext;
|
||||||
struct expandArg arg;
|
struct expandArg arg;
|
||||||
|
bool dereference = (rootUse->cu_def->cd_flags & CDDEREFERENCE) ?
|
||||||
|
TRUE : FALSE;
|
||||||
|
|
||||||
if ((rootUse->cu_def->cd_flags & CDAVAILABLE) == 0)
|
if ((rootUse->cu_def->cd_flags & CDAVAILABLE) == 0)
|
||||||
(void) DBCellRead(rootUse->cu_def, (char *) NULL, TRUE, FALSE, NULL);
|
{
|
||||||
|
(void) DBCellRead(rootUse->cu_def, (char *) NULL, TRUE, dereference, NULL);
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Walk through the area and set the expansion state
|
* Walk through the area and set the expansion state
|
||||||
|
|
@ -154,6 +160,7 @@ DBExpandAll(rootUse, rootRect, expandMask, expandFlag, func, cdarg)
|
||||||
arg.ea_xmask = expandMask;
|
arg.ea_xmask = expandMask;
|
||||||
arg.ea_func = func;
|
arg.ea_func = func;
|
||||||
arg.ea_arg = cdarg;
|
arg.ea_arg = cdarg;
|
||||||
|
arg.ea_deref = dereference;
|
||||||
|
|
||||||
scontext.scx_use = rootUse;
|
scontext.scx_use = rootUse;
|
||||||
scontext.scx_trans = GeoIdentityTransform;
|
scontext.scx_trans = GeoIdentityTransform;
|
||||||
|
|
@ -193,7 +200,7 @@ dbExpandFunc(scx, arg)
|
||||||
/* If the cell is unavailable, then don't expand it.
|
/* If the cell is unavailable, then don't expand it.
|
||||||
*/
|
*/
|
||||||
if ((childUse->cu_def->cd_flags & CDAVAILABLE) == 0)
|
if ((childUse->cu_def->cd_flags & CDAVAILABLE) == 0)
|
||||||
if(!DBCellRead(childUse->cu_def, (char *) NULL, TRUE, FALSE, NULL))
|
if(!DBCellRead(childUse->cu_def, (char *) NULL, TRUE, arg->ea_deref, NULL))
|
||||||
{
|
{
|
||||||
TxError("Cell %s is unavailable. It could not be expanded.\n",
|
TxError("Cell %s is unavailable. It could not be expanded.\n",
|
||||||
childUse->cu_def->cd_name);
|
childUse->cu_def->cd_name);
|
||||||
|
|
@ -303,7 +310,8 @@ dbReadAreaFunc(scx)
|
||||||
|
|
||||||
if ((def->cd_flags & CDAVAILABLE) == 0)
|
if ((def->cd_flags & CDAVAILABLE) == 0)
|
||||||
{
|
{
|
||||||
(void) DBCellRead(def, (char *) NULL, TRUE, FALSE, NULL);
|
bool dereference = (def->cd_flags & CDDEREFERENCE) ? TRUE : FALSE;
|
||||||
|
(void) DBCellRead(def, (char *) NULL, TRUE, dereference, NULL);
|
||||||
/* Note: we don't have to invoke DBReComputeBbox here because
|
/* Note: we don't have to invoke DBReComputeBbox here because
|
||||||
* if the bbox changed then there was a timestamp mismatch and
|
* if the bbox changed then there was a timestamp mismatch and
|
||||||
* the timestamp code will take care of the bounding box later.
|
* the timestamp code will take care of the bounding box later.
|
||||||
|
|
|
||||||
|
|
@ -934,7 +934,7 @@ DBCellRead(cellDef, name, ignoreTech, dereference, errptr)
|
||||||
* names do not match, but an attempt will be
|
* names do not match, but an attempt will be
|
||||||
* made to read the file anyway.
|
* made to read the file anyway.
|
||||||
*/
|
*/
|
||||||
bool dereference; /* If TRUE, ignore path references in the input */
|
bool dereference; /* If TRUE then ignore path argument to uses */
|
||||||
int *errptr; /* Copy of errno set by file reading routine
|
int *errptr; /* Copy of errno set by file reading routine
|
||||||
* is placed here, unless NULL.
|
* is placed here, unless NULL.
|
||||||
*/
|
*/
|
||||||
|
|
@ -2855,8 +2855,11 @@ DBCellWrite(cellDef, fileName)
|
||||||
|
|
||||||
#ifdef FILE_LOCKS
|
#ifdef FILE_LOCKS
|
||||||
else
|
else
|
||||||
|
{
|
||||||
|
bool dereference = (cellDef->cd_flags & CDDEREFERENCE) ? TRUE : FALSE;
|
||||||
/* Re-aquire the lock on the new file by opening it. */
|
/* Re-aquire the lock on the new file by opening it. */
|
||||||
DBCellRead(cellDef, NULL, TRUE, FALSE, NULL);
|
DBCellRead(cellDef, NULL, TRUE, dereference, NULL);
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -294,7 +294,10 @@ DBTreeFindUse(name, use, scx)
|
||||||
* is read in from disk.
|
* is read in from disk.
|
||||||
*/
|
*/
|
||||||
if ((def->cd_flags & CDAVAILABLE) == 0)
|
if ((def->cd_flags & CDAVAILABLE) == 0)
|
||||||
(void) DBCellRead(def, (char *) NULL, TRUE, FALSE, NULL);
|
{
|
||||||
|
bool dereference = (def->cd_flags & CDDEREFERENCE) ? TRUE : FALSE;
|
||||||
|
(void) DBCellRead(def, (char *) NULL, TRUE, dereference, NULL);
|
||||||
|
}
|
||||||
|
|
||||||
cp = name;
|
cp = name;
|
||||||
he = HashLookOnly(&def->cd_idHash, name);
|
he = HashLookOnly(&def->cd_idHash, name);
|
||||||
|
|
@ -343,7 +346,10 @@ DBTreeFindUse(name, use, scx)
|
||||||
/* Ensure that the leaf cell is read in */
|
/* Ensure that the leaf cell is read in */
|
||||||
def = use->cu_def;
|
def = use->cu_def;
|
||||||
if ((def->cd_flags & CDAVAILABLE) == 0)
|
if ((def->cd_flags & CDAVAILABLE) == 0)
|
||||||
(void) DBCellRead(def, (char *) NULL, TRUE, FALSE, NULL);
|
{
|
||||||
|
bool dereference = (def->cd_flags & CDDEREFERENCE) ? TRUE : FALSE;
|
||||||
|
(void) DBCellRead(def, (char *) NULL, dereference, NULL);
|
||||||
|
}
|
||||||
|
|
||||||
scx->scx_use = use;
|
scx->scx_use = use;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -126,6 +126,8 @@ DBFixMismatch()
|
||||||
|
|
||||||
while (mismatch != NULL)
|
while (mismatch != NULL)
|
||||||
{
|
{
|
||||||
|
bool dereference;
|
||||||
|
|
||||||
/* Be careful to remove the front element from the mismatch
|
/* Be careful to remove the front element from the mismatch
|
||||||
* list before processing it, because while processing it we
|
* list before processing it, because while processing it we
|
||||||
* may add new elements to the list.
|
* may add new elements to the list.
|
||||||
|
|
@ -137,7 +139,8 @@ DBFixMismatch()
|
||||||
mismatch = mismatch->mm_next;
|
mismatch = mismatch->mm_next;
|
||||||
if (cellDef->cd_flags & CDPROCESSED) continue;
|
if (cellDef->cd_flags & CDPROCESSED) continue;
|
||||||
|
|
||||||
(void) DBCellRead(cellDef, (char *) NULL, TRUE, FALSE, NULL);
|
dereference = (cellDef->cd_flags & CDDEREFERENCE) ? TRUE : FALSE;
|
||||||
|
(void) DBCellRead(cellDef, (char *) NULL, TRUE, dereference, NULL);
|
||||||
|
|
||||||
/* Jimmy up the cell's current bounding box, so the following
|
/* Jimmy up the cell's current bounding box, so the following
|
||||||
* procedure call will absolutely and positively know that
|
* procedure call will absolutely and positively know that
|
||||||
|
|
|
||||||
|
|
@ -385,6 +385,8 @@ DBWloadWindow(window, name, ignoreTech, expand, dereference)
|
||||||
if (newEditDef == (CellDef *) NULL)
|
if (newEditDef == (CellDef *) NULL)
|
||||||
newEditDef = DBCellNewDef(rootname, (char *) NULL);
|
newEditDef = DBCellNewDef(rootname, (char *) NULL);
|
||||||
|
|
||||||
|
if (dereference) newEditDef->cd_flags |= CDDEREFERENCE;
|
||||||
|
|
||||||
if (!DBCellRead(newEditDef, name, ignoreTech, dereference, &error_val))
|
if (!DBCellRead(newEditDef, name, ignoreTech, dereference, &error_val))
|
||||||
{
|
{
|
||||||
if (error_val == ENOENT)
|
if (error_val == ENOENT)
|
||||||
|
|
|
||||||
|
|
@ -894,13 +894,15 @@ drcFindFunc(scx, finddata)
|
||||||
CellDef *def;
|
CellDef *def;
|
||||||
HashEntry *h;
|
HashEntry *h;
|
||||||
int drcFindFunc2();
|
int drcFindFunc2();
|
||||||
|
bool dereference;
|
||||||
|
|
||||||
def = scx->scx_use->cu_def;
|
def = scx->scx_use->cu_def;
|
||||||
h = HashFind(finddata->deft, (char *)def);
|
h = HashFind(finddata->deft, (char *)def);
|
||||||
if (HashGetValue(h) != 0) return 0;
|
if (HashGetValue(h) != 0) return 0;
|
||||||
HashSetValue(h, 1);
|
HashSetValue(h, 1);
|
||||||
|
|
||||||
(void) DBCellRead(def, (char *) NULL, TRUE, FALSE, NULL);
|
dereference = (def->cd_flags & CDDEREFERENCE) ? TRUE : FALSE;
|
||||||
|
(void) DBCellRead(def, (char *) NULL, TRUE, dereference, NULL);
|
||||||
|
|
||||||
if (DBSrPaintArea((Tile *) NULL, def->cd_planes[PL_DRC_ERROR],
|
if (DBSrPaintArea((Tile *) NULL, def->cd_planes[PL_DRC_ERROR],
|
||||||
&def->cd_bbox, &DBAllButSpaceBits, drcFindFunc2,
|
&def->cd_bbox, &DBAllButSpaceBits, drcFindFunc2,
|
||||||
|
|
|
||||||
|
|
@ -424,7 +424,10 @@ extTreeSrPaintArea(scx, func, cdarg)
|
||||||
int pNum;
|
int pNum;
|
||||||
|
|
||||||
if ((def->cd_flags & CDAVAILABLE) == 0)
|
if ((def->cd_flags & CDAVAILABLE) == 0)
|
||||||
if (!DBCellRead(def, (char *) NULL, TRUE, FALSE, NULL)) return 0;
|
{
|
||||||
|
bool dereference = (def->cd_flags & CDDEREFERENCE) ? TRUE : FALSE;
|
||||||
|
if (!DBCellRead(def, (char *) NULL, TRUE, dereference, NULL)) return 0;
|
||||||
|
}
|
||||||
|
|
||||||
filter.tf_func = func;
|
filter.tf_func = func;
|
||||||
filter.tf_arg = cdarg;
|
filter.tf_arg = cdarg;
|
||||||
|
|
@ -461,7 +464,10 @@ extTreeSrFunc(scx, fp)
|
||||||
int pNum;
|
int pNum;
|
||||||
|
|
||||||
if ((def->cd_flags & CDAVAILABLE) == 0)
|
if ((def->cd_flags & CDAVAILABLE) == 0)
|
||||||
if (!DBCellRead(def, (char *) NULL, TRUE, FALSE, NULL)) return (0);
|
{
|
||||||
|
bool dereference = (def->cd_flags & CDDEREFERENCE) ? TRUE : FALSE;
|
||||||
|
if (!DBCellRead(def, (char *) NULL, TRUE, dereference, NULL)) return (0);
|
||||||
|
}
|
||||||
|
|
||||||
context.tc_scx = scx;
|
context.tc_scx = scx;
|
||||||
context.tc_filter = fp;
|
context.tc_filter = fp;
|
||||||
|
|
@ -548,8 +554,12 @@ extCellSrArea(scx, func, cdarg)
|
||||||
filter.tf_arg = cdarg;
|
filter.tf_arg = cdarg;
|
||||||
|
|
||||||
if ((scx->scx_use->cu_def->cd_flags & CDAVAILABLE) == 0)
|
if ((scx->scx_use->cu_def->cd_flags & CDAVAILABLE) == 0)
|
||||||
if (!DBCellRead(scx->scx_use->cu_def, (char *) NULL, TRUE, FALSE, NULL))
|
{
|
||||||
|
bool dereference = (scx->scx_use->cu_def->cd_flags & CDDEREFERENCE) ?
|
||||||
|
TRUE : FALSE;
|
||||||
|
if (!DBCellRead(scx->scx_use->cu_def, (char *) NULL, TRUE, dereference, NULL))
|
||||||
return 0;
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* In order to make this work with zero-size areas, we first expand
|
* In order to make this work with zero-size areas, we first expand
|
||||||
|
|
|
||||||
|
|
@ -1389,12 +1389,14 @@ W3DloadWindow(window, name)
|
||||||
CellDef *newEditDef;
|
CellDef *newEditDef;
|
||||||
CellUse *newEditUse;
|
CellUse *newEditUse;
|
||||||
Rect loadBox;
|
Rect loadBox;
|
||||||
|
bool dereference;
|
||||||
|
|
||||||
newEditDef = DBCellLookDef(name);
|
newEditDef = DBCellLookDef(name);
|
||||||
if (newEditDef == (CellDef *)NULL)
|
if (newEditDef == (CellDef *)NULL)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
if (!DBCellRead(newEditDef, (char *)NULL, TRUE, FALSE, NULL))
|
dereference = (newEditDef->cd_flags & CDDEREFERENCE) ? TRUE : FALSE;
|
||||||
|
if (!DBCellRead(newEditDef, (char *)NULL, TRUE, dereference, NULL))
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
DBReComputeBbox(newEditDef);
|
DBReComputeBbox(newEditDef);
|
||||||
|
|
|
||||||
|
|
@ -1487,11 +1487,14 @@ DefReadComponents(f, rootDef, sname, oscale, total)
|
||||||
|
|
||||||
if (defMacro == (CellDef *)NULL)
|
if (defMacro == (CellDef *)NULL)
|
||||||
{
|
{
|
||||||
|
bool dereference;
|
||||||
|
|
||||||
/* Before giving up, assume that this cell has a */
|
/* Before giving up, assume that this cell has a */
|
||||||
/* magic .mag layout file. */
|
/* magic .mag layout file. */
|
||||||
defMacro = DBCellNewDef(token, (char *)NULL);
|
defMacro = DBCellNewDef(token, (char *)NULL);
|
||||||
defMacro->cd_flags &= ~CDNOTFOUND;
|
defMacro->cd_flags &= ~CDNOTFOUND;
|
||||||
if (!DBCellRead(defMacro, (char *)NULL, TRUE, FALSE, NULL))
|
dereference = (defMacro->cd_flags & CDDEREFERENCE) ? TRUE : FALSE;
|
||||||
|
if (!DBCellRead(defMacro, (char *)NULL, TRUE, dereference, NULL))
|
||||||
{
|
{
|
||||||
LefError(DEF_ERROR, "Cell %s is not defined. Maybe you "
|
LefError(DEF_ERROR, "Cell %s is not defined. Maybe you "
|
||||||
"have not read the corresponding LEF file?\n",
|
"have not read the corresponding LEF file?\n",
|
||||||
|
|
|
||||||
|
|
@ -789,7 +789,10 @@ SimCellTileSrFunc(scx, fp)
|
||||||
if (!DBDescendSubcell(scx->scx_use, fp->tf_xmask))
|
if (!DBDescendSubcell(scx->scx_use, fp->tf_xmask))
|
||||||
return 0;
|
return 0;
|
||||||
if ((def->cd_flags & CDAVAILABLE) == 0)
|
if ((def->cd_flags & CDAVAILABLE) == 0)
|
||||||
if (!DBCellRead(def, (char *) NULL, TRUE, FALSE, NULL)) return 0;
|
{
|
||||||
|
bool dereference = (def->cd_flags & CDDEREFERENCE) ? TRUE : FALSE;
|
||||||
|
if (!DBCellRead(def, (char *) NULL, TRUE, dereference, NULL)) return 0;
|
||||||
|
}
|
||||||
|
|
||||||
context.tc_scx = scx;
|
context.tc_scx = scx;
|
||||||
context.tc_filter = fp;
|
context.tc_filter = fp;
|
||||||
|
|
|
||||||
|
|
@ -2,9 +2,7 @@ args.o: args.c ../utils/magic.h ../utils/utils.h
|
||||||
child.o: child.c ../utils/utils.h ../utils/magic.h ../utils/malloc.h
|
child.o: child.c ../utils/utils.h ../utils/magic.h ../utils/malloc.h
|
||||||
dqueue.o: dqueue.c ../utils/magic.h ../utils/dqueue.h ../utils/malloc.h
|
dqueue.o: dqueue.c ../utils/magic.h ../utils/dqueue.h ../utils/malloc.h
|
||||||
finddisp.o: finddisp.c ../utils/magic.h ../utils/utils.h
|
finddisp.o: finddisp.c ../utils/magic.h ../utils/utils.h
|
||||||
flock.o: flock.c ../utils/magic.h ../utils/hash.h ../utils/geometry.h \
|
flock.o: flock.c
|
||||||
../tiles/tile.h ../database/database.h ../windows/windows.h \
|
|
||||||
../utils/malloc.h
|
|
||||||
flsbuf.o: flsbuf.c
|
flsbuf.o: flsbuf.c
|
||||||
fraction.o: fraction.c ../utils/magic.h ../utils/geometry.h
|
fraction.o: fraction.c ../utils/magic.h ../utils/geometry.h
|
||||||
geometry.o: geometry.c ../utils/magic.h ../utils/geometry.h \
|
geometry.o: geometry.c ../utils/magic.h ../utils/geometry.h \
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue