abc-master
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
nwkAig.c File Reference
#include "nwk.h"
#include "proof/abs/abs.h"

Go to the source code of this file.

Functions

ABC_NAMESPACE_IMPL_START
Nwk_Man_t
Nwk_ManDeriveFromAig (Aig_Man_t *p)
 DECLARATIONS ///. More...
 
Vec_Ptr_tNwk_ManDeriveRetimingCut (Aig_Man_t *p, int fForward, int fVerbose)
 FUNCTION DECLARATIONS ///. More...
 
ABC_NAMESPACE_IMPL_END
ABC_NAMESPACE_IMPL_START void 
Nwk_ManColleacReached_rec (Gia_Man_t *p, Gia_Obj_t *pObj, Vec_Int_t *vNodes, Vec_Int_t *vLeaves)
 
Nwk_Man_tNwk_ManCreateFromGia (Gia_Man_t *p, Vec_Int_t *vPPis, Vec_Int_t *vNodes, Vec_Int_t *vLeaves, Vec_Int_t **pvMapInv)
 
void Nwk_ManDeriveMinCut (Gia_Man_t *p, int fVerbose)
 

Function Documentation

ABC_NAMESPACE_IMPL_END ABC_NAMESPACE_IMPL_START void Nwk_ManColleacReached_rec ( Gia_Man_t p,
Gia_Obj_t pObj,
Vec_Int_t vNodes,
Vec_Int_t vLeaves 
)

Function*************************************************************

Synopsis [Collects reachable nodes.]

Description []

SideEffects []

SeeAlso []

Definition at line 124 of file nwkAig.c.

125 {
126  if ( Gia_ObjIsTravIdCurrent(p, pObj) )
127  return;
128  Gia_ObjSetTravIdCurrent(p, pObj);
129  if ( Gia_ObjIsCi(pObj) )
130  {
131  Vec_IntPush( vLeaves, Gia_ObjId(p, pObj) );
132  return;
133  }
134  assert( Gia_ObjIsAnd(pObj) );
135  Nwk_ManColleacReached_rec( p, Gia_ObjFanin0(pObj), vNodes, vLeaves );
136  Nwk_ManColleacReached_rec( p, Gia_ObjFanin1(pObj), vNodes, vLeaves );
137  Vec_IntPush( vNodes, Gia_ObjId(p, pObj) );
138 }
static int Gia_ObjIsTravIdCurrent(Gia_Man_t *p, Gia_Obj_t *pObj)
Definition: gia.h:533
ABC_NAMESPACE_IMPL_END ABC_NAMESPACE_IMPL_START void Nwk_ManColleacReached_rec(Gia_Man_t *p, Gia_Obj_t *pObj, Vec_Int_t *vNodes, Vec_Int_t *vLeaves)
Definition: nwkAig.c:124
static Gia_Obj_t * Gia_ObjFanin0(Gia_Obj_t *pObj)
Definition: gia.h:454
static void Gia_ObjSetTravIdCurrent(Gia_Man_t *p, Gia_Obj_t *pObj)
Definition: gia.h:531
static void Vec_IntPush(Vec_Int_t *p, int Entry)
Definition: bblif.c:468
static int Gia_ObjId(Gia_Man_t *p, Gia_Obj_t *pObj)
Definition: gia.h:410
static int Gia_ObjIsAnd(Gia_Obj_t *pObj)
Definition: gia.h:422
static Gia_Obj_t * Gia_ObjFanin1(Gia_Obj_t *pObj)
Definition: gia.h:455
#define assert(ex)
Definition: util_old.h:213
static int Gia_ObjIsCi(Gia_Obj_t *pObj)
Definition: gia.h:420
Nwk_Man_t* Nwk_ManCreateFromGia ( Gia_Man_t p,
Vec_Int_t vPPis,
Vec_Int_t vNodes,
Vec_Int_t vLeaves,
Vec_Int_t **  pvMapInv 
)

Function*************************************************************

Synopsis [Converts AIG into the network.]

Description []

SideEffects []

SeeAlso []

Definition at line 152 of file nwkAig.c.

153 {
154  Nwk_Man_t * pNtk;
155  Nwk_Obj_t ** ppCopies;
156  Gia_Obj_t * pObj;
157  Vec_Int_t * vMaps;
158  int i;
159 // assert( Vec_IntSize(vLeaves) >= Vec_IntSize(vPPis) );
160  Gia_ManCreateRefs( p );
161  pNtk = Nwk_ManAlloc();
162  pNtk->pName = Abc_UtilStrsav( p->pName );
163  pNtk->nFanioPlus = 0;
164  Hop_ManStop( pNtk->pManHop );
165  pNtk->pManHop = NULL;
166  // allocate
167  vMaps = Vec_IntAlloc( Vec_IntSize(vNodes) + Abc_MaxInt(Vec_IntSize(vPPis), Vec_IntSize(vLeaves)) + 1 );
168  ppCopies = ABC_ALLOC( Nwk_Obj_t *, Gia_ManObjNum(p) );
169  // copy objects
170  pObj = Gia_ManConst0(p);
171 // ppCopies[Gia_ObjId(p,pObj)] = Nwk_ManCreateNode( pNtk, 0, Gia_ObjRefNum(p,pObj) );
172  ppCopies[Gia_ObjId(p,pObj)] = Nwk_ManCreateNode( pNtk, 0, Gia_ObjRefNum(p,pObj) + (Vec_IntSize(vLeaves) > Vec_IntSize(vPPis) ? Vec_IntSize(vLeaves) - Vec_IntSize(vPPis) : 0) );
173  Vec_IntPush( vMaps, Gia_ObjId(p,pObj) );
174  Gia_ManForEachObjVec( vLeaves, p, pObj, i )
175  {
176  ppCopies[Gia_ObjId(p,pObj)] = Nwk_ManCreateCi( pNtk, Gia_ObjRefNum(p,pObj) );
177  assert( Vec_IntSize(vMaps) == Nwk_ObjId(ppCopies[Gia_ObjId(p,pObj)]) );
178  Vec_IntPush( vMaps, Gia_ObjId(p,pObj) );
179  }
180  for ( i = Vec_IntSize(vLeaves); i < Vec_IntSize(vPPis); i++ )
181  {
182  Nwk_ManCreateCi( pNtk, 0 );
183  Vec_IntPush( vMaps, -1 );
184  }
185  Gia_ManForEachObjVec( vNodes, p, pObj, i )
186  {
187  ppCopies[Gia_ObjId(p,pObj)] = Nwk_ManCreateNode( pNtk, 2, Gia_ObjRefNum(p,pObj) );
188  Nwk_ObjAddFanin( ppCopies[Gia_ObjId(p,pObj)], ppCopies[Gia_ObjFaninId0p(p,pObj)] );
189  Nwk_ObjAddFanin( ppCopies[Gia_ObjId(p,pObj)], ppCopies[Gia_ObjFaninId1p(p,pObj)] );
190  assert( Vec_IntSize(vMaps) == Nwk_ObjId(ppCopies[Gia_ObjId(p,pObj)]) );
191  Vec_IntPush( vMaps, Gia_ObjId(p,pObj) );
192  }
193  Gia_ManForEachObjVec( vPPis, p, pObj, i )
194  {
195  assert( ppCopies[Gia_ObjId(p,pObj)] != NULL );
196  Nwk_ObjAddFanin( Nwk_ManCreateCo(pNtk), ppCopies[Gia_ObjId(p,pObj)] );
197  }
198  for ( i = Vec_IntSize(vPPis); i < Vec_IntSize(vLeaves); i++ )
199  Nwk_ObjAddFanin( Nwk_ManCreateCo(pNtk), ppCopies[0] );
200  assert( Vec_IntSize(vMaps) == Vec_IntSize(vNodes) + Abc_MaxInt(Vec_IntSize(vPPis), Vec_IntSize(vLeaves)) + 1 );
201  ABC_FREE( ppCopies );
202  *pvMapInv = vMaps;
203  return pNtk;
204 }
void Gia_ManCreateRefs(Gia_Man_t *p)
Definition: giaUtil.c:715
typedefABC_NAMESPACE_HEADER_START struct Nwk_Obj_t_ Nwk_Obj_t
INCLUDES ///.
Definition: nwk.h:49
typedefABC_NAMESPACE_IMPL_START struct Vec_Int_t_ Vec_Int_t
DECLARATIONS ///.
Definition: bblif.c:37
static int Nwk_ObjId(Nwk_Obj_t *p)
Definition: nwk.h:135
static int Gia_ObjFaninId1p(Gia_Man_t *p, Gia_Obj_t *pObj)
Definition: gia.h:464
static int Gia_ObjRefNum(Gia_Man_t *p, Gia_Obj_t *pObj)
Definition: gia.h:521
#define ABC_ALLOC(type, num)
Definition: abc_global.h:229
char * pName
Definition: nwk.h:64
static int Abc_MaxInt(int a, int b)
Definition: abc_global.h:238
Definition: gia.h:75
void Hop_ManStop(Hop_Man_t *p)
Definition: hopMan.c:84
Hop_Man_t * pManHop
Definition: nwk.h:73
char * pName
Definition: gia.h:97
static Vec_Int_t * Vec_IntAlloc(int nCap)
FUNCTION DEFINITIONS ///.
Definition: bblif.c:149
Definition: nwk.h:61
ABC_DLL Nwk_Man_t * Nwk_ManAlloc()
DECLARATIONS ///.
Definition: nwkMan.c:45
ABC_DLL Nwk_Obj_t * Nwk_ManCreateCo(Nwk_Man_t *pMan)
Definition: nwkObj.c:92
static void Vec_IntPush(Vec_Int_t *p, int Entry)
Definition: bblif.c:468
static int Gia_ObjId(Gia_Man_t *p, Gia_Obj_t *pObj)
Definition: gia.h:410
#define Gia_ManForEachObjVec(vVec, p, pObj, i)
Definition: gia.h:988
ABC_DLL Nwk_Obj_t * Nwk_ManCreateCi(Nwk_Man_t *pMan, int nFanouts)
Definition: nwkObj.c:70
static int Vec_IntSize(Vec_Int_t *p)
Definition: bblif.c:252
#define ABC_FREE(obj)
Definition: abc_global.h:232
static Gia_Obj_t * Gia_ManConst0(Gia_Man_t *p)
Definition: gia.h:400
static int Gia_ObjFaninId0p(Gia_Man_t *p, Gia_Obj_t *pObj)
Definition: gia.h:463
ABC_DLL void Nwk_ObjAddFanin(Nwk_Obj_t *pObj, Nwk_Obj_t *pFanin)
Definition: nwkFanio.c:165
#define assert(ex)
Definition: util_old.h:213
char * Abc_UtilStrsav(char *s)
Definition: starter.c:47
static int Gia_ManObjNum(Gia_Man_t *p)
Definition: gia.h:388
ABC_DLL Nwk_Obj_t * Nwk_ManCreateNode(Nwk_Man_t *pMan, int nFanins, int nFanouts)
Definition: nwkObj.c:134
int nFanioPlus
Definition: nwk.h:71
ABC_NAMESPACE_IMPL_START Nwk_Man_t* Nwk_ManDeriveFromAig ( Aig_Man_t p)

DECLARATIONS ///.

CFile****************************************************************

FileName [nwkAig.c]

SystemName [ABC: Logic synthesis and verification system.]

PackageName [Netlist representation.]

Synopsis [Translating of AIG into the network.]

Author [Alan Mishchenko]

Affiliation [UC Berkeley]

Date [Ver. 1.0. Started - June 20, 2005.]

Revision [

Id:
nwkAig.c,v 1.00 2005/06/20 00:00:00 alanmi Exp

]FUNCTION DEFINITIONS /// Function*************************************************************

Synopsis [Converts AIG into the network.]

Description []

SideEffects []

SeeAlso []

Definition at line 45 of file nwkAig.c.

46 {
47  Nwk_Man_t * pNtk;
48  Aig_Obj_t * pObj;
49  int i;
50  pNtk = Nwk_ManAlloc();
51  pNtk->nFanioPlus = 0;
52  Hop_ManStop( pNtk->pManHop );
53  pNtk->pManHop = NULL;
54  pNtk->pName = Abc_UtilStrsav( p->pName );
55  pNtk->pSpec = Abc_UtilStrsav( p->pSpec );
56  pObj = Aig_ManConst1(p);
57  pObj->pData = Nwk_ManCreateNode( pNtk, 0, pObj->nRefs );
58  Aig_ManForEachCi( p, pObj, i )
59  pObj->pData = Nwk_ManCreateCi( pNtk, pObj->nRefs );
60  Aig_ManForEachNode( p, pObj, i )
61  {
62  pObj->pData = Nwk_ManCreateNode( pNtk, 2, pObj->nRefs );
63  Nwk_ObjAddFanin( (Nwk_Obj_t *)pObj->pData, (Nwk_Obj_t *)Aig_ObjFanin0(pObj)->pData );
64  Nwk_ObjAddFanin( (Nwk_Obj_t *)pObj->pData, (Nwk_Obj_t *)Aig_ObjFanin1(pObj)->pData );
65  }
66  Aig_ManForEachCo( p, pObj, i )
67  {
68  pObj->pData = Nwk_ManCreateCo( pNtk );
69  Nwk_ObjAddFanin( (Nwk_Obj_t *)pObj->pData, (Nwk_Obj_t *)Aig_ObjFanin0(pObj)->pData );
70  }
71  return pNtk;
72 }
typedefABC_NAMESPACE_HEADER_START struct Nwk_Obj_t_ Nwk_Obj_t
INCLUDES ///.
Definition: nwk.h:49
static Llb_Mgr_t * p
Definition: llb3Image.c:950
char * pSpec
Definition: nwk.h:65
void * pData
Definition: aig.h:87
static Aig_Obj_t * Aig_ObjFanin0(Aig_Obj_t *pObj)
Definition: aig.h:308
#define Aig_ManForEachCi(p, pObj, i)
ITERATORS ///.
Definition: aig.h:393
#define Aig_ManForEachCo(p, pObj, i)
Definition: aig.h:398
char * pName
Definition: nwk.h:64
static Aig_Obj_t * Aig_ObjFanin1(Aig_Obj_t *pObj)
Definition: aig.h:309
void Hop_ManStop(Hop_Man_t *p)
Definition: hopMan.c:84
#define Aig_ManForEachNode(p, pObj, i)
Definition: aig.h:413
Hop_Man_t * pManHop
Definition: nwk.h:73
Definition: nwk.h:61
ABC_DLL Nwk_Man_t * Nwk_ManAlloc()
DECLARATIONS ///.
Definition: nwkMan.c:45
ABC_DLL Nwk_Obj_t * Nwk_ManCreateCo(Nwk_Man_t *pMan)
Definition: nwkObj.c:92
Definition: aig.h:69
static Aig_Obj_t * Aig_ManConst1(Aig_Man_t *p)
Definition: aig.h:264
ABC_DLL Nwk_Obj_t * Nwk_ManCreateCi(Nwk_Man_t *pMan, int nFanouts)
Definition: nwkObj.c:70
ABC_DLL void Nwk_ObjAddFanin(Nwk_Obj_t *pObj, Nwk_Obj_t *pFanin)
Definition: nwkFanio.c:165
char * Abc_UtilStrsav(char *s)
Definition: starter.c:47
unsigned int nRefs
Definition: aig.h:81
ABC_DLL Nwk_Obj_t * Nwk_ManCreateNode(Nwk_Man_t *pMan, int nFanins, int nFanouts)
Definition: nwkObj.c:134
int nFanioPlus
Definition: nwk.h:71
void Nwk_ManDeriveMinCut ( Gia_Man_t p,
int  fVerbose 
)

Function*************************************************************

Synopsis [Returns min-cut in the AIG.]

Description []

SideEffects []

SeeAlso []

Definition at line 218 of file nwkAig.c.

219 {
220  Nwk_Man_t * pNtk;
221  Nwk_Obj_t * pNode;
222  Vec_Ptr_t * vMinCut;
223  Vec_Int_t * vPPis, * vNodes, * vLeaves, * vNodes2, * vLeaves2, * vMapInv;
224  Vec_Int_t * vCommon, * vDiff0, * vDiff1;
225  Gia_Obj_t * pObj;
226  int i, iObjId;
227  // get inputs
228  Gia_ManGlaCollect( p, p->vGateClasses, NULL, &vPPis, NULL, NULL );
229  // collect nodes rechable from PPIs
230  vNodes = Vec_IntAlloc( 100 );
231  vLeaves = Vec_IntAlloc( 100 );
233  Gia_ManForEachObjVec( vPPis, p, pObj, i )
234  Nwk_ManColleacReached_rec( p, pObj, vNodes, vLeaves );
235  // derive the new network
236  pNtk = Nwk_ManCreateFromGia( p, vPPis, vNodes, vLeaves, &vMapInv );
237  assert( Nwk_ManPiNum(pNtk) == Nwk_ManPoNum(pNtk) );
238  // create min-cut
239  vMinCut = Nwk_ManRetimeCutBackward( pNtk, Nwk_ManPiNum(pNtk), fVerbose );
240  // copy from the GIA back
241 // Aig_ManForEachObj( p, pObj, i )
242 // ((Nwk_Obj_t *)pObj->pData)->pCopy = pObj;
243  // mark min-cut nodes
244  vNodes2 = Vec_IntAlloc( 100 );
245  vLeaves2 = Vec_IntAlloc( 100 );
247  Vec_PtrForEachEntry( Nwk_Obj_t *, vMinCut, pNode, i )
248  {
249  pObj = Gia_ManObj( p, Vec_IntEntry(vMapInv, Nwk_ObjId(pNode)) );
250  if ( Gia_ObjIsConst0(pObj) )
251  continue;
252  Nwk_ManColleacReached_rec( p, pObj, vNodes2, vLeaves2 );
253  }
254  if ( fVerbose )
255  printf( "Min-cut: %d -> %d. Nodes %d -> %d. ", Vec_IntSize(vPPis)+1, Vec_PtrSize(vMinCut), Vec_IntSize(vNodes), Vec_IntSize(vNodes2) );
256  Vec_IntFree( vPPis );
257  Vec_PtrFree( vMinCut );
258  Vec_IntFree( vMapInv );
259  Nwk_ManFree( pNtk );
260 
261  // sort the results
262  Vec_IntSort( vNodes, 0 );
263  Vec_IntSort( vNodes2, 0 );
264  vCommon = Vec_IntAlloc( Vec_IntSize(vNodes) );
265  vDiff0 = Vec_IntAlloc( 100 );
266  vDiff1 = Vec_IntAlloc( 100 );
267  Vec_IntTwoSplit( vNodes, vNodes2, vCommon, vDiff0, vDiff1 );
268  if ( fVerbose )
269  printf( "Common = %d. Diff0 = %d. Diff1 = %d.\n", Vec_IntSize(vCommon), Vec_IntSize(vDiff0), Vec_IntSize(vDiff1) );
270 
271  // fill in
272  Vec_IntForEachEntry( vDiff0, iObjId, i )
273  Vec_IntWriteEntry( p->vGateClasses, iObjId, 1 );
274 
275  Vec_IntFree( vLeaves );
276  Vec_IntFree( vNodes );
277  Vec_IntFree( vLeaves2 );
278  Vec_IntFree( vNodes2 );
279 
280  Vec_IntFree( vCommon );
281  Vec_IntFree( vDiff0 );
282  Vec_IntFree( vDiff1 );
283 
284  // check abstraction
285  Gia_ManForEachObj( p, pObj, i )
286  {
287  if ( Vec_IntEntry( p->vGateClasses, i ) == 0 )
288  continue;
289  assert( Gia_ObjIsConst0(pObj) || Gia_ObjIsRo(p, pObj) || Gia_ObjIsAnd(pObj) );
290  }
291 }
typedefABC_NAMESPACE_HEADER_START struct Vec_Ptr_t_ Vec_Ptr_t
INCLUDES ///.
Definition: vecPtr.h:42
ABC_DLL int Nwk_ManPoNum(Nwk_Man_t *pNtk)
Definition: nwkUtil.c:135
ABC_DLL void Nwk_ManFree(Nwk_Man_t *p)
Definition: nwkMan.c:71
void Gia_ManGlaCollect(Gia_Man_t *p, Vec_Int_t *vGateClasses, Vec_Int_t **pvPis, Vec_Int_t **pvPPis, Vec_Int_t **pvFlops, Vec_Int_t **pvNodes)
Definition: absDup.c:158
typedefABC_NAMESPACE_HEADER_START struct Nwk_Obj_t_ Nwk_Obj_t
INCLUDES ///.
Definition: nwk.h:49
typedefABC_NAMESPACE_IMPL_START struct Vec_Int_t_ Vec_Int_t
DECLARATIONS ///.
Definition: bblif.c:37
static int Gia_ObjIsConst0(Gia_Obj_t *pObj)
Definition: gia.h:430
static int Nwk_ObjId(Nwk_Obj_t *p)
Definition: nwk.h:135
ABC_NAMESPACE_IMPL_END ABC_NAMESPACE_IMPL_START void Nwk_ManColleacReached_rec(Gia_Man_t *p, Gia_Obj_t *pObj, Vec_Int_t *vNodes, Vec_Int_t *vLeaves)
Definition: nwkAig.c:124
static int Vec_PtrSize(Vec_Ptr_t *p)
Definition: vecPtr.h:295
static void Vec_IntSort(Vec_Int_t *p, int fReverse)
Definition: vecInt.h:1293
static Gia_Obj_t * Gia_ManObj(Gia_Man_t *p, int v)
Definition: gia.h:402
Nwk_Man_t * Nwk_ManCreateFromGia(Gia_Man_t *p, Vec_Int_t *vPPis, Vec_Int_t *vNodes, Vec_Int_t *vLeaves, Vec_Int_t **pvMapInv)
Definition: nwkAig.c:152
Definition: gia.h:75
ABC_DLL Vec_Ptr_t * Nwk_ManRetimeCutBackward(Nwk_Man_t *pMan, int nLatches, int fVerbose)
Definition: nwkFlow.c:523
static void Vec_IntWriteEntry(Vec_Int_t *p, int i, int Entry)
Definition: bblif.c:285
static Vec_Int_t * Vec_IntAlloc(int nCap)
FUNCTION DEFINITIONS ///.
Definition: bblif.c:149
static void Vec_IntTwoSplit(Vec_Int_t *vArr1, Vec_Int_t *vArr2, Vec_Int_t *vArr, Vec_Int_t *vArr1n, Vec_Int_t *vArr2n)
Definition: vecInt.h:1707
Definition: nwk.h:61
static int Gia_ObjIsRo(Gia_Man_t *p, Gia_Obj_t *pObj)
Definition: gia.h:443
Vec_Int_t * vGateClasses
Definition: gia.h:141
static int Vec_IntEntry(Vec_Int_t *p, int i)
Definition: bblif.c:268
ABC_DLL int Nwk_ManPiNum(Nwk_Man_t *pNtk)
Definition: nwkUtil.c:115
#define Gia_ManForEachObjVec(vVec, p, pObj, i)
Definition: gia.h:988
static int Vec_IntSize(Vec_Int_t *p)
Definition: bblif.c:252
static int Gia_ObjIsAnd(Gia_Obj_t *pObj)
Definition: gia.h:422
#define Gia_ManForEachObj(p, pObj, i)
MACRO DEFINITIONS ///.
Definition: gia.h:984
#define assert(ex)
Definition: util_old.h:213
void Gia_ManIncrementTravId(Gia_Man_t *p)
Definition: giaUtil.c:149
static void Vec_IntFree(Vec_Int_t *p)
Definition: bblif.c:235
#define Vec_PtrForEachEntry(Type, vVec, pEntry, i)
MACRO DEFINITIONS ///.
Definition: vecPtr.h:55
#define Vec_IntForEachEntry(vVec, Entry, i)
MACRO DEFINITIONS ///.
Definition: vecInt.h:54
static void Vec_PtrFree(Vec_Ptr_t *p)
Definition: vecPtr.h:223
Vec_Ptr_t* Nwk_ManDeriveRetimingCut ( Aig_Man_t p,
int  fForward,
int  fVerbose 
)

FUNCTION DECLARATIONS ///.

Function*************************************************************

Synopsis [Converts AIG into the network.]

Description []

SideEffects []

SeeAlso []

Definition at line 85 of file nwkAig.c.

86 {
87  Vec_Ptr_t * vNodes;
88  Nwk_Man_t * pNtk;
89  Nwk_Obj_t * pNode;
90  Aig_Obj_t * pObj;
91  int i;
92  pNtk = Nwk_ManDeriveFromAig( p );
93  if ( fForward )
94  vNodes = Nwk_ManRetimeCutForward( pNtk, Aig_ManRegNum(p), fVerbose );
95  else
96  vNodes = Nwk_ManRetimeCutBackward( pNtk, Aig_ManRegNum(p), fVerbose );
97  Aig_ManForEachObj( p, pObj, i )
98  ((Nwk_Obj_t *)pObj->pData)->pCopy = pObj;
99  Vec_PtrForEachEntry( Nwk_Obj_t *, vNodes, pNode, i )
100  Vec_PtrWriteEntry( vNodes, i, pNode->pCopy );
101  Nwk_ManFree( pNtk );
102 // assert( Vec_PtrSize(vNodes) <= Aig_ManRegNum(p) );
103  return vNodes;
104 }
typedefABC_NAMESPACE_HEADER_START struct Vec_Ptr_t_ Vec_Ptr_t
INCLUDES ///.
Definition: vecPtr.h:42
ABC_DLL Vec_Ptr_t * Nwk_ManRetimeCutForward(Nwk_Man_t *pMan, int nLatches, int fVerbose)
Definition: nwkFlow.c:442
ABC_DLL void Nwk_ManFree(Nwk_Man_t *p)
Definition: nwkMan.c:71
typedefABC_NAMESPACE_HEADER_START struct Nwk_Obj_t_ Nwk_Obj_t
INCLUDES ///.
Definition: nwk.h:49
ABC_NAMESPACE_IMPL_START Nwk_Man_t * Nwk_ManDeriveFromAig(Aig_Man_t *p)
DECLARATIONS ///.
Definition: nwkAig.c:45
static Llb_Mgr_t * p
Definition: llb3Image.c:950
void * pData
Definition: aig.h:87
ABC_DLL Vec_Ptr_t * Nwk_ManRetimeCutBackward(Nwk_Man_t *pMan, int nLatches, int fVerbose)
Definition: nwkFlow.c:523
Definition: nwk.h:61
Definition: aig.h:69
static void Vec_PtrWriteEntry(Vec_Ptr_t *p, int i, void *Entry)
Definition: vecPtr.h:396
static int Aig_ManRegNum(Aig_Man_t *p)
Definition: aig.h:260
#define Aig_ManForEachObj(p, pObj, i)
Definition: aig.h:403
#define Vec_PtrForEachEntry(Type, vVec, pEntry, i)
MACRO DEFINITIONS ///.
Definition: vecPtr.h:55