diff --git a/hurricane/src/hurricane/Cell.cpp b/hurricane/src/hurricane/Cell.cpp index 65d62b3c..abcccd32 100644 --- a/hurricane/src/hurricane/Cell.cpp +++ b/hurricane/src/hurricane/Cell.cpp @@ -212,6 +212,19 @@ void Cell::flattenNets(unsigned int flags) buildRing = flags & Cell::BuildRings; } + bool hasRoutingPads = false; + forEach ( Component*, icomponent, net->getComponents() ) { + RoutingPad* rp = dynamic_cast( *icomponent ); + if (rp) { + // At least one RoutingPad is present: assumes that the net is already + // flattened (completly). + //cerr << net << " has already RoutingPads, skipped " << rp << endl; + hasRoutingPads = true; + break; + } + } + if (hasRoutingPads) continue; + forEach ( Component*, icomponent, net->getComponents() ) { Plug* primaryPlug = dynamic_cast( *icomponent ); if (primaryPlug) { diff --git a/hurricane/src/hurricane/Entity.cpp b/hurricane/src/hurricane/Entity.cpp index 96739147..9d636a68 100644 --- a/hurricane/src/hurricane/Entity.cpp +++ b/hurricane/src/hurricane/Entity.cpp @@ -37,6 +37,10 @@ namespace Hurricane { unsigned int Entity::_idCounter = 0; + unsigned int Entity::getIdCounter () + { return _idCounter; } + + Entity::Entity() : Inherit() , _id(_idCounter++) diff --git a/hurricane/src/hurricane/hurricane/Entity.h b/hurricane/src/hurricane/hurricane/Entity.h index 4023ec32..513a8e56 100644 --- a/hurricane/src/hurricane/hurricane/Entity.h +++ b/hurricane/src/hurricane/hurricane/Entity.h @@ -40,6 +40,8 @@ namespace Hurricane { { public: typedef DBo Inherit; + public: + static unsigned int getIdCounter (); public: inline unsigned int getId () const; virtual Cell* getCell () const = 0;