51 pCut->
uSign = 10 * Cnf_CutSopCost(
p, pCut );
55 if ( !Aig_ObjIsNode(pLeaf) )
77 nAreaFlow = 100 * (Vec_PtrSize(vSuper) + 1);
80 pLeaf = Aig_Regular(pLeaf);
81 if ( !Aig_ObjIsNode(pLeaf) )
84 nAreaFlow += pAreaFlows[pLeaf->
Id] / (pLeaf->
nRefs? pLeaf->
nRefs : 1);
105 int i, k, AreaFlow, * pAreaFlows;
107 pAreaFlows =
ABC_ALLOC(
int, Aig_ManObjNumMax(
p->pManAig) );
108 memset( pAreaFlows, 0,
sizeof(
int) * Aig_ManObjNumMax(
p->pManAig) );
110 vSuper = Vec_PtrAlloc( 100 );
121 if ( pCutBest == NULL || pCutBest->
uSign > pCut->
uSign ||
130 if ( AreaFlow >= (
int)pCutBest->
uSign )
132 pAreaFlows[pObj->
Id] = pCutBest->
uSign;
137 pAreaFlows[pObj->
Id] = AreaFlow;
141 Vec_PtrFree( vSuper );
175 if ( --pLeaf->
nRefs > 0 || !Aig_ObjIsAnd(pLeaf) )
177 Aig_CutDeref(
p, Aig_ObjBestCut(pLeaf) );
195 int i, Area = pCut->
Value;
199 if ( pLeaf->
nRefs++ > 0 || !Aig_ObjIsAnd(pLeaf) )
201 Area += Aig_CutRef(
p, Aig_ObjBestCut(pLeaf) );
220 Area = Aig_CutRef(
p, pCut );
221 Aig_CutDeref(
p, pCut );
238 if ( pC0->Area < pC1->Area - 0.0001 )
240 if ( pC0->Area > pC1->Area + 0.0001 )
271 if ( pCutBest == NULL || Cnf_CutCompare(pCutBest, pCut) == 1 )
291 pCut->Area = (float)pCut->Cost;
296 if ( !Aig_ObjIsNode(pLeaf) )
298 if ( pLeaf->
nRefs == 0 )
300 pCut->Area += Aig_ObjBestCut(pLeaf)->Cost;
305 if ( pCut->FanRefs + pLeaf->
nRefs > 15 )
308 pCut->FanRefs += pLeaf->
nRefs;
333 pCutBest = Aig_ObjBestCut(pObj);
334 Dar_ObjClearBestCut(pCutBest);
337 Aig_CutDeref(
p->pManAig, pCutBest );
342 pCut->Area = (float)Cnf_CutArea(
p->pManAig, pCut );
345 pCutBest = Cnf_ObjFindBestCut(pObj);
346 Dar_ObjSetBestCut( pCutBest );
349 Aig_CutRef(
p->pManAig, pCutBest );
#define ABC_ALLOC(type, num)
#define ABC_INFINITY
MACRO DEFINITIONS ///.
#define ABC_NAMESPACE_IMPL_START
#define ABC_NAMESPACE_IMPL_END
struct Aig_Obj_t_ Aig_Obj_t
#define Aig_ManForEachNode(p, pObj, i)
typedefABC_NAMESPACE_HEADER_START struct Aig_Man_t_ Aig_Man_t
INCLUDES ///.
ABC_NAMESPACE_IMPL_START void Cnf_CutAssignAreaFlow(Cnf_Man_t *p, Dar_Cut_t *pCut, int *pAreaFlows)
DECLARATIONS ///.
int Cnf_CutSuperAreaFlow(Vec_Ptr_t *vSuper, int *pAreaFlows)
void Cnf_DeriveMapping(Cnf_Man_t *p)
int Cnf_ManMapForCnf(Cnf_Man_t *p)
typedefABC_NAMESPACE_HEADER_START struct Cnf_Man_t_ Cnf_Man_t
INCLUDES ///.
struct Dar_Cut_t_ Dar_Cut_t
#define Dar_CutForEachLeaf(p, pCut, pLeaf, i)
#define Dar_ObjForEachCut(pObj, pCut, i)
typedefABC_NAMESPACE_HEADER_START struct Vec_Ptr_t_ Vec_Ptr_t
INCLUDES ///.
#define Vec_PtrForEachEntry(Type, vVec, pEntry, i)
MACRO DEFINITIONS ///.