mirror of https://github.com/YosysHQ/abc.git
Merge pull request #31 from davidar/fix-55
Fix Assertion using &if: `pCutSet->nCuts > 0'
This commit is contained in:
commit
078afe9faa
|
|
@ -444,7 +444,7 @@ void If_ObjPerformMappingAnd( If_Man_t * p, If_Obj_t * pObj, int Mode, int fPrep
|
||||||
pCut->Delay = If_CutDelay( p, pObj, pCut );
|
pCut->Delay = If_CutDelay( p, pObj, pCut );
|
||||||
if ( pCut->Delay == -1 )
|
if ( pCut->Delay == -1 )
|
||||||
continue;
|
continue;
|
||||||
if ( Mode && pCut->Delay > pObj->Required + p->fEpsilon )
|
if ( Mode && pCut->Delay > pObj->Required + p->fEpsilon && pCutSet->nCuts > 0 )
|
||||||
continue;
|
continue;
|
||||||
// compute area of the cut (this area may depend on the application specific cost)
|
// compute area of the cut (this area may depend on the application specific cost)
|
||||||
pCut->Area = (Mode == 2)? If_CutAreaDerefed( p, pCut ) : If_CutAreaFlow( p, pCut );
|
pCut->Area = (Mode == 2)? If_CutAreaDerefed( p, pCut ) : If_CutAreaFlow( p, pCut );
|
||||||
|
|
@ -542,7 +542,7 @@ void If_ObjPerformMappingChoice( If_Man_t * p, If_Obj_t * pObj, int Mode, int fP
|
||||||
continue;
|
continue;
|
||||||
// check if the cut satisfies the required times
|
// check if the cut satisfies the required times
|
||||||
// assert( pCut->Delay == If_CutDelay( p, pTemp, pCut ) );
|
// assert( pCut->Delay == If_CutDelay( p, pTemp, pCut ) );
|
||||||
if ( Mode && pCut->Delay > pObj->Required + p->fEpsilon )
|
if ( Mode && pCut->Delay > pObj->Required + p->fEpsilon && pCutSet->nCuts > 0 )
|
||||||
continue;
|
continue;
|
||||||
// set the phase attribute
|
// set the phase attribute
|
||||||
pCut->fCompl = pObj->fPhase ^ pTemp->fPhase;
|
pCut->fCompl = pObj->fPhase ^ pTemp->fPhase;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue