Commit 89cab3ad by Alan Mishchenko

Normalization of slew/load values.

parent c6b80ffc
......@@ -327,7 +327,7 @@ void Abc_SclOneNodePrint( Bus_Man_t * p, Abc_Obj_t * pObj )
printf( "%12s ", pCell->pName );
printf( "(%2d/%2d) ", pCell->Order, pCell->nGates );
printf( "gain =%5d ", (int)(100.0 * Bus_SclObjLoad(pObj) / SC_CellPinCapAve(pCell)) );
printf( "dept =%7.0f ps ", SC_LibTimePs(p->pLib, Bus_SclObjDept(pObj)) );
printf( "dept =%7.0f ps ", Bus_SclObjDept(pObj) );
printf( "\n" );
}
Abc_Obj_t * Abc_SclAddOneInv( Bus_Man_t * p, Abc_Obj_t * pObj, Vec_Ptr_t * vFanouts, float Gain )
......@@ -475,7 +475,7 @@ void Abc_SclBufSize( Bus_Man_t * p )
{
printf( "WireLoads = %d. Degree = %d. Target gain =%5d Slew =%5d Buf = %6d Delay =%7.0f ps ",
p->pPars->fUseWireLoads, p->pPars->nDegree, p->pPars->GainRatio, p->pPars->Slew,
Abc_NtkObjNumMax(p->pNtk) - nObjOld, SC_LibTimePs(p->pLib, DeptMax) );
Abc_NtkObjNumMax(p->pNtk) - nObjOld, DeptMax );
Abc_PrintTime( 1, "Time", Abc_Clock() - clk );
}
}
......
......@@ -115,7 +115,7 @@ clk = Abc_Clock();
Abc_SclLoadStore( p, pObj );
// try different gate sizes for this node
gateBest = -1;
dGainBest = -SC_LibTimeFromPs(p->pLib, (float)DelayGap);
dGainBest = -DelayGap;
SC_RingForEachCellRev( pCellOld, pCellNew, i )
{
if ( pCellNew->area >= pCellOld->area )
......@@ -224,7 +224,7 @@ void Abc_SclDnsizePrint( SC_Man * p, int Iter, int nAttempts, int nOverlaps, int
printf( "%.2f ", p->SumArea );
printf( "(%+5.1f %%) ", 100.0 * (p->SumArea - p->SumArea0)/ p->SumArea0 );
printf( "D: " );
printf( "%.2f ps ", SC_LibTimePs(p->pLib, p->MaxDelay) );
printf( "%.2f ps ", p->MaxDelay );
printf( "(%+5.1f %%) ", 100.0 * (p->MaxDelay - p->MaxDelay0)/ p->MaxDelay0 );
printf( "%8.2f sec ", 1.0*(Abc_Clock() - p->timeTotal)/(CLOCKS_PER_SEC) );
printf( "%c", fVerbose ? '\n' : '\r' );
......@@ -262,7 +262,7 @@ void Abc_SclDnsizePerform( SC_Lib * pLib, Abc_Ntk_t * pNtk, SC_SizePars * pPars
}
// prepare the manager; collect init stats
p = Abc_SclManStart( pLib, pNtk, pPars->fUseWireLoads, pPars->fUseDept, SC_LibTimeFromPs(pLib, pPars->DelayUser), pPars->BuffTreeEst );
p = Abc_SclManStart( pLib, pNtk, pPars->fUseWireLoads, pPars->fUseDept, pPars->DelayUser, pPars->BuffTreeEst );
p->timeTotal = Abc_Clock();
assert( p->vGatesBest == NULL );
p->vGatesBest = Vec_IntDup( p->pNtk->vGates );
......
......@@ -243,11 +243,6 @@ static inline float SC_CellPinCapAve( SC_Cell * p ) { int i; flo
static inline char * SC_CellPinOutFunc( SC_Cell * p, int i ) { return SC_CellPin(p, p->n_inputs + i)->func_text; }
static inline char * SC_CellPinName( SC_Cell * p, int i ) { return SC_CellPin(p, i)->pName; }
static inline double SC_LibCapFf( SC_Lib * p, double cap ) { return cap * p->unit_cap_fst * pow(10.0, 15 - p->unit_cap_snd); }
static inline double SC_LibCapFromFf( SC_Lib * p, double cap ) { return cap / p->unit_cap_fst / pow(10.0, 15 - p->unit_cap_snd); }
static inline double SC_LibTimePs( SC_Lib * p, double time ) { return time * pow(10.0, 12 - p->unit_time); }
static inline double SC_LibTimeFromPs( SC_Lib * p, double ps ) { return ps / pow(10.0, 12 - p->unit_time); }
#define SC_LibForEachCell( p, pCell, i ) Vec_PtrForEachEntry( SC_Cell *, p->vCells, pCell, i )
#define SC_LibForEachCellClass( p, pCell, i ) Vec_PtrForEachEntry( SC_Cell *, p->vCellClasses, pCell, i )
#define SC_LibForEachWireLoad( p, pWL, i ) Vec_PtrForEachEntry( SC_WireLoad *, p->vWireLoads, pWL, i )
......
......@@ -492,9 +492,9 @@ void Abc_SclPrintCells( SC_Lib * p, float Slew, float Gain, int fInvOnly, int fS
printf( "D =%6.1f ps ", 0.01 * Gain * LD + PD );
printf( "LD =%6.1f ps ", LD );
printf( "PD =%6.1f ps ", PD );
printf( "C =%5.1f ff ", SC_LibCapFf(p, SC_CellPinCapAve(pCell)) );
printf( "Cm =%5.0f ff ", SC_LibCapFf(p, SC_CellPin(pCell, pCell->n_inputs)->max_out_cap) );
printf( "Sm =%5.1f ps ", SC_LibTimePs(p, SC_CellPin(pCell, pCell->n_inputs)->max_out_slew) );
printf( "C =%5.1f ff ", SC_CellPinCapAve(pCell) );
printf( "Cm =%5.0f ff ", SC_CellPin(pCell, pCell->n_inputs)->max_out_cap );
printf( "Sm =%5.1f ps ", SC_CellPin(pCell, pCell->n_inputs)->max_out_slew );
}
printf( "\n" );
}
......
......@@ -119,9 +119,9 @@ static inline void Abc_SclTimeNodePrint( SC_Man * p, Abc_Obj_t * pObj, int fRise
printf( "%6.1f", Abc_MaxFloat(Abc_SclObjTimePs(p, pObj, 0), Abc_SclObjTimePs(p, pObj, 1)) );
printf( "%7.1f ps ", -Abc_AbsFloat(Abc_SclObjTimePs(p, pObj, 0) - Abc_SclObjTimePs(p, pObj, 1)) );
printf( "S =%6.1f ps ", Abc_SclObjSlewPs(p, pObj, fRise >= 0 ? fRise : 0) );
printf( "Cin =%5.1f ff ", pCell ? SC_LibCapFf(p->pLib, SC_CellPinCapAve(pCell)) : 0.0 );
printf( "Cin =%5.1f ff ", pCell ? SC_CellPinCapAve(pCell) : 0.0 );
printf( "Cout =%6.1f ff ", Abc_SclObjLoadFf(p, pObj, fRise >= 0 ? fRise : 0) );
printf( "Cmax =%6.1f ff ", pCell ? SC_LibCapFf(p->pLib, SC_CellPin(pCell, pCell->n_inputs)->max_out_cap) : 0.0 );
printf( "Cmax =%6.1f ff ", pCell ? SC_CellPin(pCell, pCell->n_inputs)->max_out_cap : 0.0 );
printf( "G =%5d ", pCell ? (int)(100.0 * Abc_SclObjLoadAve(p, pObj) / SC_CellPinCapAve(pCell)) : 0 );
// printf( "SL =%6.1f ps", Abc_SclObjSlackPs(p, pObj, p->MaxDelay0) );
printf( "\n" );
......@@ -136,7 +136,7 @@ void Abc_SclTimeNtkPrint( SC_Man * p, int fShowAll, int fPrintPath )
printf( "WireLoad = \"%s\" ", p->pWLoadUsed ? p->pWLoadUsed->pName : "none" );
printf( "Gates =%7d ", Abc_NtkNodeNum(p->pNtk) );
printf( "(%5.1f %%) ", 100.0 * Abc_SclGetBufInvCount(p->pNtk) / Abc_NtkNodeNum(p->pNtk) );
printf( "Cap =%5.1f ff ", SC_LibCapFf(p->pLib, p->EstLoadAve) );
printf( "Cap =%5.1f ff ", p->EstLoadAve );
printf( "(%5.1f %%) ", Abc_SclGetAverageSize(p->pNtk) );
printf( "Area =%12.2f ", Abc_SclGetTotalArea(p->pNtk) );
printf( "(%5.1f %%) ", 100.0 * Abc_SclCountMinSize(p->pLib, p->pNtk, 0) / Abc_NtkNodeNum(p->pNtk) );
......@@ -522,18 +522,15 @@ void Abc_SclTimeIncUpdateLevel( Abc_Obj_t * pObj )
***********************************************************************/
void Abc_SclManReadSlewAndLoad( SC_Man * p, Abc_Ntk_t * pNtk )
{
Abc_Time_t * pTime;
Abc_Obj_t * pObj;
int i;
if ( Abc_FrameReadMaxLoad() )
{
Abc_Obj_t * pObj; int i;
float MaxLoad = Abc_FrameReadMaxLoad();
// printf( "Default output load is specified (%f ff).\n", SC_LibCapFf(p->pLib, MaxLoad) );
// printf( "Default output load is specified (%.2f ff).\n", MaxLoad );
Abc_NtkForEachPo( pNtk, pObj, i )
{
SC_Pair * pLoad = Abc_SclObjLoad( p, pObj );
pLoad->rise = SC_LibCapFromFf( p->pLib, MaxLoad );
pLoad->fall = SC_LibCapFromFf( p->pLib, MaxLoad );
pLoad->rise = pLoad->fall = MaxLoad;
}
}
if ( Abc_FrameReadDrivingCell() )
......@@ -549,76 +546,6 @@ void Abc_SclManReadSlewAndLoad( SC_Man * p, Abc_Ntk_t * pNtk )
assert( p->pPiDrive->n_inputs == 1 );
}
}
if ( pNtk->pManTime == NULL )
return;
/*
// read input slew
pTime = Abc_NtkReadDefaultInputDrive( pNtk );
if ( Abc_MaxFloat(pTime->Rise, pTime->Fall) != 0 )
{
printf( "Default input slew is specified (%.2f ps; %.2f ps).\n", pTime->Rise, pTime->Fall );
Abc_NtkForEachPi( pNtk, pObj, i )
{
SC_Pair * pSlew = Abc_SclObjSlew( p, pObj );
pSlew->rise = SC_LibTimeFromPs( p->pLib, pTime->Rise );
pSlew->fall = SC_LibTimeFromPs( p->pLib, pTime->Fall );
}
}
if ( Abc_NodeReadInputDrive(pNtk, 0) != NULL )
{
printf( "Input slews for some primary inputs are specified.\n" );
Abc_NtkForEachPi( pNtk, pObj, i )
{
SC_Pair * pSlew = Abc_SclObjSlew( p, pObj );
pTime = Abc_NodeReadInputDrive(pNtk, i);
pSlew->rise = SC_LibTimeFromPs( p->pLib, pTime->Rise );
pSlew->fall = SC_LibTimeFromPs( p->pLib, pTime->Fall );
}
}
*/
pTime = Abc_NtkReadDefaultInputDrive( pNtk );
if ( Abc_MaxFloat(pTime->Rise, pTime->Fall) != 0 )
{
printf( "Default input drive strength is specified (%.2f ff; %.2f ff).\n", pTime->Rise, pTime->Fall );
if ( p->vInDrive == NULL )
p->vInDrive = Vec_FltStart( Abc_NtkCiNum(pNtk) );
Abc_NtkForEachPi( pNtk, pObj, i )
Abc_SclObjSetInDrive( p, pObj, SC_LibCapFromFf( p->pLib, 0.5 * pTime->Rise + 0.5 * pTime->Fall ) );
}
if ( Abc_NodeReadInputDrive(pNtk, 0) != NULL )
{
printf( "Input drive strengths for some primary inputs are specified.\n" );
if ( p->vInDrive == NULL )
p->vInDrive = Vec_FltStart( Abc_NtkCiNum(pNtk) );
Abc_NtkForEachPi( pNtk, pObj, i )
{
pTime = Abc_NodeReadInputDrive(pNtk, i);
Abc_SclObjSetInDrive( p, pObj, SC_LibCapFromFf( p->pLib, 0.5 * pTime->Rise + 0.5 * pTime->Fall ) );
}
}
// read output load
pTime = Abc_NtkReadDefaultOutputLoad( pNtk );
if ( Abc_MaxFloat(pTime->Rise, pTime->Fall) != 0 )
{
printf( "Default output load is specified (%.2f ff; %.2f ff).\n", pTime->Rise, pTime->Fall );
Abc_NtkForEachPo( pNtk, pObj, i )
{
SC_Pair * pSlew = Abc_SclObjLoad( p, pObj );
pSlew->rise = SC_LibCapFromFf( p->pLib, pTime->Rise );
pSlew->fall = SC_LibCapFromFf( p->pLib, pTime->Fall );
}
}
if ( Abc_NodeReadOutputLoad(pNtk, 0) != NULL )
{
printf( "Output loads for some primary outputs are specified.\n" );
Abc_NtkForEachPo( pNtk, pObj, i )
{
SC_Pair * pSlew = Abc_SclObjLoad( p, pObj );
pTime = Abc_NodeReadOutputLoad(pNtk, i);
pSlew->rise = SC_LibCapFromFf( p->pLib, pTime->Rise );
pSlew->fall = SC_LibCapFromFf( p->pLib, pTime->Fall );
}
}
}
/**Function*************************************************************
......@@ -841,7 +768,7 @@ void Abc_SclPrintBuffersOne( SC_Man * p, Abc_Obj_t * pObj, int nOffset )
printf( "sl =%5.0f ps ", Abc_SclObjSlackPs(p, pObj, p->MaxDelay0) );
if ( nOffset == 0 )
{
printf( "L =%5.0f ff ", SC_LibCapFf( p->pLib, Abc_SclCountNonBufferLoad(p, pObj) ) );
printf( "L =%5.0f ff ", Abc_SclCountNonBufferLoad(p, pObj) );
printf( "Lx =%5.0f ff ", 100.0*Abc_SclCountNonBufferLoad(p, pObj)/p->EstLoadAve );
printf( "Dx =%5.0f ps ", Abc_SclCountNonBufferDelay(p, pObj)/Abc_SclCountNonBufferFanouts(pObj) - Abc_SclObjTimePs(p, pObj, 1) );
printf( "Cx =%5.0f ps", (Abc_SclCountNonBufferDelay(p, pObj)/Abc_SclCountNonBufferFanouts(pObj) - Abc_SclObjTimePs(p, pObj, 1))/log(Abc_SclCountNonBufferLoad(p, pObj)/p->EstLoadAve) );
......
......@@ -124,10 +124,10 @@ static inline void Abc_SclObjDupFanin( SC_Man * p, Abc_Obj_t * pObj )
static inline float Abc_SclObjInDrive( SC_Man * p, Abc_Obj_t * pObj ) { return Vec_FltEntry( p->vInDrive, pObj->iData ); }
static inline void Abc_SclObjSetInDrive( SC_Man * p, Abc_Obj_t * pObj, float c){ Vec_FltWriteEntry( p->vInDrive, pObj->iData, c ); }
static inline double Abc_SclObjLoadFf( SC_Man * p, Abc_Obj_t * pObj, int fRise ) { return SC_LibCapFf( p->pLib, fRise ? Abc_SclObjLoad(p, pObj)->rise : Abc_SclObjLoad(p, pObj)->fall); }
static inline double Abc_SclObjTimePs( SC_Man * p, Abc_Obj_t * pObj, int fRise ) { return SC_LibTimePs(p->pLib, fRise ? Abc_SclObjTime(p, pObj)->rise : Abc_SclObjTime(p, pObj)->fall); }
static inline double Abc_SclObjSlewPs( SC_Man * p, Abc_Obj_t * pObj, int fRise ) { return SC_LibTimePs(p->pLib, fRise ? Abc_SclObjSlew(p, pObj)->rise : Abc_SclObjSlew(p, pObj)->fall); }
static inline double Abc_SclObjSlackPs( SC_Man * p, Abc_Obj_t * pObj, float D ) { return SC_LibTimePs(p->pLib, Abc_SclObjGetSlack(p, pObj, D)); }
static inline double Abc_SclObjLoadFf( SC_Man * p, Abc_Obj_t * pObj, int fRise ) { return fRise ? Abc_SclObjLoad(p, pObj)->rise : Abc_SclObjLoad(p, pObj)->fall; }
static inline double Abc_SclObjTimePs( SC_Man * p, Abc_Obj_t * pObj, int fRise ) { return fRise ? Abc_SclObjTime(p, pObj)->rise : Abc_SclObjTime(p, pObj)->fall; }
static inline double Abc_SclObjSlewPs( SC_Man * p, Abc_Obj_t * pObj, int fRise ) { return fRise ? Abc_SclObjSlew(p, pObj)->rise : Abc_SclObjSlew(p, pObj)->fall; }
static inline double Abc_SclObjSlackPs( SC_Man * p, Abc_Obj_t * pObj, float D ) { return Abc_SclObjGetSlack(p, pObj, D); }
////////////////////////////////////////////////////////////////////////
/// FUNCTION DEFINITIONS ///
......@@ -149,6 +149,8 @@ static inline SC_Man * Abc_SclManAlloc( SC_Lib * pLib, Abc_Ntk_t * pNtk )
SC_Man * p;
Abc_Obj_t * pObj;
int i;
assert( pLib->unit_time == 12 );
assert( pLib->unit_cap_snd == 15 );
assert( Abc_NtkHasMapping(pNtk) );
p = ABC_CALLOC( SC_Man, 1 );
p->pLib = pLib;
......
......@@ -96,9 +96,9 @@ static inline void Scl_ObjDupFanin( SC_Time * p, int i, int iFanin ) {
static inline float Scl_ObjGain( SC_Time * p, int i ) { return 0.5*((Scl_ObjTime2(p, i)->rise - Scl_ObjTime(p, i)->rise) + (Scl_ObjTime2(p, i)->fall - Scl_ObjTime(p, i)->fall)); }
static inline int Scl_ObjLegal( SC_Time * p, int i, float D ) { return Scl_ObjTime(p, i)->rise <= Scl_ObjTime2(p, i)->rise + Scl_ObjGetSlackR(p, i, D) && Scl_ObjTime(p, i)->fall <= Scl_ObjTime2(p, i)->fall + Scl_ObjGetSlackF(p, i, D); }
static inline double Scl_ObjLoadFf( SC_Time * p, int i, int fRise ) { return SC_LibCapFf( p->pLib, fRise ? Scl_ObjLoad(p, i)->rise : Scl_ObjLoad(p, i)->fall); }
static inline double Scl_ObjTimePs( SC_Time * p, int i, int fRise ) { return SC_LibTimePs(p->pLib, fRise ? Scl_ObjTime(p, i)->rise : Scl_ObjTime(p, i)->fall); }
static inline double Scl_ObjSlewPs( SC_Time * p, int i, int fRise ) { return SC_LibTimePs(p->pLib, fRise ? Scl_ObjSlew(p, i)->rise : Scl_ObjSlew(p, i)->fall); }
static inline double Scl_ObjLoadFf( SC_Time * p, int i, int fRise ) { return fRise ? Scl_ObjLoad(p, i)->rise : Scl_ObjLoad(p, i)->fall; }
static inline double Scl_ObjTimePs( SC_Time * p, int i, int fRise ) { return fRise ? Scl_ObjTime(p, i)->rise : Scl_ObjTime(p, i)->fall; }
static inline double Scl_ObjSlewPs( SC_Time * p, int i, int fRise ) { return fRise ? Scl_ObjSlew(p, i)->rise : Scl_ObjSlew(p, i)->fall; }
////////////////////////////////////////////////////////////////////////
/// FUNCTION DEFINITIONS ///
......
......@@ -284,7 +284,7 @@ int Abc_SclFindBestCell( SC_Man * p, Abc_Obj_t * pObj, Vec_Int_t * vRecalcs, Vec
Abc_SclLoadStore( p, pObj );
// try different gate sizes for this node
gateBest = -1;
dGainBest = -SC_LibTimeFromPs(p->pLib, DelayGap);
dGainBest = -DelayGap;
SC_RingForEachCell( pCellOld, pCellNew, k )
{
if ( pCellNew == pCellOld )
......@@ -765,19 +765,19 @@ void Abc_SclUpsizePrintDiffs( SC_Man * p, SC_Lib * pLib, Abc_Ntk_t * pNtk )
Abc_NtkForEachNode( pNtk, pObj, k )
{
if ( Abc_AbsFloat(p->pLoads[k].rise - pLoads[k].rise) > fDiff )
printf( "%6d : load rise differs %12.6f %f %f\n", k, SC_LibCapFf(pLib, p->pLoads[k].rise)-SC_LibCapFf(pLib, pLoads[k].rise), SC_LibCapFf(pLib, p->pLoads[k].rise), SC_LibCapFf(pLib, pLoads[k].rise) );
printf( "%6d : load rise differs %12.6f %f %f\n", k, p->pLoads[k].rise-pLoads[k].rise, p->pLoads[k].rise, pLoads[k].rise );
if ( Abc_AbsFloat(p->pLoads[k].fall - pLoads[k].fall) > fDiff )
printf( "%6d : load fall differs %12.6f %f %f\n", k, SC_LibCapFf(pLib, p->pLoads[k].fall)-SC_LibCapFf(pLib, pLoads[k].fall), SC_LibCapFf(pLib, p->pLoads[k].fall), SC_LibCapFf(pLib, pLoads[k].fall) );
printf( "%6d : load fall differs %12.6f %f %f\n", k, p->pLoads[k].fall-pLoads[k].fall, p->pLoads[k].fall, pLoads[k].fall );
if ( Abc_AbsFloat(p->pSlews[k].rise - pSlews[k].rise) > fDiff )
printf( "%6d : slew rise differs %12.6f %f %f\n", k, SC_LibTimePs(pLib, p->pSlews[k].rise)-SC_LibTimePs(pLib, pSlews[k].rise), SC_LibTimePs(pLib, p->pSlews[k].rise), SC_LibTimePs(pLib, pSlews[k].rise) );
printf( "%6d : slew rise differs %12.6f %f %f\n", k, p->pSlews[k].rise-pSlews[k].rise, p->pSlews[k].rise, pSlews[k].rise );
if ( Abc_AbsFloat(p->pSlews[k].fall - pSlews[k].fall) > fDiff )
printf( "%6d : slew fall differs %12.6f %f %f\n", k, SC_LibTimePs(pLib, p->pSlews[k].fall)-SC_LibTimePs(pLib, pSlews[k].fall), SC_LibTimePs(pLib, p->pSlews[k].fall), SC_LibTimePs(pLib, pSlews[k].fall) );
printf( "%6d : slew fall differs %12.6f %f %f\n", k, p->pSlews[k].fall-pSlews[k].fall, p->pSlews[k].fall, pSlews[k].fall );
if ( Abc_AbsFloat(p->pTimes[k].rise - pTimes[k].rise) > fDiff )
printf( "%6d : time rise differs %12.6f %f %f\n", k, SC_LibTimePs(pLib, p->pTimes[k].rise)-SC_LibTimePs(pLib, pTimes[k].rise), SC_LibTimePs(pLib, p->pTimes[k].rise), SC_LibTimePs(pLib, pTimes[k].rise) );
printf( "%6d : time rise differs %12.6f %f %f\n", k, p->pTimes[k].rise-pTimes[k].rise, p->pTimes[k].rise, pTimes[k].rise );
if ( Abc_AbsFloat(p->pTimes[k].fall - pTimes[k].fall) > fDiff )
printf( "%6d : time fall differs %12.6f %f %f\n", k, SC_LibTimePs(pLib, p->pTimes[k].fall)-SC_LibTimePs(pLib, pTimes[k].fall), SC_LibTimePs(pLib, p->pTimes[k].fall), SC_LibTimePs(pLib, pTimes[k].fall) );
printf( "%6d : time fall differs %12.6f %f %f\n", k, p->pTimes[k].fall-pTimes[k].fall, p->pTimes[k].fall, pTimes[k].fall );
}
/*
......@@ -817,10 +817,10 @@ void Abc_SclUpsizePrint( SC_Man * p, int Iter, int win, int nPathPos, int nPathN
printf( "%.2f ", p->SumArea );
printf( "(%+5.1f %%) ", 100.0 * (p->SumArea - p->SumArea0)/ p->SumArea0 );
printf( "D: " );
printf( "%.2f ps ", SC_LibTimePs(p->pLib, p->MaxDelay) );
printf( "%.2f ps ", p->MaxDelay );
printf( "(%+5.1f %%) ", 100.0 * (p->MaxDelay - p->MaxDelay0)/ p->MaxDelay0 );
printf( "B: " );
printf( "%.2f ps ", SC_LibTimePs(p->pLib, p->BestDelay) );
printf( "%.2f ps ", p->BestDelay );
printf( "(%+5.1f %%)", 100.0 * (p->BestDelay - p->MaxDelay0)/ p->MaxDelay0 );
printf( "%8.2f sec ", 1.0*(Abc_Clock() - p->timeTotal)/(CLOCKS_PER_SEC) );
printf( "%c", fVerbose ? '\n' : '\r' );
......@@ -895,8 +895,8 @@ void Abc_SclUpsizePerform( SC_Lib * pLib, Abc_Ntk_t * pNtk, SC_SizePars * pPars
p->BestDelay = p->MaxDelay0;
// perform upsizing
nAllPos = nAllNodes = nAllTfos = nAllUpsizes = 0;
if ( p->BestDelay <= SC_LibTimeFromPs(p->pLib, (float)pPars->DelayUser) )
printf( "Current delay (%.2f ps) is better than the target delay (%.2f ps).\n", SC_LibTimePs(p->pLib, p->BestDelay), (float)pPars->DelayUser );
if ( p->BestDelay <= pPars->DelayUser )
printf( "Current delay (%.2f ps) is better than the target delay (%.2f ps).\n", p->BestDelay, (float)pPars->DelayUser );
else
for ( i = 0; i < pPars->nIters; i++ )
{
......@@ -975,7 +975,7 @@ void Abc_SclUpsizePerform( SC_Lib * pLib, Abc_Ntk_t * pNtk, SC_SizePars * pPars
if ( nFramesNoChange > pPars->nIterNoChange )
break;
// check best delay
if ( p->BestDelay <= SC_LibTimeFromPs(p->pLib, (float)pPars->DelayUser) )
if ( p->BestDelay <= pPars->DelayUser )
break;
}
// update for best gates and recompute timing
......
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