summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/map/if/if.h1
-rw-r--r--src/map/if/ifMan.c1
-rw-r--r--src/map/if/ifMap.c10
3 files changed, 12 insertions, 0 deletions
diff --git a/src/map/if/if.h b/src/map/if/if.h
index 5076bb28..be6232ec 100644
--- a/src/map/if/if.h
+++ b/src/map/if/if.h
@@ -226,6 +226,7 @@ struct If_Man_t_
int nCutsCount[32];
int nCutsCountAll;
int nCutsUselessAll;
+ int nCuts5, nCuts5a;
// Abc_Nam_t * pNamDsd;
int iNamVar;
Dss_Man_t * pDsdMan;
diff --git a/src/map/if/ifMan.c b/src/map/if/ifMan.c
index e483a54d..20c3f0f9 100644
--- a/src/map/if/ifMan.c
+++ b/src/map/if/ifMan.c
@@ -151,6 +151,7 @@ void If_ManStop( If_Man_t * p )
if ( p->nCutsUseless[i] )
Abc_Print( 1, "Useless cuts %2d = %9d (out of %9d) (%6.2f %%)\n", i, p->nCutsUseless[i], p->nCutsCount[i], 100.0*p->nCutsUseless[i]/(p->nCutsCount[i]+1) );
Abc_Print( 1, "Useless cuts all = %9d (out of %9d) (%6.2f %%)\n", p->nCutsUselessAll, p->nCutsCountAll, 100.0*p->nCutsUselessAll/(p->nCutsCountAll+1) );
+ Abc_Print( 1, "Statistics about 5-cuts: Total = %d Non-decomposable = %d (%.2f %%)\n", p->nCuts5, p->nCuts5-p->nCuts5a, 100.0*(p->nCuts5-p->nCuts5a)/p->nCuts5 );
}
if ( p->pPars->fUseDsd )
{
diff --git a/src/map/if/ifMap.c b/src/map/if/ifMap.c
index 7520c325..853e9cb0 100644
--- a/src/map/if/ifMap.c
+++ b/src/map/if/ifMap.c
@@ -273,6 +273,16 @@ void If_ObjPerformMappingAnd( If_Man_t * p, If_Obj_t * pObj, int Mode, int fPrep
p->nCutsUseless[pCut->nLeaves] += pCut->fUseless;
p->nCutsCountAll++;
p->nCutsCount[pCut->nLeaves]++;
+ if ( p->pPars->fVerbose && pCut->nLeaves == 5 )
+ {
+ extern int If_CluCheckDecIn( word t, int nVars );
+ extern int If_CluCheckDecOut( word t, int nVars );
+ unsigned TruthU = *If_CutTruth(pCut);
+ word Truth = (((word)TruthU << 32) | (word)TruthU);
+ p->nCuts5++;
+ if ( If_CluCheckDecIn( Truth, 5 ) || If_CluCheckDecOut( Truth, 5 ) )
+ p->nCuts5a++;
+ }
}
}
if ( p->pPars->fUseDsd )