Corrected an error placing proxy pins after the first pin of the

first object if the (presumably top-level) cell has no pins
(top-level cells not in a subcircuit definition satisfy this
condition).
This commit is contained in:
Tim Edwards 2017-05-05 21:08:09 -04:00
parent 5e9635e05f
commit ace1c28507
2 changed files with 13 additions and 8 deletions

View File

@ -5078,7 +5078,6 @@ PropertyMatch(struct objlist *ob1, struct objlist *ob2, int do_print,
// t1 has no properties. See if t2's properties are required
// to be checked. If so, flag t2 instance as unmatched
mismatches++;
for (i = 0;; i++) {
vl2 = &(tp2->instance.props[i]);
if (vl2->type == PROP_ENDLIST) break;
@ -5088,6 +5087,7 @@ PropertyMatch(struct objlist *ob1, struct objlist *ob2, int do_print,
if (kl2 != NULL) break; // Property is required
}
if (vl2->type != PROP_ENDLIST) {
mismatches++;
if (do_print) Fprintf(stdout, "Circuit 2 %s instance %s has no"
" property match in circuit 1.\n",
Circuit2->name, inst2);
@ -6597,8 +6597,14 @@ int MatchPins(struct nlist *tc1, struct nlist *tc2, int dolist)
obn->model.port = -1;
obn->instance.name = NULL;
obn->node = -1;
obn->next = ob1->next;
ob1->next = obn;
if (ob1 == tc1->cell) {
obn->next = ob1;
tc1->cell = obn;
}
else {
obn->next = ob1->next;
ob1->next = obn;
}
ob1 = obn;
hasproxy1 = 1;

View File

@ -3387,11 +3387,10 @@ int CombineSerial(char *model, int file)
/* a parameter '_tag', string value set to "+". */
for (obn = instlist[i][1]; obn->next &&
obn->next->type != PROPERTY &&
obn->next->type != FIRSTPIN; obn = obn->next);
obn->next->type > FIRSTPIN; obn = obn->next);
obp = obn->next;
if (obp == NULL || obp->type == FIRSTPIN) {
if (obp == NULL || obp->type != PROPERTY) {
struct objlist *nob;
/* No property record, so insert one */
nob = GetObject();
@ -3466,8 +3465,8 @@ int CombineSerial(char *model, int file)
for (obp = instlist[i][0]; obp->next->type > FIRSTPIN ||
obp->next->type == PROPERTY; obp = obp->next);
for (ob2 = obp; ob2->next != instlist[i][1]; ob2 = ob2->next);
for (obs = ob2->next; obs->next && obs->next->type != FIRSTPIN;
obs = obs->next);
for (obs = ob2->next; obs->next && (obs->next->type > FIRSTPIN
|| obs->next->type == PROPERTY); obs = obs->next);
ob2->next = obs->next;
if (obs->next) obs->next = NULL; // Terminate 2nd instance record