57 if ( Hop_IsComplement(pRoot) )
58 Extra_TruthNot( pTruth, pTruth, nVars );
62 float Prob = (float)2.0 * dProb * (1.0 - dProb);
63 assert( Prob >= 0.0 && Prob <= 0.5 );
66 Extra_TruthNot( puCare, puCare, nVars );
68 Extra_TruthOr( pTruth, pTruth, puCare, nVars );
70 Extra_TruthSharp( pTruth, pTruth, puCare, nVars );
71 Extra_TruthNot( puCare, puCare, nVars );
88 for ( i = 0; i < nVars; i++ )
91 for ( i = nVars + 1; i < nNodes; i++ )
116 int i, nGainTotal = 0, nNodes1, nNodes2;
118 assert( Abc_NtkIsLogic(pNtk) );
122 pPars->fVerbose = fVerbose;
123 if ( pPars->nVarsMax > 15 )
126 printf(
"Resynthesis is not performed for nodes with more than 15 inputs.\n" );
127 pPars->nVarsMax = 15;
129 vTruth = Vec_IntAlloc( 0 );
133 if ( Abc_ObjFaninNum(pObj) > 15 )
138 nGainTotal += nNodes1 - nNodes2;
141 Vec_IntFree( vTruth );
144 printf(
"Total gain in AIG nodes = %d. ", nGainTotal );
145 ABC_PRT(
"Total runtime", Abc_Clock() - clk );
void Abc_NtkBidecResyn(Abc_Ntk_t *pNtk, int fVerbose)
Hop_Obj_t * Abc_NodeIfNodeResyn(Bdc_Man_t *p, Hop_Man_t *pHop, Hop_Obj_t *pRoot, int nVars, Vec_Int_t *vTruth, unsigned *puCare, float dProb)
FUNCTION DEFINITIONS ///.
struct Abc_Obj_t_ Abc_Obj_t
ABC_DLL int Abc_NtkGetFaninMax(Abc_Ntk_t *pNtk)
struct Abc_Ntk_t_ Abc_Ntk_t
ABC_DLL int Abc_NtkToAig(Abc_Ntk_t *pNtk)
#define Abc_NtkForEachNode(pNtk, pNode, i)
#define ABC_NAMESPACE_IMPL_START
#define ABC_NAMESPACE_IMPL_END
typedefABC_NAMESPACE_IMPL_START struct Vec_Int_t_ Vec_Int_t
DECLARATIONS ///.
int Bdc_ManNodeNum(Bdc_Man_t *p)
Bdc_Fun_t * Bdc_FuncFanin0(Bdc_Fun_t *p)
Bdc_Fun_t * Bdc_ManRoot(Bdc_Man_t *p)
typedefABC_NAMESPACE_HEADER_START struct Bdc_Fun_t_ Bdc_Fun_t
INCLUDES ///.
struct Bdc_Par_t_ Bdc_Par_t
void Bdc_FuncSetCopy(Bdc_Fun_t *p, void *pCopy)
struct Bdc_Man_t_ Bdc_Man_t
Bdc_Fun_t * Bdc_FuncFanin1(Bdc_Fun_t *p)
void * Bdc_FuncCopy(Bdc_Fun_t *p)
void Bdc_ManFree(Bdc_Man_t *p)
int Bdc_ManDecompose(Bdc_Man_t *p, unsigned *puFunc, unsigned *puCare, int nVars, Vec_Ptr_t *vDivs, int nNodesMax)
Bdc_Fun_t * Bdc_ManFunc(Bdc_Man_t *p, int i)
DECLARATIONS ///.
Bdc_Man_t * Bdc_ManAlloc(Bdc_Par_t *pPars)
MACRO DEFINITIONS ///.
typedefABC_NAMESPACE_HEADER_START struct Hop_Man_t_ Hop_Man_t
INCLUDES ///.
int Hop_DagSize(Hop_Obj_t *pObj)
Hop_Obj_t * Hop_And(Hop_Man_t *p, Hop_Obj_t *p0, Hop_Obj_t *p1)
unsigned * Hop_ManConvertAigToTruth(Hop_Man_t *p, Hop_Obj_t *pRoot, int nVars, Vec_Int_t *vTruth, int fMsbFirst)
struct Hop_Obj_t_ Hop_Obj_t