Commit a3bc77cd by Alan Mishchenko

Making 'fold' and 'unfold' skip constant POs.

parent 08bb54f3
...@@ -283,6 +283,8 @@ Aig_Man_t * Saig_ManDupUnfoldConstrs( Aig_Man_t * pAig ) ...@@ -283,6 +283,8 @@ Aig_Man_t * Saig_ManDupUnfoldConstrs( Aig_Man_t * pAig )
vConsAll = Vec_PtrAlloc( Saig_ManPoNum(pAig) ); vConsAll = Vec_PtrAlloc( Saig_ManPoNum(pAig) );
Saig_ManForEachPo( pAig, pObj, i ) Saig_ManForEachPo( pAig, pObj, i )
{ {
if ( Aig_ObjFanin0(pObj) == Aig_ManConst1(pAig) )
continue;
RetValue = Saig_ManDetectConstr( pAig, i, &vOuts, &vCons ); RetValue = Saig_ManDetectConstr( pAig, i, &vOuts, &vCons );
if ( RetValue == 0 ) if ( RetValue == 0 )
{ {
...@@ -392,6 +394,8 @@ Aig_Man_t * Saig_ManDupFoldConstrs( Aig_Man_t * pAig, Vec_Int_t * vConstrs ) ...@@ -392,6 +394,8 @@ Aig_Man_t * Saig_ManDupFoldConstrs( Aig_Man_t * pAig, Vec_Int_t * vConstrs )
// create primary output // create primary output
Saig_ManForEachPo( pAig, pObj, i ) Saig_ManForEachPo( pAig, pObj, i )
{ {
if ( Aig_ObjFanin0(pObj) == Aig_ManConst1(pAig) )
continue;
pMiter = Aig_And( pAigNew, Aig_ObjChild0Copy(pObj), Aig_Not(pFlopIn) ); pMiter = Aig_And( pAigNew, Aig_ObjChild0Copy(pObj), Aig_Not(pFlopIn) );
Aig_ObjCreateCo( pAigNew, pMiter ); Aig_ObjCreateCo( pAigNew, pMiter );
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment