Modified the behavior of "extract" so that it does not try to check

for sticky labels making connections through the hierarchy.  This
is only needed for some annoying layouts that put point-size labels
with no connecting geometry in cells, and causes magic to spent
excessive amounts of time searching through labels for any layout
that has lots of labels.
This commit is contained in:
Tim Edwards 2021-04-26 12:19:33 -04:00
parent 0dcc9c6ca7
commit 538d7201e1
4 changed files with 8 additions and 25 deletions

View File

@ -1 +1 @@
8.3.158
8.3.159

View File

@ -880,6 +880,7 @@ cmdExpandFunc(use, windowMask)
#define DOLENGTH 4
#define DOLOCAL 5
#define DORESISTANCE 6
#define DOLABELCHECK 7
#define LENCLEAR 0
#define LENDRIVER 1
@ -922,6 +923,7 @@ CmdExtract(w, cmd)
"length compute driver-receiver pathlengths",
"local put all generated files in the current directory",
"resistance estimate resistance",
"labelcheck check for connections through sticky labels",
NULL
};
static char *cmdExtLength[] =
@ -1141,6 +1143,7 @@ CmdExtract(w, cmd)
TxPrintf("%s length\n", OPTSET(EXT_DOLENGTH));
TxPrintf("%s local\n", OPTSET(EXT_DOLOCAL));
TxPrintf("%s resistance\n", OPTSET(EXT_DORESISTANCE));
TxPrintf("%s label check\n", OPTSET(EXT_DOLABELCHECK));
return;
#undef OPTSET
}
@ -1169,6 +1172,7 @@ CmdExtract(w, cmd)
case DOLENGTH: option = EXT_DOLENGTH; break;
case DOLOCAL: option = EXT_DOLOCAL; break;
case DORESISTANCE: option = EXT_DORESISTANCE; break;
case DOLABELCHECK: option = EXT_DOLABELCHECK; break;
}
if (no) ExtOptions &= ~option;
else ExtOptions |= option;

View File

@ -346,6 +346,8 @@ extHierConnectFunc1(oneTile, ha)
/* This allows the extractor to catch "sticky" labels that are not */
/* attached to a physical layer in the parent cell. */
if (!(ExtOptions & EXT_DOLABELCHECK)) return 0;
// NOTE by Tim, 9/10/2014: This generates phantom nodes when the
// labels are created by the "hard" node search; I think this code
// should be restricted to sticky labels only. But not certain.
@ -393,31 +395,7 @@ extHierConnectFunc1(oneTile, ha)
node1->node_names = node2->node_names;
freeMagic((char *) node2);
}
#if 0
/* Copy this label to the parent def with a */
/* special flag, so we can output it as a node */
/* and then delete it. Don't duplicate labels */
/* that are already in the parent. */
for (newlab = ha->ha_parentUse->cu_def->cd_labels;
newlab; newlab = newlab->lab_next)
if (!strcmp(newlab->lab_text, lab->lab_text))
break;
if (newlab == NULL)
{
n = sizeof(Label) + strlen(lab->lab_text)
- sizeof lab->lab_text + 1;
newlab = (Label *)mallocMagic((unsigned)n);
bcopy((char *)lab, (char *)newlab, (int)n);
newlab->lab_next = ha->ha_parentUse->cu_def->cd_labels;
ha->ha_parentUse->cu_def->cd_labels = newlab;
}
#endif
}
}
return (0);
}

View File

@ -67,6 +67,7 @@ extern char *extDevTable[];
#define EXT_DOLENGTH 0x10 /* Extract pathlengths */
#define EXT_DOALL 0x1f /* ALL OF THE ABOVE */
#define EXT_DOLOCAL 0x20 /* Write to local directory only */
#define EXT_DOLABELCHECK 0x40 /* Check for connections by label */
extern int ExtOptions; /* Bitmask of above */