90 printf(
"Groups:\n" );
93 if ( p->pvParts[i].nSize == 0 )
95 printf(
"%3d : ", i );
96 for ( k = 0; k < p->pvParts[i].nSize; k++ )
97 printf(
"%d ", p->pvParts[i].pArray[k] );
105 printf(
"Groups %d: ", p->nParts );
108 if ( p->pvParts[i].nSize == 0 )
114 printf(
"%d ", Count );
136 assert( p->pId2Part[ iObj ] >= 0 );
137 if ( p->pId2Part[ iFanin ] == -1 )
139 p->pId2Part[ iFanin ] = p->pId2Part[ iObj ];
140 Vec_IntPush( p->pvParts + p->pId2Part[ iObj ], iFanin );
148 assert( p->pId2Part[ iFanin ] == -1 );
149 p->pId2Part[ iFanin ] = p->pId2Part[ iObj ];
150 Vec_IntPush( p->pvParts + p->pId2Part[ iObj ], iFanin );
154 else if ( p->pId2Part[ iObj ] != p->pId2Part[ iFanin ] )
156 Vec_Int_t * vPartObj = p->pvParts + p->pId2Part[ iObj ];
157 Vec_Int_t * vPartFan = p->pvParts + p->pId2Part[ iFanin ];
165 p->pId2Part[ iTemp ] = p->pId2Part[ iFanin ];
175 int i, Limit, Count = 0;
184 printf(
"%6d : %6d -> %6d\n", ++Count, i, p->nParts );
200 if ( p->nParts == 1 )
282 int i, RetValue, iOut;
345 int i, j, Count, *
pPerm, Limit;
368 if ( Count < 2 )
continue;
385 ABC_SWAP(
int, vPivots->pArray[i], vPivots->pArray[j] );
386 ABC_SWAP(
int, vWeights->pArray[i], vWeights->pArray[j] );
389 if ( SelectShift == 0 )
401 for ( i = 0; i < Limit; i++ )
438 printf(
"Signature propagation: " );
504 printf(
"Computed %d partitions:\n",
Vec_PtrSize(vBins) );
506 printf(
"Listing partitions with more than 100 outputs:\n" );
575 *pvPosEquivs = vParts;
int Gia_ManConeMark_rec(Gia_Man_t *p, Gia_Obj_t *pObj, Vec_Int_t *vRoots, int nLimit)
static int * Vec_IntArray(Vec_Int_t *p)
Vec_Wrd_t * Gia_ManDeriveSigns(Gia_Man_t *p, Vec_Int_t *vPivots, int fVerbose)
void Gia_ManCreateRefs(Gia_Man_t *p)
Gia_Man_t * Gia_ManFindPoPartition3(Gia_Man_t *p, int iOut, int nDelta, int nOutsMin, int nOutsMax, int fVerbose, Vec_Ptr_t **pvPosEquivs)
int * Abc_QuickSortCost(int *pCosts, int nSize, int fDecrease)
Gia_Man_t * Gia_ManDupCones(Gia_Man_t *p, int *pPos, int nPos, int fTrimPis)
typedefABC_NAMESPACE_HEADER_START struct Vec_Ptr_t_ Vec_Ptr_t
INCLUDES ///.
typedefABC_NAMESPACE_HEADER_START struct Vec_Wec_t_ Vec_Wec_t
INCLUDES ///.
int Gia_ManConeMark(Gia_Man_t *p, int iOut, int Limit)
static void Vec_VecSort(Vec_Vec_t *p, int fReverse)
static Opa_Man_t * Opa_ManStart(Gia_Man_t *pGia)
FUNCTION DEFINITIONS ///.
typedefABC_NAMESPACE_HEADER_START struct Vec_Vec_t_ Vec_Vec_t
INCLUDES ///.
static int Gia_ManPoNum(Gia_Man_t *p)
typedefABC_NAMESPACE_IMPL_START struct Vec_Int_t_ Vec_Int_t
DECLARATIONS ///.
static Vec_Ptr_t * Vec_WecConvertToVecPtr(Vec_Wec_t *p)
static int Gia_ObjIsTravIdCurrent(Gia_Man_t *p, Gia_Obj_t *pObj)
static Gia_Obj_t * Gia_ManPo(Gia_Man_t *p, int v)
void Opa_ManMoveOne(Opa_Man_t *p, Gia_Obj_t *pObj, Gia_Obj_t *pFanin)
static Vec_Int_t * Vec_IntAllocArray(int *pArray, int nSize)
static void Vec_WrdPush(Vec_Wrd_t *p, word Entry)
static void Vec_WecFree(Vec_Wec_t *p)
static abctime Abc_Clock()
static int Vec_PtrSize(Vec_Ptr_t *p)
static Vec_Int_t * Vec_IntStartNatural(int nSize)
static void Vec_VecFree(Vec_Vec_t *p)
static Gia_Obj_t * Gia_ManObj(Gia_Man_t *p, int v)
static Vec_Int_t * Hsh_WrdManHashArray(Vec_Wrd_t *vDataW, int nSize)
#define ABC_SWAP(Type, a, b)
Gia_Man_t * Gia_ManFindPoPartition(Gia_Man_t *p, int SelectShift, int fOnlyCis, int fSetLargest, int fVerbose, Vec_Ptr_t **pvPosEquivs)
Vec_Ptr_t * Gia_ManHashOutputs(Gia_Man_t *p, Vec_Wrd_t *vSigns, int fVerbose)
unsigned Gia_ManRandom(int fReset)
FUNCTION DEFINITIONS ///.
#define Gia_ManForEachRiRo(p, pObjRi, pObjRo, i)
static void Abc_PrintTime(int level, const char *pStr, abctime time)
static int Gia_ManAndNum(Gia_Man_t *p)
static int Abc_MinInt(int a, int b)
static Gia_Obj_t * Gia_ObjFanin0(Gia_Obj_t *pObj)
static Vec_Int_t * Vec_IntAlloc(int nCap)
FUNCTION DEFINITIONS ///.
static int Gia_ObjIsRo(Gia_Man_t *p, Gia_Obj_t *pObj)
Gia_Man_t * Gia_ManFindPoPartition2(Gia_Man_t *p, int iStartNum, int nDelta, int nOutsMin, int nOutsMax, int fSetLargest, int fVerbose, Vec_Ptr_t **pvPosEquivs)
static Gia_Obj_t * Gia_ObjRoToRi(Gia_Man_t *p, Gia_Obj_t *pObj)
static int Vec_IntEntry(Vec_Int_t *p, int i)
unsigned __int64 word
DECLARATIONS ///.
static void Gia_ObjSetTravIdCurrent(Gia_Man_t *p, Gia_Obj_t *pObj)
#define ABC_NAMESPACE_IMPL_END
static void Vec_WrdFree(Vec_Wrd_t *p)
static void Vec_IntPush(Vec_Int_t *p, int Entry)
static int Gia_ObjId(Gia_Man_t *p, Gia_Obj_t *pObj)
void Gia_ManFillValue(Gia_Man_t *p)
typedefABC_NAMESPACE_IMPL_START struct Opa_Man_t_ Opa_Man_t
DECLARATIONS ///.
int Gia_ManCountFlops(Gia_Man_t *p, Vec_Int_t *vOuts)
static Vec_Int_t * Vec_VecEntryInt(Vec_Vec_t *p, int i)
static int Gia_ObjIsCo(Gia_Obj_t *pObj)
static Vec_Wrd_t * Vec_WrdAlloc(int nCap)
FUNCTION DEFINITIONS ///.
#define Gia_ManForEachObjVec(vVec, p, pObj, i)
#define ABC_NAMESPACE_IMPL_START
static Vec_Wrd_t * Vec_WrdStart(int nSize)
static int Gia_ManCiNum(Gia_Man_t *p)
static void Opa_ManPrint2(Opa_Man_t *p)
static int Vec_IntSize(Vec_Int_t *p)
void Extra_PrintBinary(FILE *pFile, unsigned Sign[], int nBits)
static void Opa_ManPrint(Opa_Man_t *p)
static void Vec_IntShrink(Vec_Int_t *p, int nSizeNew)
static void Opa_ManStop(Opa_Man_t *p)
static int Gia_ObjIsAnd(Gia_Obj_t *pObj)
#define Gia_ManForEachObj(p, pObj, i)
MACRO DEFINITIONS ///.
static Gia_Obj_t * Gia_ManConst0(Gia_Man_t *p)
static word Vec_WrdEntry(Vec_Wrd_t *p, int i)
#define ABC_CALLOC(type, num)
static int Gia_ObjIsPo(Gia_Man_t *p, Gia_Obj_t *pObj)
static Gia_Obj_t * Gia_ObjFanin1(Gia_Obj_t *pObj)
Vec_Int_t * Gia_ManFindPivots(Gia_Man_t *p, int SelectShift, int fOnlyCis, int fVerbose)
#define ABC_INFINITY
MACRO DEFINITIONS ///.
void Gia_ManIncrementTravId(Gia_Man_t *p)
static void Vec_IntFree(Vec_Int_t *p)
#define Vec_PtrForEachEntry(Type, vVec, pEntry, i)
MACRO DEFINITIONS ///.
static int Gia_ObjIsCi(Gia_Obj_t *pObj)
#define Gia_ManForEachPo(p, pObj, i)
#define Vec_IntForEachEntry(vVec, Entry, i)
MACRO DEFINITIONS ///.
static int Gia_ObjFaninId1(Gia_Obj_t *pObj, int ObjId)
typedefABC_NAMESPACE_HEADER_START struct Vec_Wrd_t_ Vec_Wrd_t
INCLUDES ///.
void Opa_ManPerform(Gia_Man_t *pGia)
static int Gia_ManObjNum(Gia_Man_t *p)
static Vec_Wec_t * Vec_WecCreateClasses(Vec_Int_t *vMap)
#define ABC_FALLOC(type, num)
static int Gia_ObjFaninId0(Gia_Obj_t *pObj, int ObjId)
static int Gia_ObjIsPi(Gia_Man_t *p, Gia_Obj_t *pObj)
static word * Vec_WrdEntryP(Vec_Wrd_t *p, int i)