Corrected the "property parallel none" command option so that it

gets applied properly to all existing cells (as well as all
future cells, but normally the former is applicable in a setup
file for LVS).
This commit is contained in:
Tim Edwards 2017-06-19 22:22:08 -04:00
parent 70bb33cc62
commit 78779ce2e9
3 changed files with 33 additions and 2 deletions

View File

@ -871,6 +871,32 @@ int ReduceExpressions(struct objlist *instprop, struct objlist *parprops,
return 0;
}
/*----------------------------------------------------------------------*/
/* Set/clear the flag bit COMB_NO_PARALLEL on all cells. Note that the */
/* function is called with value for enabling combine parallel, so */
/* value TRUE means clear bit, value FALSE means set bit. */
/*----------------------------------------------------------------------*/
struct nlist *SetParallelCombineFlag(struct hashlist *p, void *clientdata)
{
struct nlist *ptr;
int *value = (int *)clientdata;
ptr = (struct nlist *)(p->ptr);
if (*value == TRUE)
ptr->flags &= (~COMB_NO_PARALLEL);
else
ptr->flags |= COMB_NO_PARALLEL;
return NULL; /* NULL keeps search alive */
}
void SetParallelCombine(int value)
{
ClearDumpedList();
RecurseCellHashTable2(SetParallelCombineFlag, (void *)(&value));
}
/*----------------------------------------------------------------------*/
/* Delete a property from the master cell record. */
/*----------------------------------------------------------------------*/

View File

@ -35,6 +35,7 @@ extern struct property *PropertyInteger(char *name, int fnum, char *key,
extern struct property *PropertyString(char *name, int fnum, char *key,
double slop, char *pdefault);
extern int PropertyDelete(char *name, int fnum, char *key);
extern void SetParallelCombine(int value);
extern int PropertyTolerance(char *name, int fnum, char *key, int ival,
double dval);
extern int PropertyMerge(char *name, int fnum, char *key, int merge_type);

View File

@ -3228,10 +3228,14 @@ _netcmp_property(ClientData clientData,
return TCL_OK;
}
else if ((objc == 3) && (!strcmp(Tcl_GetString(objv[1]), "parallel"))) {
if (!strcmp(Tcl_GetString(objv[2]), "none"))
if (!strcmp(Tcl_GetString(objv[2]), "none")) {
GlobalParallelNone = TRUE;
else if (!strcmp(Tcl_GetString(objv[2]), "all"))
SetParallelCombine(FALSE);
}
else if (!strcmp(Tcl_GetString(objv[2]), "all")) {
GlobalParallelNone = FALSE;
SetParallelCombine(TRUE);
}
else {
Tcl_SetResult(interp, "Bad option, should be property parallel none|all",
NONE);