summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAlan Mishchenko <alanmi@berkeley.edu>2014-04-29 00:21:35 -0700
committerAlan Mishchenko <alanmi@berkeley.edu>2014-04-29 00:21:35 -0700
commit73289034befeeeb8f55b13d519459b752b43534a (patch)
treeaafaf3dab35bc21818a675634252fb9ea81f06ae /src
parent5acb147f615c8f76f7af745d8f72bccd350016fc (diff)
downloadabc-73289034befeeeb8f55b13d519459b752b43534a.tar.gz
abc-73289034befeeeb8f55b13d519459b752b43534a.tar.bz2
abc-73289034befeeeb8f55b13d519459b752b43534a.zip
Added optimization for average rather than maximum delay.
Diffstat (limited to 'src')
-rw-r--r--src/map/if/ifTime.c24
1 files changed, 20 insertions, 4 deletions
diff --git a/src/map/if/ifTime.c b/src/map/if/ifTime.c
index 7402bd31..ca53776d 100644
--- a/src/map/if/ifTime.c
+++ b/src/map/if/ifTime.c
@@ -363,8 +363,16 @@ void If_ManComputeRequired( If_Man_t * p )
// set the required times for the POs
if ( p->pPars->fDoAverage )
{
- If_ManForEachCo( p, pObj, i )
- If_ObjFanin0(pObj)->Required = If_ObjArrTime(If_ObjFanin0(pObj));
+ if ( p->pPars->nRelaxRatio )
+ {
+ If_ManForEachCo( p, pObj, i )
+ If_ObjFanin0(pObj)->Required = If_ObjArrTime(If_ObjFanin0(pObj)) * (100.0 + p->pPars->nRelaxRatio) / 100.0;
+ }
+ else
+ {
+ If_ManForEachCo( p, pObj, i )
+ If_ObjFanin0(pObj)->Required = If_ObjArrTime(If_ObjFanin0(pObj));
+ }
}
else if ( p->pPars->fLatchPaths )
{
@@ -443,8 +451,16 @@ void If_ManComputeRequired( If_Man_t * p )
}
else if ( p->pPars->fDoAverage )
{
- If_ManForEachCo( p, pObj, i )
- Tim_ManSetCoRequired( p->pManTim, i, If_ObjArrTime(If_ObjFanin0(pObj)) );
+ if ( p->pPars->nRelaxRatio )
+ {
+ If_ManForEachCo( p, pObj, i )
+ Tim_ManSetCoRequired( p->pManTim, i, If_ObjArrTime(If_ObjFanin0(pObj)) * (100.0 + p->pPars->nRelaxRatio) / 100.0 );
+ }
+ else
+ {
+ If_ManForEachCo( p, pObj, i )
+ Tim_ManSetCoRequired( p->pManTim, i, If_ObjArrTime(If_ObjFanin0(pObj)) );
+ }
}
else if ( p->pPars->fLatchPaths )
{