diff options
Diffstat (limited to 'src/aig/ntl/ntlAig.c')
-rw-r--r-- | src/aig/ntl/ntlAig.c | 30 |
1 files changed, 27 insertions, 3 deletions
diff --git a/src/aig/ntl/ntlAig.c b/src/aig/ntl/ntlAig.c index c81280d7..c0a122d3 100644 --- a/src/aig/ntl/ntlAig.c +++ b/src/aig/ntl/ntlAig.c @@ -367,7 +367,7 @@ Aig_Obj_t * Ntl_ManExtractAigNode( Ntl_Obj_t * pNode ) SeeAlso [] ***********************************************************************/ -int Ntl_ManExtract( Ntl_Man_t * p ) +int Ntl_ManExtract_old( Ntl_Man_t * p ) { Ntl_Obj_t * pNode; Ntl_Net_t * pNet; @@ -394,6 +394,30 @@ int Ntl_ManExtract( Ntl_Man_t * p ) /**Function************************************************************* + Synopsis [Extracts AIG from the netlist.] + + Description [] + + SideEffects [] + + SeeAlso [] + +***********************************************************************/ +int Ntl_ManExtract( Ntl_Man_t * p ) +{ + // start the AIG manager + assert( p->pAig == NULL ); + p->pAig = Aig_ManStart( 10000 ); + // check the DFS traversal + if ( !Ntl_ManDfs( p ) ) + return 0; + // cleanup the AIG + Aig_ManCleanup( p->pAig ); + return 1; +} + +/**Function************************************************************* + Synopsis [Inserts the given mapping into the netlist.] Description [] @@ -557,8 +581,8 @@ int Ntl_ManInsertTestIf( Ntl_Man_t * p ) if ( !Ntl_ManExtract( p ) ) return 0; assert( p->pAig != NULL ); - Ntl_ManPerformSynthesis( p ); - vMapping = Ntl_MappingIf( p->pAig ); +// Ntl_ManPerformSynthesis( p ); + vMapping = Ntl_MappingIf( p, p->pAig ); RetValue = Ntl_ManInsert( p, vMapping ); Vec_PtrFree( vMapping ); return RetValue; |