diff options
-rw-r--r-- | src/aig/gia/giaSwitch.c | 8 | ||||
-rw-r--r-- | src/base/wlc/wlcBlast.c | 6 |
2 files changed, 11 insertions, 3 deletions
diff --git a/src/aig/gia/giaSwitch.c b/src/aig/gia/giaSwitch.c index b1c5eb82..4722ef0f 100644 --- a/src/aig/gia/giaSwitch.c +++ b/src/aig/gia/giaSwitch.c @@ -795,6 +795,14 @@ float Gia_ManComputeSwitching( Gia_Man_t * p, int nFrames, int nPref, int fProbO Gia_ManForEachAnd( p, pObj, i ) SwiTotal += pSwi[Gia_ObjFaninId0(pObj, i)] + pSwi[Gia_ObjFaninId1(pObj, i)]; } + if ( 0 ) + { + Gia_ManForEachObj( p, pObj, i ) + { + printf( "Switch %6.2f ", pSwi[i] ); + Gia_ObjPrint( p, pObj ); + } + } Vec_IntFree( vSwitching ); return SwiTotal; } diff --git a/src/base/wlc/wlcBlast.c b/src/base/wlc/wlcBlast.c index 6e910cd8..c6edb3ab 100644 --- a/src/base/wlc/wlcBlast.c +++ b/src/base/wlc/wlcBlast.c @@ -1930,9 +1930,9 @@ Gia_Man_t * Wlc_NtkBitBlast( Wlc_Ntk_t * p, Wlc_BstPar_t * pParIn ) // create combinational outputs in the normal manager pFans0 = Wlc_ObjFaninNum(pObj) > 0 ? Vec_IntEntryP( vBits, Wlc_ObjCopy(p, Wlc_ObjFaninId0(pObj)) ) : NULL; - pFans1 = Wlc_ObjFaninNum(pObj) > 1 ? Vec_IntEntryP( vBits, Wlc_ObjCopy(p, Wlc_ObjFaninId1(pObj)) ) : NULL; - pFans2 = Wlc_ObjFaninNum(pObj) > 2 ? Vec_IntEntryP( vBits, Wlc_ObjCopy(p, Wlc_ObjFaninId2(pObj)) ) : NULL; - pFans3 = Wlc_ObjFaninNum(pObj) > 3 ? Vec_IntEntryP( vBits, Wlc_ObjCopy(p, Wlc_ObjFaninId(pObj,3)) ) : NULL; + pFans1 = Wlc_ObjFaninNum(pObj) > 2 ? Vec_IntEntryP( vBits, Wlc_ObjCopy(p, Wlc_ObjFaninId(pObj,2)) ) : NULL; // reset + pFans2 = Wlc_ObjFaninNum(pObj) > 3 ? Vec_IntEntryP( vBits, Wlc_ObjCopy(p, Wlc_ObjFaninId(pObj,3)) ) : NULL; // set + pFans3 = Wlc_ObjFaninNum(pObj) > 4 ? Vec_IntEntryP( vBits, Wlc_ObjCopy(p, Wlc_ObjFaninId(pObj,4)) ) : NULL; // enable for ( k = 0; k < nRange; k++ ) Gia_ManAppendCo( pNew, pFans0[k] ); Gia_ManAppendCo( pNew, pFans1[0] ); |