472{
475 int i, iOut, iPat;
476 clock_t clk, clkTotal = clock(), clk2, clk2Total = 0;
477 assert( Aig_ManRegNum(pAig) > 0 );
479 {
482 {
483 printf(
"Miter is trivially satisfiable (output %d).\n",
Status.iOut );
484 return 1;
485 }
487 {
488 printf( "Miter is trivially unsatisfiable.\n" );
489 return 0;
490 }
491 }
492
493 clk = clock();
497 {
498 printf( "Obj = %8d (%8d). Cut = %6d. Front = %6d. FrtMem = %7.2f MB. ",
499 p->nObjs,
p->nCis +
p->nNodes,
p->nCrossCutMax,
p->nFront,
500 4.0*
p->nWords*(
p->nFront)/(1<<20) );
501 ABC_PRT(
"Time", clock() - clk );
502 }
503
504 clk = clock();
507 {
508 printf( "Max ID = %8d. Log max ID = %2d. AigMem = %7.2f MB (%5.2f byte/obj). ",
509 p->iNumber, Aig_Base2Log(
p->iNumber),
510 1.0*(
p->pDataCur-
p->pDataAig)/(1<<20),
511 1.0*(
p->pDataCur-
p->pDataAig)/
p->nObjs );
512 ABC_PRT(
"Time", clock() - clk );
513 }
514
517 p->pDataSim =
ABC_ALLOC(
unsigned,
p->nWords *
p->nFront );
518 p->pDataSimCis =
ABC_ALLOC(
unsigned,
p->nWords *
p->nCis );
519 p->pDataSimCos =
ABC_ALLOC(
unsigned,
p->nWords *
p->nCos );
520 Fsim_ManSimInfoInit(
p );
521 for ( i = 0; i < pPars->
nIters; i++ )
522 {
523 Fsim_ManSimulateRound(
p );
525 {
526 printf(
"Frame %4d out of %4d and timeout %3d sec. ", i+1, pPars->
nIters, pPars->
TimeLimit );
527 printf( "Time = %7.2f sec\r", (1.0*clock()-clkTotal)/CLOCKS_PER_SEC );
528 }
529 if ( pPars->
fCheckMiter && Fsim_ManCheckPos(
p, &iOut, &iPat ) )
530 {
531 assert( pAig->pSeqModel == NULL );
534 printf( "Miter is satisfiable after simulation (output %d).\n", iOut );
535 break;
536 }
537 if ( (clock() - clkTotal)/CLOCKS_PER_SEC >= pPars->
TimeLimit )
538 break;
539 clk2 = clock();
540 if ( i < pPars->nIters - 1 )
541 Fsim_ManSimInfoTransfer(
p );
542 clk2Total += clock() - clk2;
543 }
544 if ( pAig->pSeqModel == NULL )
545 printf(
"No bug detected after %d frames with time limit %d seconds.\n", i+1, pPars->
TimeLimit );
547 {
548 printf( "Maxcut = %8d. AigMem = %7.2f MB. SimMem = %7.2f MB. ",
550 p->pDataAig2? 12.0*
p->nObjs/(1<<20) : 1.0*(
p->pDataCur-
p->pDataAig)/(1<<20),
551 4.0*
p->nWords*(
p->nFront+
p->nCis+
p->nCos)/(1<<20) );
552 ABC_PRT(
"Sim time", clock() - clkTotal );
553
554
555
556
557 }
559 return pAig->pSeqModel != NULL;
560
561}
void Fsim_ManFront(Fsim_Man_t *p, int fCompressAig)
FUNCTION DECLARATIONS ///.
void Fsim_ManDelete(Fsim_Man_t *p)
Fsim_Man_t * Fsim_ManCreate(Aig_Man_t *pAig)
Abc_Cex_t * Fsim_ManGenerateCounter(Aig_Man_t *pAig, int iFrame, int iOut, int nWords, int iPat, Vec_Int_t *vCis2Ids)
typedefABC_NAMESPACE_HEADER_START struct Fsim_Man_t_ Fsim_Man_t
INCLUDES ///.
Sec_MtrStatus_t Sec_MiterStatus(Aig_Man_t *p)
DECLARATIONS ///.
typedefABC_NAMESPACE_HEADER_START struct Sec_MtrStatus_t_ Sec_MtrStatus_t
INCLUDES ///.