diff --git a/anabatic/src/AnabaticEngine.cpp b/anabatic/src/AnabaticEngine.cpp index 696248e2..a9bc8df9 100644 --- a/anabatic/src/AnabaticEngine.cpp +++ b/anabatic/src/AnabaticEngine.cpp @@ -1757,10 +1757,10 @@ namespace Anabatic { { Super::printMeasures(); - // if (not tag.empty()) { - // addMeasure( getCell(), tag+"T", getTimer().getCombTime () ); - // addMeasure( getCell(), tag+"S", (getTimer().getMemorySize() >> 20) ); - // } + if (not tag.empty()) { + addMeasure( tag+"T", getTimer().getCombTime () ); + addMeasure( tag+"S", (getTimer().getMemorySize() >> 20) ); + } } diff --git a/anabatic/src/AutoSegment.cpp b/anabatic/src/AutoSegment.cpp index b02154c3..9d0be15a 100644 --- a/anabatic/src/AutoSegment.cpp +++ b/anabatic/src/AutoSegment.cpp @@ -529,10 +529,10 @@ namespace Anabatic { if (dynamic_cast(segment)) setFlags( SegHorizontal ); - _globalsCount += isGlobal() ? 1 : 0; AutoContact* source = Session::lookup(dynamic_cast(segment->getSource())); AutoContact* target = Session::lookup(dynamic_cast(segment->getTarget())); + _globalsCount += (source->getGCell() != target->getGCell()) ? 1 : 0; if (source->isTerminal()) setFlags( SegSourceTerminal ); if (target->isTerminal()) setFlags( SegTargetTerminal ); diff --git a/cumulus/src/plugins/alpha/block/block.py b/cumulus/src/plugins/alpha/block/block.py index 5f099bc2..bbd193ba 100644 --- a/cumulus/src/plugins/alpha/block/block.py +++ b/cumulus/src/plugins/alpha/block/block.py @@ -769,6 +769,8 @@ class Block ( object ): success = self.katana.isDetailedRoutingSuccess() Breakpoint.stop( 100, 'Block.route() done, success:{}.'.format(success) ) self.katana.finalizeLayout() + if self.conf.cfg.katana.dumpMeasures is True: + self.katana.dumpMeasures() self.katana.destroy() self.katana = None if self.etesian: diff --git a/cumulus/src/plugins/alpha/block/configuration.py b/cumulus/src/plugins/alpha/block/configuration.py index 51c2d306..7f32812d 100644 --- a/cumulus/src/plugins/alpha/block/configuration.py +++ b/cumulus/src/plugins/alpha/block/configuration.py @@ -1217,6 +1217,7 @@ class BlockConf ( GaugeConf ): self.cfg.etesian.spaceMargin = None self.cfg.etesian.latchUpDistance = None self.cfg.block.spareSide = None + self.cfg.katana.dumpMeasures = None self.etesian = None self.katana = None diff --git a/katana/src/GlobalRoute.cpp b/katana/src/GlobalRoute.cpp index 353e5817..f5525d87 100644 --- a/katana/src/GlobalRoute.cpp +++ b/katana/src/GlobalRoute.cpp @@ -623,14 +623,14 @@ namespace Katana { stopMeasures(); printMeasures( "Dijkstra" ); + uint32_t hoverflow = 0; + uint32_t voverflow = 0; if (not ovEdges.empty()) { Histogram ovHistogram ( 0.0, 1.0, 1 ); ovHistogram.setTitle ( "Overflowed", 0 ); ovHistogram.setColor ( "green" , 0 ); ovHistogram.setIndent( " " , 0 ); - uint32_t hoverflow = 0; - uint32_t voverflow = 0; set nets; set segments; @@ -694,6 +694,9 @@ namespace Katana { if (flags & Flags::ShowBloatedInstances) selectBloatedInstances( this ); } + addMeasure( "H-ovE", hoverflow, 12 ); + addMeasure( "V-ovE", voverflow, 12 ); + if (getBlock(0)) { getBlock(0)->resizeChannels(); _resizeMatrix(); diff --git a/katana/src/KatanaEngine.cpp b/katana/src/KatanaEngine.cpp index de12c297..14df0a15 100644 --- a/katana/src/KatanaEngine.cpp +++ b/katana/src/KatanaEngine.cpp @@ -200,6 +200,9 @@ namespace Katana { , _successState (0) { //Entity::setMemoryLimit( 1024 ); // 1Gb. + addMeasure( "Gates" + , AllianceFramework::getInstancesCount(cell,AllianceFramework::IgnoreFeeds + |AllianceFramework::Recursive) ); } @@ -599,6 +602,8 @@ namespace Katana { { if (_negociateWindow) return; + addMeasure( "GCells", getGCells().size() ); + startMeasures(); openSession(); @@ -664,13 +669,19 @@ namespace Katana { vector unrouteds; vector reduceds; ostringstream result; + bool isSymbolic = + const_cast(this)->getConfiguration()->getRoutingGauge()->isSymbolic(); AutoSegmentLut::const_iterator ilut = _getAutoSegmentLut().begin(); for ( ; ilut != _getAutoSegmentLut().end() ; ilut++ ) { TrackElement* segment = _lookup( ilut->second ); if (segment == NULL) continue; - uint64_t wl = (unsigned long long)DbU::toLambda( segment->getLength() ); + uint64_t wl = 0; + if (isSymbolic) + wl = (unsigned long long)DbU::toLambda( segment->getLength() ); + else + wl = (unsigned long long)DbU::toPhysical( segment->getLength(), DbU::UnitPower::Nano ); if (wl > 100000) { cerr << Error("KatanaEngine::printCompletion(): Suspiciously long wire: %llu for %p:%s" ,wl,ilut->first,getString(segment).c_str()) << endl; @@ -711,6 +722,10 @@ namespace Katana { // } // } + if (not isSymbolic) { + totalWireLength /= 1000; + routedWireLength /= 1000; + } result << setprecision(4) << segmentRatio << "% [" << routeds << "+" << unrouteds.size() << "]"; cmess1 << Dots::asString( " - Track Segment Completion Ratio", result.str() ) << endl; @@ -741,8 +756,8 @@ namespace Katana { cmess1 << Dots::asString( " - Unrouted verticals", result.str() ) << endl; addMeasure ( "Segs" , routeds+unrouteds.size() ); - addMeasure( "DWL(l)" , totalWireLength , 12 ); - addMeasure( "fWL(l)" , totalWireLength-routedWireLength , 12 ); + addMeasure( "DWL" , totalWireLength , 12 ); + addMeasure( "fWL" , totalWireLength-routedWireLength , 12 ); addMeasure ( "WLER(%)", expandRatio ); } @@ -768,8 +783,8 @@ namespace Katana { measuresLabels.push_back( getMeasureLabel("algoS" ) ); measuresLabels.push_back( getMeasureLabel("finT" ) ); measuresLabels.push_back( getMeasureLabel("Segs" ) ); - measuresLabels.push_back( getMeasureLabel("DWL(l)" ) ); - measuresLabels.push_back( getMeasureLabel("fWL(l)" ) ); + measuresLabels.push_back( getMeasureLabel("DWL" ) ); + measuresLabels.push_back( getMeasureLabel("fWL" ) ); measuresLabels.push_back( getMeasureLabel("WLER(%)" ) ); measuresLabels.push_back( getMeasureLabel("Events" ) ); measuresLabels.push_back( getMeasureLabel("UEvents" ) );