Added missing UpdateSession in Stratus & Plugins.

* Bug: In Cumulus & Stratus, now that creation of Hurricane objects must be
    enclosed in UpdateSession, has to adds them into Python code.
* Bug: In Anabatic & Katana, in the global routing stage suspend the timed
    bewteen ripup steps instead of resetting it.
This commit is contained in:
Jean-Paul Chaput 2016-09-11 13:20:05 +02:00
parent ce00b37cbf
commit 5435ca1933
6 changed files with 22 additions and 3 deletions

View File

@ -958,6 +958,14 @@ namespace Anabatic {
{ _timer.stop(); }
void AnabaticEngine::suspendMeasures ()
{ _timer.suspend(); }
void AnabaticEngine::resumeMeasures ()
{ _timer.resume(); }
void AnabaticEngine::printMeasures ( const string& tag ) const
{
ostringstream result;

View File

@ -278,6 +278,8 @@ namespace Anabatic {
inline const Timer& getTimer () const;
void startMeasures ();
void stopMeasures ();
void suspendMeasures ();
void resumeMeasures ();
void printMeasures ( const string& ) const;
inline void _add ( GCell* );
inline void _remove ( GCell* );

View File

@ -538,6 +538,7 @@ class Corona ( object ):
if self.horizontalDepth > self.verticalDepth:
contactDepth = self.verticalDepth
UpdateSession.open()
for i in range(self._railsNb):
xBL = self._westSide .getRail(i).axis
yBL = self._southSide.getRail(i).axis
@ -582,4 +583,5 @@ class Corona ( object ):
self._westSide.addBlockages()
self._eastSide.addBlockages()
UpdateSession.close()
return

View File

@ -105,6 +105,7 @@ class HTree ( GaugeConfWrapper ):
raise ErrorMessage( 3, 'ClockTree: clockTree.minimumSide (%g) is less than 100 lambda.' \
% DbU.toLambda(self.minSide) )
UpdateSession.open()
self.framework = CRL.AllianceFramework.get()
self.cell = cell
self.area = area
@ -126,6 +127,7 @@ class HTree ( GaugeConfWrapper ):
if not self.masterClock:
raise ErrorMessage( 3, 'ClockTree: Cell %s has no clock net.' % cell.getName() )
self._createChildNet( self.topBuffer, 'ck_htree' )
UpdateSession.close()
return
@ -371,6 +373,7 @@ class HTreeNode ( object ):
DownBranch = 0x0010
def __init__ ( self, topTree, sourceBuffer, area, prefix, flags ):
UpdateSession.open()
self.topTree = topTree
self.childs = []
self.blLeafs = []
@ -406,6 +409,7 @@ class HTreeNode ( object ):
self.childs.append( HTreeNode( self.topTree, self.tlBuffer, self.tlArea(), self.prefix+'_tl', 0 ) )
self.childs.append( HTreeNode( self.topTree, self.trBuffer, self.trArea(), self.prefix+'_tr', 0 ) )
UpdateSession.close()
return
def xmin ( self ): return self.area.getXMin()

View File

@ -150,7 +150,7 @@ namespace Katana {
annotateGlobalGraph();
startMeasures();
cmess1 << " o Running global routing..." << endl;
cmess1 << " o Running global routing." << endl;
float edgeHInc = getConfiguration()->getEdgeHInc();
@ -198,10 +198,10 @@ namespace Katana {
dijkstra->setSearchAreaHalo( Session::getSliceHeight()*3 );
cmess2 << " ripup:" << setw(4) << netCount << right;
stopMeasures();
suspendMeasures();
cmess2 << " " << setw(10) << Timer::getStringTime (getTimer().getCombTime())
<< " " << setw( 6) << Timer::getStringMemory(getTimer().getIncrease()) << endl;
startMeasures();
resumeMeasures();
++iteration;
} while ( (netCount > 0) and (iteration < 5) );

View File

@ -32,6 +32,7 @@ try:
print ' - Netlist format: <%s>.' % Cfg.getParamString('stratus1.format').asString()
print ' - Simulator: <%s>.' % Cfg.getParamString('stratus1.simulator').asString()
from Hurricane import UpdateSession
from st_model import *
from st_net import *
from st_instance import *
@ -82,6 +83,7 @@ def buildModel ( moduleName, flags, className=None, modelName=None, parameters={
print '[ERROR] Stratus module <%s> do not contains a design named <%s>.' % (moduleName,className)
sys.exit(1)
UpdateSession.open()
print ' - Generating Stratus Model <%s> (generator:<%s>).' % (modelName, className)
model = module.__dict__[className](modelName,parameters)
model.Interface()
@ -93,6 +95,7 @@ def buildModel ( moduleName, flags, className=None, modelName=None, parameters={
if flags & DoStop: stopLevel = 1
model.View(stopLevel, 'Model %s' % modelName)
model.Save(LOGICAL|PHYSICAL)
UpdateSession.close()
except ImportError, e:
module = str(e).split()[-1]