3
0
Fork 0
mirror of https://github.com/YosysHQ/yosys synced 2025-06-13 01:16:16 +00:00

Consistency

This commit is contained in:
Eddie Hung 2020-01-17 16:06:20 -08:00
parent ee500b6d8e
commit e17f3f8c63
2 changed files with 6 additions and 4 deletions

View file

@ -56,10 +56,12 @@ code sigA sigB sigH
break; break;
sigH.append(O[i]); sigH.append(O[i]);
} }
log_assert(nusers(O.extract_end(i)) <= 1); // This sigM could have no users if downstream sinks (e.g. $add) is
// narrower than $mul result, for example
if (sigH.empty()) if (i == 0)
reject; reject;
log_assert(nusers(O.extract_end(i)) <= 1);
endcode endcode
code argQ ffA ffAholdmux ffArstmux ffAholdpol ffArstpol sigA clock clock_pol code argQ ffA ffAholdmux ffArstmux ffAholdpol ffArstpol sigA clock clock_pol

View file

@ -460,7 +460,7 @@ arg argD argQ clock
code code
dff = nullptr; dff = nullptr;
if (GetSize(argQ) == 0) if (argQ.empty() == 0)
reject; reject;
for (const auto &c : argQ.chunks()) { for (const auto &c : argQ.chunks()) {
// Abandon matches when 'Q' is a constant // Abandon matches when 'Q' is a constant