diff options
author | Alan Mishchenko <alanmi@berkeley.edu> | 2018-08-01 20:50:07 -0800 |
---|---|---|
committer | Alan Mishchenko <alanmi@berkeley.edu> | 2018-08-01 20:50:07 -0800 |
commit | cb165d8c15cd850986737b48d8d577cbc3159e85 (patch) | |
tree | fc30cb34e27013a95f6ae45015c8f2a6058de071 /src/opt/dau/dauNpn.c | |
parent | a5042e19c42e1bfa8689bb2381c37d9771f22365 (diff) | |
download | abc-cb165d8c15cd850986737b48d8d577cbc3159e85.tar.gz abc-cb165d8c15cd850986737b48d8d577cbc3159e85.tar.bz2 abc-cb165d8c15cd850986737b48d8d577cbc3159e85.zip |
Experiments with function enumeration.
Diffstat (limited to 'src/opt/dau/dauNpn.c')
-rw-r--r-- | src/opt/dau/dauNpn.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/opt/dau/dauNpn.c b/src/opt/dau/dauNpn.c index 7484449f..41155a9d 100644 --- a/src/opt/dau/dauNpn.c +++ b/src/opt/dau/dauNpn.c @@ -63,7 +63,7 @@ void Dau_TruthEnum() int * pPerm = Extra_PermSchedule( nVars ); int * pComp = Extra_GreyCodeSchedule( nVars ); word nFuncs = ((word)1 << (((word)1 << nVars)-1)); - word * pPres = ABC_CALLOC( word, 1 << ((1<<nVars)-7) ); + word * pPres = ABC_CALLOC( word, 1 << ((1<<nVars)-6) ); unsigned * pTable = fUseTable ? (unsigned *)ABC_CALLOC(word, nSizeW) : NULL; Vec_Int_t * vNpns = Vec_IntAlloc( 1000 ); word tMask = Abc_Tt6Mask( 1 << nVars ); @@ -77,13 +77,13 @@ void Dau_TruthEnum() if ( pTable == NULL ) printf( "Cannot alloc memory for table.\n" ); - for ( i = 0; i <= 0x7FFFFFFF; i++ ) - if ( (i & 0x0FFFFFFF) == 0x0FFFFFFF ) - printf( "%08x : %08x\n", i, pTable[i] ); + for ( tCur = 0; tCur < nFuncs; tCur++ ) + if ( (tCur & 0x07FFFFFF) == 0 ) + printf( "%08x : %08x\n", (int)tCur, pTable[(int)tCur] ); for ( tCur = 0; tCur < nFuncs; tCur++ ) { - if ( (tCur & 0xFFFF) == 0 ) + if ( (tCur & 0xFF) == 0 ) printf( "Finished %08x\n", (int)tCur ), fflush(stdout); if ( Abc_TtGetBit(pPres, (int)tCur) ) continue; |