ABC: A System for Sequential Synthesis and Verification
 
Loading...
Searching...
No Matches
cov.h
Go to the documentation of this file.
1
20
21#ifndef ABC__map__cov__cov_h
22#define ABC__map__cov__cov_h
23
24#include "base/abc/abc.h"
25#include "covInt.h"
26
27
29
33
34typedef struct Cov_Man_t_ Cov_Man_t;
35typedef struct Cov_Obj_t_ Cov_Obj_t;
36
37// storage for node information
39{
40 Min_Cube_t * pCover[3]; // pos/neg/esop
41 Vec_Int_t * vSupp; // computed support (all nodes except CIs)
42};
43
44// storage for additional information
46{
47 // general characteristics
48 int nFaninMax; // the number of vars
49 int nCubesMax; // the limit on the number of cubes in the intermediate covers
50 int nWords; // the number of words
51 Vec_Int_t * vFanCounts; // fanout counts
52 Vec_Ptr_t * vObjStrs; // object structures
53 void * pMemory; // memory for the internal data strctures
54 Min_Man_t * pManMin; // the cube manager
55 int fUseEsop; // enables ESOPs
56 int fUseSop; // enables SOPs
57 // arrays to map local variables
58 Vec_Int_t * vComTo0; // mapping of common variables into first fanin
59 Vec_Int_t * vComTo1; // mapping of common variables into second fanin
60 Vec_Int_t * vPairs0; // the first var in each pair of common vars
61 Vec_Int_t * vPairs1; // the second var in each pair of common vars
62 Vec_Int_t * vTriv0; // trival support of the first node
63 Vec_Int_t * vTriv1; // trival support of the second node
64 // statistics
65 int nSupps; // supports created
66 int nSuppsMax; // the maximum number of supports
67 int nBoundary; // the boundary size
68 int nNodes; // the number of nodes processed
69};
70
71static inline Cov_Obj_t * Abc_ObjGetStr( Abc_Obj_t * pObj ) { return (Cov_Obj_t *)Vec_PtrEntry(((Cov_Man_t *)pObj->pNtk->pManCut)->vObjStrs, pObj->Id); }
72
73static inline void Abc_ObjSetSupp( Abc_Obj_t * pObj, Vec_Int_t * vVec ) { Abc_ObjGetStr(pObj)->vSupp = vVec; }
74static inline Vec_Int_t * Abc_ObjGetSupp( Abc_Obj_t * pObj ) { return Abc_ObjGetStr(pObj)->vSupp; }
75
76static inline void Abc_ObjSetCover2( Abc_Obj_t * pObj, Min_Cube_t * pCov ) { Abc_ObjGetStr(pObj)->pCover[2] = pCov; }
77static inline Min_Cube_t * Abc_ObjGetCover2( Abc_Obj_t * pObj ) { return Abc_ObjGetStr(pObj)->pCover[2]; }
78
79static inline void Abc_ObjSetCover( Abc_Obj_t * pObj, Min_Cube_t * pCov, int Pol ) { Abc_ObjGetStr(pObj)->pCover[Pol] = pCov; }
80static inline Min_Cube_t * Abc_ObjGetCover( Abc_Obj_t * pObj, int Pol ) { return Abc_ObjGetStr(pObj)->pCover[Pol]; }
81
85
86/*=== covBuild.c ==========================================================*/
87extern Abc_Ntk_t * Abc_NtkCovDerive( Cov_Man_t * p, Abc_Ntk_t * pNtk );
90/*=== covCore.c ===========================================================*/
91extern Abc_Ntk_t * Abc_NtkSopEsopCover( Abc_Ntk_t * pNtk, int nFaninMax, int nCubesMax, int fUseEsop, int fUseSop, int fUseInvs, int fVerbose );
92/*=== covMan.c ============================================================*/
93extern Cov_Man_t * Cov_ManAlloc( Abc_Ntk_t * pNtk, int nFaninMax, int nCubesMax );
94extern void Cov_ManFree( Cov_Man_t * p );
95extern void Abc_NodeCovDropData( Cov_Man_t * p, Abc_Obj_t * pObj );
96/*=== covTest.c ===========================================================*/
98
99
101
102#endif
103
107
108
109
struct Abc_Obj_t_ Abc_Obj_t
Definition abc.h:116
struct Abc_Ntk_t_ Abc_Ntk_t
Definition abc.h:115
#define ABC_NAMESPACE_HEADER_END
#define ABC_NAMESPACE_HEADER_START
NAMESPACES ///.
typedefABC_NAMESPACE_IMPL_START struct Vec_Int_t_ Vec_Int_t
DECLARATIONS ///.
Definition bblif.c:37
struct Min_Cube_t_ Min_Cube_t
Definition covInt.h:35
Abc_Ntk_t * Abc_NtkCovTestSop(Abc_Ntk_t *pNtk)
Abc_Ntk_t * Abc_NtkCovDeriveClean(Cov_Man_t *p, Abc_Ntk_t *pNtk)
Definition covBuild.c:357
Abc_Ntk_t * Abc_NtkCovDerive(Cov_Man_t *p, Abc_Ntk_t *pNtk)
FUNCTION DEFINITIONS ///.
Definition covBuild.c:183
Abc_Ntk_t * Abc_NtkSopEsopCover(Abc_Ntk_t *pNtk, int nFaninMax, int nCubesMax, int fUseEsop, int fUseSop, int fUseInvs, int fVerbose)
FUNCTION DEFINITIONS ///.
Definition covCore.c:60
void Abc_NodeCovDropData(Cov_Man_t *p, Abc_Obj_t *pObj)
Definition covMan.c:126
void Cov_ManFree(Cov_Man_t *p)
Definition covMan.c:92
Abc_Ntk_t * Abc_NtkCovDeriveRegular(Cov_Man_t *p, Abc_Ntk_t *pNtk)
Definition covBuild.c:503
typedefABC_NAMESPACE_HEADER_START struct Cov_Man_t_ Cov_Man_t
DECLARATIONS ///.
Definition cov.h:34
Cov_Man_t * Cov_ManAlloc(Abc_Ntk_t *pNtk, int nFaninMax, int nCubesMax)
DECLARATIONS ///.
Definition covMan.c:45
struct Cov_Obj_t_ Cov_Obj_t
Definition cov.h:35
Cube * p
Definition exorList.c:222
typedefABC_NAMESPACE_IMPL_START struct Min_Man_t_ Min_Man_t
DECLARATIONS ///.
Definition giaPat2.c:34
void * pManCut
Definition abc.h:193
Abc_Ntk_t * pNtk
Definition abc.h:130
int Id
Definition abc.h:132
int nCubesMax
Definition cov.h:49
Min_Man_t * pManMin
Definition cov.h:54
int nSupps
Definition cov.h:65
void * pMemory
Definition cov.h:53
int fUseSop
Definition cov.h:56
Vec_Ptr_t * vObjStrs
Definition cov.h:52
int fUseEsop
Definition cov.h:55
Vec_Int_t * vComTo0
Definition cov.h:58
int nFaninMax
Definition cov.h:48
int nSuppsMax
Definition cov.h:66
Vec_Int_t * vTriv1
Definition cov.h:63
int nNodes
Definition cov.h:68
Vec_Int_t * vFanCounts
Definition cov.h:51
Vec_Int_t * vPairs1
Definition cov.h:61
Vec_Int_t * vTriv0
Definition cov.h:62
Vec_Int_t * vPairs0
Definition cov.h:60
int nBoundary
Definition cov.h:67
Vec_Int_t * vComTo1
Definition cov.h:59
int nWords
Definition cov.h:50
Vec_Int_t * vSupp
Definition cov.h:41
Min_Cube_t * pCover[3]
Definition cov.h:40
typedefABC_NAMESPACE_HEADER_START struct Vec_Ptr_t_ Vec_Ptr_t
INCLUDES ///.
Definition vecPtr.h:42