mirror of https://github.com/YosysHQ/abc.git
Enabling ACD for area
This commit is contained in:
parent
8aa57c5d54
commit
b77bdeeb17
|
|
@ -570,7 +570,7 @@ extern int If_CutSopBalancePinDelaysInt( Vec_Int_t * vCover, int * p
|
|||
extern int If_CutSopBalancePinDelays( If_Man_t * p, If_Cut_t * pCut, char * pPerm );
|
||||
extern int If_CutLutBalanceEval( If_Man_t * p, If_Cut_t * pCut );
|
||||
extern int If_CutLutBalancePinDelays( If_Man_t * p, If_Cut_t * pCut, char * pPerm );
|
||||
extern int If_AcdEval( If_Man_t * p, If_Cut_t * pCut, int best_delay );
|
||||
extern int If_AcdEval( If_Man_t * p, If_Cut_t * pCut, If_Obj_t * pObj, int optDelay );
|
||||
extern int If_AcdReEval( If_Man_t * p, If_Cut_t * pCut );
|
||||
extern float If_AcdLeafProp( If_Man_t * p, If_Cut_t * pCut, int i, float required );
|
||||
/*=== ifDsd.c =============================================================*/
|
||||
|
|
|
|||
|
|
@ -412,7 +412,7 @@ int If_CutLutBalanceEval( If_Man_t * p, If_Cut_t * pCut )
|
|||
}
|
||||
}
|
||||
|
||||
int If_AcdEval( If_Man_t * p, If_Cut_t * pCut, int best_delay )
|
||||
int If_AcdEval( If_Man_t * p, If_Cut_t * pCut, If_Obj_t * pObj, int optDelay )
|
||||
{
|
||||
pCut->fUser = 1;
|
||||
pCut->Cost = pCut->nLeaves > 1 ? 1 : 0;
|
||||
|
|
@ -460,20 +460,34 @@ int If_AcdEval( If_Man_t * p, If_Cut_t * pCut, int best_delay )
|
|||
// }
|
||||
|
||||
/* compute the decomposition */
|
||||
int use_late_arrival = DelayMax + 2 >= best_delay;
|
||||
int use_late_arrival;
|
||||
unsigned cost = 1;
|
||||
|
||||
/* TODO: have checks based on delay */
|
||||
if ( use_late_arrival && nLeafMax > LutSize / 2 )
|
||||
|
||||
if ( optDelay )
|
||||
{
|
||||
pCut->Cost = IF_COST_MAX;
|
||||
return ABC_INFINITY;
|
||||
/* checks based on delay: must be better than the previous best cut */
|
||||
use_late_arrival = DelayMax + 2 >= If_ObjCutBest(pObj)->Delay;
|
||||
}
|
||||
|
||||
/* remove from critical set */
|
||||
if ( !use_late_arrival && nLeafMax > LutSize / 2 )
|
||||
else
|
||||
{
|
||||
uLeafMask = 0;
|
||||
/* checks based on delay: look at the required time */
|
||||
use_late_arrival = DelayMax + 2 > pObj->Required + p->fEpsilon;
|
||||
}
|
||||
|
||||
/* Too many late-arriving signals */
|
||||
if ( nLeafMax > LutSize / 2 )
|
||||
{
|
||||
if ( use_late_arrival )
|
||||
{
|
||||
/* unfeasible decomposition */
|
||||
pCut->Cost = IF_COST_MAX;
|
||||
return ABC_INFINITY;
|
||||
}
|
||||
else
|
||||
{
|
||||
/* remove critical signals as not needed */
|
||||
uLeafMask = 0;
|
||||
}
|
||||
}
|
||||
|
||||
word *pTruth = If_CutTruthW( p, pCut );
|
||||
|
|
|
|||
|
|
@ -431,7 +431,7 @@ void If_ObjPerformMappingAnd( If_Man_t * p, If_Obj_t * pObj, int Mode, int fPrep
|
|||
pCut->Delay = If_CutDelayRecCost3( p, pCut, pObj );
|
||||
else if ( p->pPars->fAcd )
|
||||
{
|
||||
pCut->Delay = If_AcdEval( p, pCut, fFirst ? ABC_INFINITY : (int) If_ObjCutBest(pObj)->Delay );
|
||||
pCut->Delay = If_AcdEval( p, pCut, pObj, Mode == 0 );
|
||||
pCut->fUseless = pCut->Delay == ABC_INFINITY;
|
||||
}
|
||||
else if ( p->pPars->fUserSesLib )
|
||||
|
|
|
|||
Loading…
Reference in New Issue