Pop the CO bit from O
authorEddie Hung <eddie@fpgeh.com>
Fri, 26 Jul 2019 17:27:30 +0000 (10:27 -0700)
committerEddie Hung <eddie@fpgeh.com>
Fri, 26 Jul 2019 17:27:30 +0000 (10:27 -0700)
passes/pmgen/ice40_dsp.cc

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