In Knik add support for excluded nets (not to be routeds).
* New: In Knik, in <KnikEngine>, the methods ::initGlobalRouting(), ::run() and ::Route() now accepts one argument, a reference to a map of not to be routed nets (the key being the name for fast search by name). This feature is introduced to prevent the routing of nets for which a global/detailed routing is already supplied by the designer. For now it applies to the clock tree.
This commit is contained in:
parent
7a6dcd1527
commit
a6addb5c56
|
@ -190,8 +190,9 @@ namespace Knik {
|
|||
if ( !knik ) return;
|
||||
|
||||
//emit cellPreModificated ();
|
||||
|
||||
knik->run ();
|
||||
|
||||
map<Name,Net*> excludedNets;
|
||||
knik->run ( excludedNets );
|
||||
|
||||
//emit cellPostModificated ();
|
||||
}
|
||||
|
@ -204,7 +205,8 @@ namespace Knik {
|
|||
|
||||
//emit cellPreModificated ();
|
||||
|
||||
knik->Route ();
|
||||
map<Name,Net*> excludedNets;
|
||||
knik->Route ( excludedNets );
|
||||
|
||||
//emit cellPostModificated ();
|
||||
}
|
||||
|
|
|
@ -79,6 +79,8 @@ namespace Knik {
|
|||
, _allowedDepth ( 0)
|
||||
, _routingGraph ( NULL )
|
||||
, _routingGrid ( NULL )
|
||||
, _timer ()
|
||||
, _nets_to_route ()
|
||||
, _benchMode ( benchMode )
|
||||
, _useSegments ( useSegments )
|
||||
, _routingDone ( false )
|
||||
|
@ -189,8 +191,8 @@ void KnikEngine::MakeRoutingLeaves()
|
|||
return;
|
||||
}
|
||||
|
||||
void KnikEngine::initGlobalRouting()
|
||||
// *********************************
|
||||
void KnikEngine::initGlobalRouting( const map<Name,Net*>& excludedNets )
|
||||
// *********************************************************************
|
||||
{
|
||||
assert( _nets_to_route.empty() );
|
||||
cmess2 << " o Initializing global routing." << endl;
|
||||
|
@ -222,6 +224,11 @@ void KnikEngine::initGlobalRouting()
|
|||
Name obstacleNetName ("obstaclenet");
|
||||
|
||||
forEach ( Net*, inet, getCell()->getNets() ) {
|
||||
if (excludedNets.find(inet->getName()) != excludedNets.end()) {
|
||||
cparanoid << " - <" << inet->getName() << "> not routed (pre-routing found)." << endl;
|
||||
continue;
|
||||
}
|
||||
|
||||
if ( inet->isGlobal()
|
||||
or inet->isSupply()
|
||||
or inet->isClock()
|
||||
|
@ -1035,10 +1042,10 @@ void KnikEngine::computeOverflow()
|
|||
// _routingGraph->UpdateOccupancyWindow();
|
||||
// }
|
||||
|
||||
void KnikEngine::run()
|
||||
// *******************
|
||||
void KnikEngine::run( const map<Name,Net*>& excludedNets )
|
||||
// *******************************************************
|
||||
{
|
||||
Route();
|
||||
Route( excludedNets );
|
||||
bool done = analyseRouting();
|
||||
while ( !done ) {
|
||||
unrouteOvSegments();
|
||||
|
@ -1059,12 +1066,12 @@ void KnikEngine::run()
|
|||
computeSymbolicWireLength ();
|
||||
}
|
||||
|
||||
void KnikEngine::Route()
|
||||
// *********************
|
||||
void KnikEngine::Route( const map<Name,Net*>& excludedNets )
|
||||
// *********************************************************
|
||||
{
|
||||
UpdateSession::open();
|
||||
if ( !__initialized__ )
|
||||
initGlobalRouting();
|
||||
initGlobalRouting( excludedNets );
|
||||
|
||||
_timer.resetIncrease();
|
||||
_timer.start();
|
||||
|
@ -1073,11 +1080,6 @@ void KnikEngine::Route()
|
|||
cmess2 << " Iteration INIT"
|
||||
<< " # of nets to route:" << left << _nets_to_route.size() << endl;
|
||||
|
||||
//CEditor* editor = getCEditor ( getCell() );
|
||||
//editor->showRubbers();
|
||||
//editor->Refresh();
|
||||
//editor->Stop("Global Routing is going to do its job");
|
||||
|
||||
// initializing netStamp for routingGraph:
|
||||
//_routingGraph->setNetStamp(1); // Maybe NetStamp should not be initialized here !
|
||||
// Be aware that initializingthe NetStamp in the construction of the routingGraph, might be a bad idea, if a lotof rerouting processes are run, it may overpass the unsigne limit (really ?)
|
||||
|
|
|
@ -119,20 +119,20 @@ typedef vector<NetRecord> NetVector;
|
|||
// Attributes
|
||||
// **********
|
||||
private:
|
||||
static const Name _toolName;
|
||||
static size_t _hEdgeReservedLocal;
|
||||
static size_t _vEdgeReservedLocal;
|
||||
RoutingGauge* _routingGauge;
|
||||
unsigned int _allowedDepth;
|
||||
Graph* _routingGraph;
|
||||
RoutingGrid* _routingGrid;
|
||||
Timer _timer;
|
||||
NetVector _nets_to_route;
|
||||
bool _benchMode;
|
||||
bool _useSegments;
|
||||
bool _routingDone;
|
||||
unsigned _rerouteIteration;
|
||||
map<Segment*,SegRecord> _segmentOverEdges;
|
||||
static const Name _toolName;
|
||||
static size_t _hEdgeReservedLocal;
|
||||
static size_t _vEdgeReservedLocal;
|
||||
RoutingGauge* _routingGauge;
|
||||
unsigned int _allowedDepth;
|
||||
Graph* _routingGraph;
|
||||
RoutingGrid* _routingGrid;
|
||||
Timer _timer;
|
||||
NetVector _nets_to_route;
|
||||
bool _benchMode;
|
||||
bool _useSegments;
|
||||
bool _routingDone;
|
||||
unsigned _rerouteIteration;
|
||||
map<Segment*,SegRecord> _segmentOverEdges;
|
||||
vector<pair<Segment*,SegRecord*> > _sortSegmentOv;
|
||||
set<Segment*> _segmentsToUnroute;
|
||||
|
||||
|
@ -166,9 +166,9 @@ typedef vector<NetRecord> NetVector;
|
|||
RoutingGauge* getRoutingGauge () const { return _routingGauge; }
|
||||
void setAllowedDepth ( unsigned int );
|
||||
unsigned int getAllowedDepth () const { return _allowedDepth; }
|
||||
void initGlobalRouting (); // Making it public, so it can be called earlier and then capacities on edges can be ajusted
|
||||
void run ();
|
||||
void Route ();
|
||||
void initGlobalRouting ( const map<Name,Net*>& excludedNets ); // Making it public, so it can be called earlier and then capacities on edges can be ajusted
|
||||
void run ( const map<Name,Net*>& excludedNets );
|
||||
void Route ( const map<Name,Net*>& excludedNets );
|
||||
void createRoutingGrid ( unsigned nbXTiles
|
||||
, unsigned nbYTiles
|
||||
, const Box& boundingBox
|
||||
|
|
Loading…
Reference in New Issue