Try and fix again

This commit is contained in:
Eddie Hung 2019-07-19 14:40:57 -07:00
parent c926eeb43a
commit 09beeee38a
1 changed files with 4 additions and 5 deletions

View File

@ -372,13 +372,12 @@ struct WreduceWorker
int i;
for (i = 0; i < GetSize(sig); i++) {
if (B.at(i, Sx) != S0 && (sub || A.at(i, Sx) != S0))
break;
if (B[i] == S0)
if (B.at(i, Sx) == S0 && A.at(i, Sx) != Sx)
module->connect(sig[i], A[i]);
else if (A[i] == S0)
else if (!sub && A.at(i, Sx) == S0 && B.at(i, Sx) != Sx)
module->connect(sig[i], B[i]);
else log_abort();
else
break;
}
if (i > 0) {
cell->setPort("\\A", A.extract(i, -1));