/**Function************************************************************* Synopsis [Gives the current ABC network to AIG manager for processing.] Description [] SideEffects [] SeeAlso [] ***********************************************************************/ Abc_Ntk_t * Abc_NtkIvyHaig( Abc_Ntk_t * pNtk, int nIters, int fUseZeroCost, int fVerbose ) { Abc_Ntk_t * pNtkAig; Ivy_Man_t * pMan; int clk; // int i; /* extern int nMoves; extern int nMovesS; extern int nClauses; extern int timeInv; nMoves = 0; nMovesS = 0; nClauses = 0; timeInv = 0; */ pMan = Abc_NtkIvyBefore( pNtk, 1, 1 ); if ( pMan == NULL ) return NULL; //timeRetime = clock(); clk = clock(); Ivy_ManHaigStart( pMan, fVerbose ); // Ivy_ManRewriteSeq( pMan, 0, 0 ); // for ( i = 0; i < nIters; i++ ) // Ivy_ManRewriteSeq( pMan, fUseZeroCost, 0 ); //printf( "%d ", Ivy_ManNodeNum(pMan) ); Ivy_ManRewriteSeq( pMan, 0, 0 ); Ivy_ManRewriteSeq( pMan, 0, 0 ); Ivy_ManRewriteSeq( pMan, 1, 0 ); //printf( "%d ", Ivy_ManNodeNum(pMan) ); //printf( "%d ", Ivy_ManNodeNum(pMan->pHaig) ); //PRT( " ", clock() - clk ); //printf( "\n" ); /* printf( "Moves = %d. ", nMoves ); printf( "MovesS = %d. ", nMovesS ); printf( "Clauses = %d. ", nClauses ); PRT( "Time", timeInv ); */ // Ivy_ManRewriteSeq( pMan, 1, 0 ); //printf( "Haig size = %d.\n", Ivy_ManNodeNum(pMan->pHaig) ); // Ivy_ManHaigPostprocess( pMan, fVerbose ); //timeRetime = clock() - timeRetime; // write working AIG into the current network // pNtkAig = Abc_NtkIvyAfter( pNtk, pMan, 1, 0 ); // write HAIG into the current network pNtkAig = Abc_NtkIvyAfter( pNtk, pMan->pHaig, 1, 1 ); Ivy_ManHaigStop( pMan ); Ivy_ManStop( pMan ); return pNtkAig; }
/**Function************************************************************* Synopsis [Gives the current ABC network to AIG manager for processing.] Description [] SideEffects [] SeeAlso [] ***********************************************************************/ Abc_Ntk_t * Abc_NtkIvyStrash( Abc_Ntk_t * pNtk ) { Abc_Ntk_t * pNtkAig; Ivy_Man_t * pMan; pMan = Abc_NtkIvyBefore( pNtk, 1, 0 ); if ( pMan == NULL ) return NULL; pNtkAig = Abc_NtkIvyAfter( pNtk, pMan, 1, 0 ); Ivy_ManStop( pMan ); return pNtkAig; }
/**Function************************************************************* Synopsis [Gives the current ABC network to AIG manager for processing.] Description [] SideEffects [] SeeAlso [] ***********************************************************************/ Abc_Ntk_t * Abc_NtkIvyResyn( Abc_Ntk_t * pNtk, int fUpdateLevel, int fVerbose ) { Abc_Ntk_t * pNtkAig; Ivy_Man_t * pMan, * pTemp; pMan = Abc_NtkIvyBefore( pNtk, 0, 0 ); if ( pMan == NULL ) return NULL; pMan = Ivy_ManResyn( pTemp = pMan, fUpdateLevel, fVerbose ); Ivy_ManStop( pTemp ); pNtkAig = Abc_NtkIvyAfter( pNtk, pMan, 0, 0 ); Ivy_ManStop( pMan ); return pNtkAig; }
/**Function************************************************************* Synopsis [Gives the current ABC network to AIG manager for processing.] Description [] SideEffects [] SeeAlso [] ***********************************************************************/ Abc_Ntk_t * Abc_NtkIvyRewrite( Abc_Ntk_t * pNtk, int fUpdateLevel, int fUseZeroCost, int fVerbose ) { Abc_Ntk_t * pNtkAig; Ivy_Man_t * pMan; pMan = Abc_NtkIvyBefore( pNtk, 0, 0 ); if ( pMan == NULL ) return NULL; //timeRetime = clock(); Ivy_ManRewritePre( pMan, fUpdateLevel, fUseZeroCost, fVerbose ); //timeRetime = clock() - timeRetime; pNtkAig = Abc_NtkIvyAfter( pNtk, pMan, 0, 0 ); Ivy_ManStop( pMan ); return pNtkAig; }
/**Function************************************************************* Synopsis [Gives the current ABC network to AIG manager for processing.] Description [] SideEffects [] SeeAlso [] ***********************************************************************/ Abc_Ntk_t * Abc_NtkIvyRewriteSeq( Abc_Ntk_t * pNtk, int fUseZeroCost, int fVerbose ) { Abc_Ntk_t * pNtkAig; Ivy_Man_t * pMan; pMan = Abc_NtkIvyBefore( pNtk, 1, 1 ); if ( pMan == NULL ) return NULL; //timeRetime = Abc_Clock(); Ivy_ManRewriteSeq( pMan, fUseZeroCost, fVerbose ); //timeRetime = Abc_Clock() - timeRetime; // Ivy_ManRewriteSeq( pMan, 1, 0 ); // Ivy_ManRewriteSeq( pMan, 1, 0 ); pNtkAig = Abc_NtkIvyAfter( pNtk, pMan, 1, 0 ); Ivy_ManStop( pMan ); return pNtkAig; }
/**Function************************************************************* Synopsis [Gives the current ABC network to AIG manager for processing.] Description [] SideEffects [] SeeAlso [] ***********************************************************************/ Abc_Ntk_t * Abc_NtkIvySat( Abc_Ntk_t * pNtk, int nConfLimit, int fVerbose ) { Ivy_FraigParams_t Params, * pParams = &Params; Abc_Ntk_t * pNtkAig; Ivy_Man_t * pMan, * pTemp; pMan = Abc_NtkIvyBefore( pNtk, 0, 0 ); if ( pMan == NULL ) return NULL; Ivy_FraigParamsDefault( pParams ); pParams->nBTLimitMiter = nConfLimit; pParams->fVerbose = fVerbose; // pMan = Ivy_FraigPerform( pTemp = pMan, pParams ); pMan = Ivy_FraigMiter( pTemp = pMan, pParams ); Ivy_ManStop( pTemp ); pNtkAig = Abc_NtkIvyAfter( pNtk, pMan, 0, 0 ); Ivy_ManStop( pMan ); return pNtkAig; }