diff --git a/cumulus/src/plugins/ChipPlugin.py b/cumulus/src/plugins/ChipPlugin.py index a8812e5e..66773917 100644 --- a/cumulus/src/plugins/ChipPlugin.py +++ b/cumulus/src/plugins/ChipPlugin.py @@ -20,6 +20,8 @@ try: import os.path import optparse import math + import cProfile + import pstats import Cfg import Hurricane from Hurricane import DataBase @@ -151,10 +153,18 @@ class PlaceCore ( chip.Configuration.ChipConfWrapper ): etesian.place() etesian.destroy() + #profile = cProfile.Profile() + #profile.enable() ht.connectLeaf() #ht.prune() ht.route() ht.save( self.cell ) + #profile.disable() + + #stats = pstats.Stats( profile, stream=sys.stderr ) + #stats.strip_dirs() + #stats.sort_stats( 'cumtime' ) + #stats.print_stats() else: if Cfg.getParamString('clockTree.placerEngine').asString() != 'Etesian': mauka = Mauka.MaukaEngine.create( coreCell ) diff --git a/hurricane/src/hurricane/Net.cpp b/hurricane/src/hurricane/Net.cpp index c2b822d4..30f682a0 100644 --- a/hurricane/src/hurricane/Net.cpp +++ b/hurricane/src/hurricane/Net.cpp @@ -465,23 +465,23 @@ void Net::setGlobal(bool isGlobal) void Net::setExternal(bool isExternal) // *********************************** { - if (isExternal != _isExternal) { - if (!isExternal) { - if (!getConnectedSlavePlugs().isEmpty()) - throw Error("Can't set internal : has connected slave plugs"); - _direction = Direction::UNDEFINED; - } - _isExternal = isExternal; - if (_isExternal) { - UpdateSession::open(); - setPosition(Point(0,0)); - for_each_instance(instance, _cell->getSlaveInstances()) { - Plug::_create(instance, this); - end_for; - } - UpdateSession::close(); - } + if (isExternal != _isExternal) { + if (not isExternal) { + if (not getConnectedSlavePlugs().isEmpty()) + throw Error( "Net::setExternal(): Cannot set \"%s\" of \"%s\" internal, has connected slave plugs" + , getString(getName()).c_str() + , getString(getCell()->getName()).c_str() + ); + _direction = Direction::UNDEFINED; } + _isExternal = isExternal; + if (_isExternal) { + setPosition( Point(0,0) ); + for ( Instance* instance : _cell->getSlaveInstances() ) { + Plug::_create( instance, this ); + } + } + } } void Net::setAutomatic(bool isAutomatic) diff --git a/katabatic/src/AutoHorizontal.cpp b/katabatic/src/AutoHorizontal.cpp index a17b60fa..c118e13a 100644 --- a/katabatic/src/AutoHorizontal.cpp +++ b/katabatic/src/AutoHorizontal.cpp @@ -426,6 +426,16 @@ namespace Katabatic { if (spinFlags & SegSourceBottom) setFlags( SegTargetBottom ); if (spinFlags & SegTargetTop ) setFlags( SegSourceTop ); if (spinFlags & SegTargetBottom) setFlags( SegSourceBottom ); + + unsigned int invalidatedFlags = _flags & (SegInvalidatedSource|SegInvalidatedTarget); + unsetFlags( SegInvalidatedSource|SegInvalidatedTarget ); + if (invalidatedFlags & SegInvalidatedSource) setFlags( SegInvalidatedTarget ); + if (invalidatedFlags & SegInvalidatedTarget) setFlags( SegInvalidatedSource ); + + unsigned int terminalFlags = _flags & SegStrongTerminal; + unsetFlags( SegStrongTerminal ); + if (terminalFlags & SegSourceTerminal) setFlags( SegTargetTerminal ); + if (terminalFlags & SegTargetTerminal) setFlags( SegSourceTerminal ); } } diff --git a/kite/src/Session.cpp b/kite/src/Session.cpp index aa932976..978d7616 100644 --- a/kite/src/Session.cpp +++ b/kite/src/Session.cpp @@ -245,6 +245,8 @@ namespace Kite { } _doRemovalEvents(); + for ( Track* track : _sortEvents ) track->doReorder(); + _sortEvents.clear(); cdebug_tabw(159,-1); return count;