mirror of https://github.com/YosysHQ/abc.git
update reverse level when co is replaced
This commit is contained in:
parent
766f64e221
commit
3daecc0ea8
|
|
@ -897,6 +897,16 @@ void Abc_AigReplace_int( Abc_Aig_t * pMan, Abc_Obj_t * pOld, Abc_Obj_t * pNew, i
|
||||||
{
|
{
|
||||||
if ( Abc_ObjIsCo(pFanout) )
|
if ( Abc_ObjIsCo(pFanout) )
|
||||||
{
|
{
|
||||||
|
pFanin1 = Abc_ObjRegular( pNew );
|
||||||
|
if ( pFanin1->fMarkB )
|
||||||
|
Abc_AigRemoveFromLevelStructureR( pMan->vLevelsR, pFanin1 );
|
||||||
|
if ( fUpdateLevel && pMan->pNtkAig->vLevelsR )
|
||||||
|
{
|
||||||
|
Abc_ObjSetReverseLevel( pFanin1, Abc_ObjReverseLevel(pOld) );
|
||||||
|
assert( pFanin1->fMarkB == 0 );
|
||||||
|
pFanin1->fMarkB = 1;
|
||||||
|
Vec_VecPush( pMan->vLevelsR, Abc_ObjReverseLevel(pFanin1), pFanin1 );
|
||||||
|
}
|
||||||
Abc_ObjPatchFanin( pFanout, pOld, pNew );
|
Abc_ObjPatchFanin( pFanout, pOld, pNew );
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue