summaryrefslogtreecommitdiffstats
path: root/src/opt/sfm/sfmWin.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/opt/sfm/sfmWin.c')
-rw-r--r--src/opt/sfm/sfmWin.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/src/opt/sfm/sfmWin.c b/src/opt/sfm/sfmWin.c
index f12474c9..fa0b484b 100644
--- a/src/opt/sfm/sfmWin.c
+++ b/src/opt/sfm/sfmWin.c
@@ -214,8 +214,7 @@ void Sfm_NtkAddDivisors( Sfm_Ntk_t * p, int iNode, int nLevelMax )
if ( p->pPars->nFanoutMax && i > p->pPars->nFanoutMax )
return;
// skip TFI nodes, PO nodes, or nodes with high logic level
- if ( Sfm_ObjIsTravIdCurrent(p, iFanout) || Sfm_ObjIsPo(p, iFanout) ||
- (p->pPars->fFixLevel && Sfm_ObjLevel(p, iFanout) > nLevelMax) )
+ if ( Sfm_ObjIsTravIdCurrent(p, iFanout) || Sfm_ObjIsPo(p, iFanout) || Sfm_ObjLevel(p, iFanout) > nLevelMax )
continue;
// handle single-input nodes
if ( Sfm_ObjFaninNum(p, iFanout) == 1 )
@@ -362,6 +361,15 @@ int Sfm_NtkCreateWindow( Sfm_Ntk_t * p, int iNode, int fVerbose )
break;
}
if ( Vec_IntSize(p->vRoots) > 0 )
+ Vec_IntForEachEntry( p->vTfo, iTemp, i )
+ if ( Sfm_NtkCollectTfi_rec( p, iTemp, p->vOrder ) )
+ {
+ Vec_IntClear( p->vRoots );
+ Vec_IntClear( p->vTfo );
+ Vec_IntClear( p->vOrder );
+ break;
+ }
+ if ( Vec_IntSize(p->vRoots) > 0 )
Vec_IntForEachEntry( p->vDivs, iTemp, i )
if ( Sfm_NtkCollectTfi_rec( p, iTemp, p->vOrder ) )
{