61 for ( f = 0; f < nFrames; f++ )
72 if ( f == nFrames - 1 )
124 Aig_Obj_t * pObj, * pObjLi, * pObjLo, * pObjPo;
136 for ( f = 0; f < nFrames; f++ )
150 if ( Counter >= nSizeMax )
155 if ( f == nFrames - 1 )
186 int Saig_ManBmcSimple(
Aig_Man_t * pAig,
int nFrames,
int nSizeMax,
int nConfLimit,
int fRewrite,
int fVerbose,
int * piFrame,
int nCofFanLit )
193 int status, Lit, i, RetValue = -1;
201 if ( pFrames == NULL )
204 else if ( nSizeMax > 0 )
215 printf(
"Running \"bmc\". AIG: PI/PO/Reg = %d/%d/%d. Node = %6d. Lev = %5d.\n",
218 printf(
"Time-frames (%d): PI/PO = %d/%d. Node = %6d. Lev = %5d. ",
233 printf(
"Time-frames after rewriting: Node = %6d. Lev = %5d. ",
246 for ( i = 0; i < pCnf->
nClauses; i++ )
253 printf(
"CNF: Variables = %6d. Clauses = %7d. Literals = %8d. ", pCnf->
nVars, pCnf->
nClauses, pCnf->
nLiterals );
262 printf(
"The BMC problem is trivially UNSAT\n" );
276 printf(
"Solving output %2d of frame %3d ... \r",
280 status =
sat_solver_solve( pSat, &Lit, &Lit + 1, (ABC_INT64_T)nConfLimit, (ABC_INT64_T)0, (ABC_INT64_T)0, (ABC_INT64_T)0 );
283 printf(
"Solved %2d outputs of frame %3d. ",
303 else if ( status ==
l_True )
Aig_Obj_t * Aig_ObjCreateCo(Aig_Man_t *p, Aig_Obj_t *pDriver)
static int Saig_ManPoNum(Aig_Man_t *p)
ABC_NAMESPACE_IMPL_START Aig_Man_t * Saig_ManFramesBmc(Aig_Man_t *pAig, int nFrames)
DECLARATIONS ///.
Cnf_Dat_t * Cnf_Derive(Aig_Man_t *pAig, int nOutputs)
typedefABC_NAMESPACE_HEADER_START struct Aig_Man_t_ Aig_Man_t
INCLUDES ///.
int sat_solver_addclause(sat_solver *s, lit *begin, lit *end)
typedefABC_NAMESPACE_IMPL_START struct Vec_Int_t_ Vec_Int_t
DECLARATIONS ///.
void Aig_ManStop(Aig_Man_t *p)
static int Aig_ObjIsTravIdCurrent(Aig_Man_t *p, Aig_Obj_t *pObj)
#define Saig_ManForEachLiLo(p, pObjLi, pObjLo, i)
int sat_solver_solve(sat_solver *s, lit *begin, lit *end, ABC_INT64_T nConfLimit, ABC_INT64_T nInsLimit, ABC_INT64_T nConfLimitGlobal, ABC_INT64_T nInsLimitGlobal)
void sat_solver_delete(sat_solver *s)
static Aig_Obj_t * Aig_ObjFanin0(Aig_Obj_t *pObj)
Aig_Man_t * Aig_ManStart(int nNodesMax)
DECLARATIONS ///.
Aig_Obj_t * Aig_ObjCreateCi(Aig_Man_t *p)
DECLARATIONS ///.
static Aig_Obj_t * Aig_ManConst0(Aig_Man_t *p)
#define Aig_ManForEachCo(p, pObj, i)
Abc_Cex_t * Fra_SmlCopyCounterExample(Aig_Man_t *pAig, Aig_Man_t *pFrames, int *pModel)
static abctime Abc_Clock()
static Aig_Obj_t * Aig_ObjFanin1(Aig_Obj_t *pObj)
Aig_Man_t * Saig_ManFramesBmcLimit(Aig_Man_t *pAig, int nFrames, int nSizeMax)
static void Aig_ObjSetTravIdCurrent(Aig_Man_t *p, Aig_Obj_t *pObj)
ABC_NAMESPACE_IMPL_START Aig_Man_t * Dar_ManRwsat(Aig_Man_t *pAig, int fBalance, int fVerbose)
DECLARATIONS ///.
static int Aig_ManNodeNum(Aig_Man_t *p)
Aig_Obj_t * Aig_And(Aig_Man_t *p, Aig_Obj_t *p0, Aig_Obj_t *p1)
void Aig_ManIncrementTravId(Aig_Man_t *p)
DECLARATIONS ///.
static int Aig_ObjIsNode(Aig_Obj_t *pObj)
static int Aig_ManCoNum(Aig_Man_t *p)
#define Aig_ManForEachNode(p, pObj, i)
#define Saig_ManForEachLi(p, pObj, i)
Vec_Int_t * Cnf_DataCollectPiSatNums(Cnf_Dat_t *pCnf, Aig_Man_t *p)
static lit toLitCond(int v, int c)
void sat_solver_setnvars(sat_solver *s, int n)
static int Aig_ManCiNum(Aig_Man_t *p)
#define ABC_NAMESPACE_IMPL_END
static Aig_Obj_t * Aig_ObjChild1Copy(Aig_Obj_t *pObj)
#define Saig_ManForEachLo(p, pObj, i)
static Aig_Obj_t * Aig_ObjChild0Copy(Aig_Obj_t *pObj)
static int Saig_ManRegNum(Aig_Man_t *p)
int Saig_ManFramesCount_rec(Aig_Man_t *p, Aig_Obj_t *pObj)
static Aig_Obj_t * Aig_ManConst1(Aig_Man_t *p)
#define ABC_NAMESPACE_IMPL_START
int Aig_ManLevelNum(Aig_Man_t *p)
int sat_solver_simplify(sat_solver *s)
sat_solver * sat_solver_new(void)
ABC_NAMESPACE_IMPL_END ABC_NAMESPACE_IMPL_START int Saig_ManBmcSimple(Aig_Man_t *pAig, int nFrames, int nSizeMax, int nConfLimit, int fRewrite, int fVerbose, int *piFrame, int nCofFanLit)
Aig_Man_t * Gia_ManCofactorAig(Aig_Man_t *p, int nFrames, int nCofFanLit)
static int Saig_ManPiNum(Aig_Man_t *p)
MACRO DEFINITIONS ///.
void Cnf_DataFree(Cnf_Dat_t *p)
#define Saig_ManForEachPo(p, pObj, i)
static void Vec_IntFree(Vec_Int_t *p)
int Aig_ManCleanup(Aig_Man_t *p)
int * Sat_SolverGetModel(sat_solver *p, int *pVars, int nVars)
#define Saig_ManForEachPi(p, pObj, i)