Pop the CO bit from O

This commit is contained in:
Eddie Hung 2019-07-26 10:27:30 -07:00
parent c1a05f4557
commit 4c25d1a76f
1 changed files with 3 additions and 1 deletions

View File

@ -144,8 +144,10 @@ void create_ice40_dsp(ice40_dsp_pm &pm)
// SB_MAC16 Output Interface // SB_MAC16 Output Interface
SigSpec O = st.sigO; SigSpec O = st.sigO;
if (GetSize(O) == 33) if (GetSize(O) == 33) {
cell->setPort("\\CO", st.sigO[32]); cell->setPort("\\CO", st.sigO[32]);
O.remove(32);
}
else { else {
log_assert(GetSize(O) <= 32); log_assert(GetSize(O) <= 32);
cell->setPort("\\CO", pm.module->addWire(NEW_ID)); cell->setPort("\\CO", pm.module->addWire(NEW_ID));