31static unsigned short * s_puCanons = NULL;
32static char * s_pPhases = NULL;
33static char * s_pPerms = NULL;
34static unsigned char * s_pMap = NULL;
53 if ( s_puCanons == NULL )
97 p->puCanons = s_puCanons;
98 p->pPhases = s_pPhases;
108 p->vForest = Vec_PtrAlloc( 100 );
118 p->vLevNums = Vec_IntAlloc( 50 );
119 p->vFanins = Vec_PtrAlloc( 50 );
120 p->vFaninsCur = Vec_PtrAlloc( 50 );
121 p->vNodesTemp = Vec_PtrAlloc( 50 );
134p->timeStart = Abc_Clock() - clk;
158 if (
p->vClasses ) Vec_VecFree(
p->vClasses );
159 Vec_PtrFree(
p->vNodesTemp );
160 Vec_PtrFree(
p->vForest );
161 Vec_IntFree(
p->vLevNums );
162 Vec_PtrFree(
p->vFanins );
163 Vec_PtrFree(
p->vFaninsCur );
186 for ( i = 0; i < 222; i++ )
187 Counter += (
p->nScores[i] > 0);
189 printf(
"Rewriting statistics:\n" );
190 printf(
"Total cuts tries = %8d.\n",
p->nCutsGood );
191 printf(
"Bad cuts found = %8d.\n",
p->nCutsBad );
192 printf(
"Total subgraphs = %8d.\n",
p->nSubgraphs );
193 printf(
"Used NPN classes = %8d.\n", Counter );
194 printf(
"Nodes considered = %8d.\n",
p->nNodesConsidered );
195 printf(
"Nodes rewritten = %8d.\n",
p->nNodesRewritten );
196 printf(
"Calculated gain = %8d.\n",
p->nNodesGained );
200 ABC_PRT(
"Resynthesis ",
p->timeRes );
203 ABC_PRT(
"Update ",
p->timeUpdate );
233 pTable = fopen(
"stats.txt",
"a+" );
234 fprintf( pTable,
"%d ",
p->nCutsGood );
235 fprintf( pTable,
"%d ",
p->nSubgraphs );
236 fprintf( pTable,
"%d ",
p->nNodesRewritten );
237 fprintf( pTable,
"%d",
p->nNodesGained );
238 fprintf( pTable,
"\n" );
319 p->timeUpdate += Time;
335 p->timeTotal += Time;
#define ABC_ALLOC(type, num)
#define ABC_NAMESPACE_IMPL_START
#define ABC_NAMESPACE_IMPL_END
struct Dec_Graph_t_ Dec_Graph_t
void Mem_FixedStop(Mem_Fixed_t *p, int fVerbose)
Mem_Fixed_t * Mem_FixedStart(int nEntrySize)
FUNCTION DEFINITIONS ///.
void Rwt_ManPrintStatsFile(Rwt_Man_t *p)
void Rwt_ManPrintStats(Rwt_Man_t *p)
int Rwt_ManReadCompl(Rwt_Man_t *p)
Vec_Ptr_t * Rwt_ManReadLeaves(Rwt_Man_t *p)
void Rwt_ManAddTimeUpdate(Rwt_Man_t *p, abctime Time)
void * Rwt_ManReadDecs(Rwt_Man_t *p)
void Rwt_ManGlobalStart()
FUNCTION DEFINITIONS ///.
void Rwt_ManAddTimeCuts(Rwt_Man_t *p, abctime Time)
void Rwt_ManAddTimeTotal(Rwt_Man_t *p, abctime Time)
void Rwt_ManStop(Rwt_Man_t *p)
Rwt_Man_t * Rwt_ManStart(int fPrecompute)
void Rwt_ManLoadFromArray(Rwt_Man_t *p, int fVerbose)
struct Rwt_Man_t_ Rwt_Man_t
Rwt_Node_t * Rwt_ManAddVar(Rwt_Man_t *p, unsigned uTruth, int fPrecompute)
struct Rwt_Node_t_ Rwt_Node_t
char * Rwt_ManGetPractical(Rwt_Man_t *p)
void Rwt_ManPreprocess(Rwt_Man_t *p)
MACRO DEFINITIONS ///.
typedefABC_NAMESPACE_HEADER_START struct Vec_Ptr_t_ Vec_Ptr_t
INCLUDES ///.
#define Vec_VecForEachEntry(Type, vGlob, pEntry, i, k)