diff options
author | Alan Mishchenko <alanmi@berkeley.edu> | 2014-02-28 10:35:36 -0800 |
---|---|---|
committer | Alan Mishchenko <alanmi@berkeley.edu> | 2014-02-28 10:35:36 -0800 |
commit | de48fd79992a5218c18da8dca62869b865a62f0e (patch) | |
tree | 90961ce052afc4b83b7b331ed4c45c883b05e3e2 /src/map/if/ifMap.c | |
parent | b556c2591e8dc6e35d523971aa467bce4ad6200e (diff) | |
download | abc-de48fd79992a5218c18da8dca62869b865a62f0e.tar.gz abc-de48fd79992a5218c18da8dca62869b865a62f0e.tar.bz2 abc-de48fd79992a5218c18da8dca62869b865a62f0e.zip |
Changes to LUT mappers.
Diffstat (limited to 'src/map/if/ifMap.c')
-rw-r--r-- | src/map/if/ifMap.c | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/src/map/if/ifMap.c b/src/map/if/ifMap.c index c719215f..d7b7f4cc 100644 --- a/src/map/if/ifMap.c +++ b/src/map/if/ifMap.c @@ -279,6 +279,39 @@ void If_ObjPerformMappingAnd( If_Man_t * p, If_Obj_t * pObj, int Mode, int fPrep int Value = If_DsdManCheckDec( p->pIfDsdMan, pCut->iCutDsd ); if ( Value != (int)pCut->fUseless ) { + if ( pCut->fUseless && !Value ) + p->nCountNonDec[0]++; + if ( !pCut->fUseless && Value ) + p->nCountNonDec[1]++; +/* +// if ( pCut->fUseless && !Value ) +// printf( "Old does not work. New works.\n" ); + if ( !pCut->fUseless && Value ) + printf( "Old works. New does not work. DSD = %d.\n", Abc_Lit2Var(pCut->iCutDsd) ); + if ( !pCut->fUseless && Value ) + { + extern word If_Dec6Perform( word t, int fDerive ); + extern word * If_DsdManComputeTruth( If_DsdMan_t * p, int iDsd, unsigned char * pPermLits ); + int s; + +// word z, t = *If_CutTruthW(p, pCut); + word z, t = *If_DsdManComputeTruth( p->pIfDsdMan, pCut->iCutDsd, NULL ); + + Extra_PrintHex( stdout, (unsigned *)If_CutTruthW(p, pCut), pCut->nLeaves ); printf( "\n" ); + + Dau_DsdPrintFromTruth( &t, pCut->nLeaves ); +// Dau_DsdPrintFromTruth( If_CutTruthW(p, pCut), pCut->nLeaves ); +// If_DsdManPrintOne( stdout, p->pIfDsdMan, Abc_Lit2Var(pCut->iCutDsd), pCut->pPerm, 1 ); +// printf( "Old works. New does not work. DSD = %d.\n", Abc_Lit2Var(pCut->iCutDsd) ); + + z = If_Dec6Perform( t, 1 ); + If_DecPrintConfig( z ); + + s = If_DsdManCheckXY( p->pIfDsdMan, pCut->iCutDsd, 4, 1 ); + printf( "Confirm %d\n", s ); + s = 0; + } +*/ } } } |