Merge branch 'master' into netgen-1.5

This commit is contained in:
Tim Edwards 2024-12-28 02:00:02 -05:00
commit 3ca77300ac
4 changed files with 18 additions and 5 deletions

View File

@ -1 +1 @@
1.5.287
1.5.289

View File

@ -6567,11 +6567,16 @@ void PrintAutomorphisms(void)
* separating out those devices that are connected to matching pins
* in each circuit.
*
* If match_nets == TRUE, then also match internal nets by name. Pins
* should always be matched by name without considering nets first;
* once all symmetries related to pins have been broken, then matching
* symmetries by net can keep the output from looking confusing.
*
* Return value is the same as VerifyMatching()
*-------------------------------------------------------------------------
*/
int ResolveAutomorphsByPin()
int ResolveAutomorphsByPin(int match_nets)
{
struct NodeClass *NC;
struct Node *N;
@ -6604,7 +6609,9 @@ int ResolveAutomorphsByPin()
if (N1->hashval != orighash) continue;
for (N2 = N1->next; N2 != NULL; N2 = N2->next) {
if ((N2->graph != N1->graph) &&
(*matchfunc)(N2->object->name, N1->object->name)) {
(*matchfunc)(N2->object->name, N1->object->name) &&
(N1->object->type == PORT || N2->object->type == PORT)) {
if (Debug == TRUE)
Printf("Symmetry group broken by name match (pin %s)\n", N2->object->name);
Magic(newhash);

View File

@ -62,7 +62,7 @@ extern void RegroupDataStructures();
extern void FormatIllegalElementClasses();
extern void FormatIllegalNodeClasses();
extern int ResolveAutomorphsByProperty();
extern int ResolveAutomorphsByPin();
extern int ResolveAutomorphsByPin(int match_nets);
extern void SummarizeElementClasses(struct ElementClass *EC);
extern int remove_group_tags(struct objlist *ob);

View File

@ -2512,7 +2512,13 @@ _netcmp_run(ClientData clientData,
if (automorphisms > 0) {
// Next, attempt to resolve automorphisms uniquely by
// using the pin names
automorphisms = ResolveAutomorphsByPin();
automorphisms = ResolveAutomorphsByPin(FALSE);
}
if (automorphisms > 0) {
// Next, attempt to resolve automorphisms uniquely by
// using the net names (should only be done after
// resolving by pin).
automorphisms = ResolveAutomorphsByPin(TRUE);
}
if (automorphisms > 0) {
// Anything left is truly indistinguishable