ExtensionCap support and source/target terminal flags in Katabatic & Kite.

Placement management:
* Change: In <metis>, always disable the hMetis support regardless of
    it being detected or not as the placer is still unable manage the
    final bin contents.

Routing gauge management:
* Bug: In CRL Core, <vsclib/alliance.conf>, set the correct pitches and
    size for the routing layers and the cell gauge.
* Change: In Katabatic & Kite, extract the correct extension cap for each
    routing layer from the layers characteristics (cache then in
    Katabatic::Configuration).
* Change: In Katabatic, <AutoSegment>, create segment with the wire width
    defined in the gauge. For AutoSegment created on already existing
    Segment from the global routing, adjust the width.
* Change: In Katabatic, <AutoSegment>, more accurate information about how
    a segment is connected to terminal via source and/or target.
    The flag SegStrongTerminal is splitted into SegSourceTerminal and
    SegSourceTarget (but still used as a mask). So now we can know by
    which end an AutoSegment is connected to a terminal.
* Change: In Katabatic, ::doRp_Access(), create constraint freeing segments
    not only when HSmall but also when VSmall (more critical for <vsclib>).
    Otherwise we may see AutoSegments with incompatible source/target
    constraints.
* Change: In Kite, BuildPowerRails, do not create blockage on PinOnly
    layers *but* still create power rails planes. This is a temporary
    workaround for <vsclib> where the METAL1 blockages overlaps the
    terminals (it was fine for Nero, but they shouldn't for Kite).
* Change: In Kite, <RoutingEvent>, if a TrackSegment is overconstrained,
    directly bybass it's slackening state to DataNegociate::Slacken.
    Also rename the flag "_canHandleConstraints" to "_overConstrained",
    seems clearer to me.

Miscellaneous:
* Change: In CRL Core, <Utilities>, add a "pass-though" capability on the
    mstream to temporarily make them print everything.
This commit is contained in:
Jean-Paul Chaput 2014-05-25 15:00:35 +02:00
parent 8bc7bd38db
commit cd9d3fc4b6
31 changed files with 238 additions and 192 deletions

View File

@ -33,13 +33,13 @@ allianceConfig = \
routingGaugesTable = {} routingGaugesTable = {}
routingGaugesTable['vsclib'] = \ routingGaugesTable['vsclib'] = \
( ( 'METAL1', ( RoutingLayerGauge.Vertical , RoutingLayerGauge.PinOnly, 0, 0.0, 0, 5, 2, 2 ) ) ( ( 'METAL1', ( RoutingLayerGauge.Vertical , RoutingLayerGauge.PinOnly, 0, 0.0, 4, 8, 3, 2 ) )
, ( 'METAL2', ( RoutingLayerGauge.Horizontal, RoutingLayerGauge.Default, 1, 7.0, 0, 5, 2, 2 ) ) , ( 'METAL2', ( RoutingLayerGauge.Horizontal, RoutingLayerGauge.Default, 1, 7.0, 0, 8, 4, 2 ) )
, ( 'METAL3', ( RoutingLayerGauge.Vertical , RoutingLayerGauge.Default, 2, 0.0, 0, 5, 2, 2 ) ) , ( 'METAL3', ( RoutingLayerGauge.Vertical , RoutingLayerGauge.Default, 2, 0.0, 4, 8, 4, 2 ) )
, ( 'METAL4', ( RoutingLayerGauge.Horizontal, RoutingLayerGauge.Default, 3, 0.0, 0, 5, 2, 2 ) ) , ( 'METAL4', ( RoutingLayerGauge.Horizontal, RoutingLayerGauge.Default, 3, 0.0, 0, 8, 4, 2 ) )
, ( 'METAL5', ( RoutingLayerGauge.Vertical , RoutingLayerGauge.Default, 4, 0.0, 0, 5, 2, 2 ) ) , ( 'METAL5', ( RoutingLayerGauge.Vertical , RoutingLayerGauge.Default, 4, 0.0, 4, 8, 4, 2 ) )
#, ( 'METAL6', ( RoutingLayerGauge.Horizontal, RoutingLayerGauge.Default, 5, 0.0, 0, 5, 2, 2 ) ) #, ( 'METAL6', ( RoutingLayerGauge.Horizontal, RoutingLayerGauge.Default, 5, 0.0, 0, 8, 4, 2 ) )
#, ( 'METAL7', ( RoutingLayerGauge.Vertical , RoutingLayerGauge.Default, 6, 0.0, 0, 5, 2, 2 ) ) #, ( 'METAL7', ( RoutingLayerGauge.Vertical , RoutingLayerGauge.Default, 6, 0.0, 4, 8, 4, 2 ) )
) )
@ -48,5 +48,5 @@ routingGaugesTable['vsclib'] = \
# ( METAL_PIN, xy_common_pitch, slice_height, slice_step ) # ( METAL_PIN, xy_common_pitch, slice_height, slice_step )
cellGaugesTable = {} cellGaugesTable = {}
cellGaugesTable['vsclib'] = ('metal2', 5.0, 50.0, 5.0) cellGaugesTable['vsclib'] = ('metal2', 8.0, 72.0, 8.0)

View File

@ -3,7 +3,7 @@
import helpers import helpers
# The informations here are extracted from the Alliance ".rds" file, # The informations here are extracted from the Alliance ".rds" file,
# and must be coherent with it. # and must be consistent with it.
# #
# Provides standard settings for: # Provides standard settings for:
# - <viewerConfig> # - <viewerConfig>

View File

@ -118,7 +118,7 @@ namespace {
int tty::_width = 80; int tty::_width = 80;
bool tty::_enabled = true; bool tty::_enabled = true;
unsigned int mstream::_activeMask = mstream::Verbose0; unsigned int mstream::_activeMask = mstream::PassThrough|mstream::Verbose0;
mstream cmess0 ( mstream::Verbose0, std::cout ); mstream cmess0 ( mstream::Verbose0, std::cout );
mstream cmess1 ( mstream::Verbose1, std::cout ); mstream cmess1 ( mstream::Verbose1, std::cout );

View File

@ -1,8 +1,7 @@
// -*- C++ -*- // -*- C++ -*-
// //
// This file is part of the Coriolis Software. // This file is part of the Coriolis Software.
// Copyright (c) UPMC/LIP6 2008-2012, All Rights Reserved // Copyright (c) UPMC 2008-2014, All Rights Reserved
// //
// +-----------------------------------------------------------------+ // +-----------------------------------------------------------------+
// | C O R I O L I S | // | C O R I O L I S |
@ -257,20 +256,23 @@ inline std::string tty::bgcolor ( unsigned int mask )
class mstream : public std::ostream { class mstream : public std::ostream {
public: public:
enum StreamMasks { Verbose0 = 0x00000001 enum StreamMasks { PassThrough = 0x00000001
, Verbose1 = 0x00000002 , Verbose0 = 0x00000002
, Verbose2 = 0x00000004 , Verbose1 = 0x00000004
, Info = 0x00000008 , Verbose2 = 0x00000008
, Paranoid = 0x00000010 , Info = 0x00000010
, Bug = 0x00000020 , Paranoid = 0x00000020
, Bug = 0x00000040
}; };
public: public:
static void enable ( unsigned int mask ); static void enable ( unsigned int mask );
static void disable ( unsigned int mask ); static void disable ( unsigned int mask );
inline mstream ( unsigned int mask, std::ostream &s ); inline mstream ( unsigned int mask, std::ostream &s );
inline unsigned int getStreamMask() const;
static inline unsigned int getActiveMask();
inline bool enabled () const; inline bool enabled () const;
inline unsigned int getStreamMask () const;
static inline unsigned int getActiveMask ();
inline void setStreamMask ( unsigned int mask );
inline void unsetStreamMask ( unsigned int mask );
// Overload for formatted outputs. // Overload for formatted outputs.
template<typename T> inline mstream& operator<< ( T& t ); template<typename T> inline mstream& operator<< ( T& t );
template<typename T> inline mstream& operator<< ( T* t ); template<typename T> inline mstream& operator<< ( T* t );
@ -288,9 +290,11 @@ inline std::string tty::bgcolor ( unsigned int mask )
inline mstream::mstream ( unsigned int mask, std::ostream& s ): std::ostream(s.rdbuf()) , _streamMask(mask) {} inline mstream::mstream ( unsigned int mask, std::ostream& s ): std::ostream(s.rdbuf()) , _streamMask(mask) {}
inline unsigned int mstream::getStreamMask() const { return _streamMask; }
inline unsigned int mstream::getActiveMask() { return _activeMask; }
inline bool mstream::enabled () const { return (_streamMask & _activeMask); } inline bool mstream::enabled () const { return (_streamMask & _activeMask); }
inline unsigned int mstream::getStreamMask () const { return _streamMask; }
inline unsigned int mstream::getActiveMask () { return _activeMask; }
inline void mstream::setStreamMask ( unsigned int mask ) { _streamMask |= mask; }
inline void mstream::unsetStreamMask( unsigned int mask ) { _streamMask &= ~mask; }
inline mstream& mstream::flush () { if (enabled()) static_cast<std::ostream*>(this)->flush(); return *this; } inline mstream& mstream::flush () { if (enabled()) static_cast<std::ostream*>(this)->flush(); return *this; }
inline mstream& mstream::operator<< ( std::ostream& (*pf)(std::ostream&) ) { if (enabled()) (*pf)(*this); return *this; } inline mstream& mstream::operator<< ( std::ostream& (*pf)(std::ostream&) ) { if (enabled()) (*pf)(*this); return *this; }

View File

@ -1,7 +1,6 @@
// -*- C++ -*- // -*- C++ -*-
// //
// Copyright (c) BULL S.A. 2000-2009, All Rights Reserved // Copyright (c) BULL S.A. 2000-2014, All Rights Reserved
// //
// This file is part of Hurricane. // This file is part of Hurricane.
// //
@ -19,12 +18,7 @@
// License along with Hurricane. If not, see // License along with Hurricane. If not, see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
// //
// =================================================================== // +-----------------------------------------------------------------+
//
// $Id$
//
// x-----------------------------------------------------------------x
// | |
// | H U R R I C A N E | // | H U R R I C A N E |
// | V L S I B a c k e n d D a t a - B a s e | // | V L S I B a c k e n d D a t a - B a s e |
// | | // | |
@ -32,21 +26,17 @@
// | E-mail : Jean-Paul.Chaput@lip6.fr | // | E-mail : Jean-Paul.Chaput@lip6.fr |
// | =============================================================== | // | =============================================================== |
// | C++ Module : "./RegularLayer.cpp" | // | C++ Module : "./RegularLayer.cpp" |
// | *************************************************************** | // +-----------------------------------------------------------------+
// | U p d a t e s |
// | |
// x-----------------------------------------------------------------x
# include "hurricane/BasicLayer.h" #include "hurricane/BasicLayer.h"
# include "hurricane/RegularLayer.h" #include "hurricane/RegularLayer.h"
# include "hurricane/Technology.h" #include "hurricane/Technology.h"
# include "hurricane/Error.h" #include "hurricane/Error.h"
namespace { namespace {
const char* nullLayer = const char* nullLayer =
"RegularLayer::setBasicLayer() [%s]\n" "RegularLayer::setBasicLayer() [%s]\n"
" basicLayer argument mustn't be NULL."; " basicLayer argument mustn't be NULL.";
@ -55,13 +45,11 @@ namespace {
"RegularLayer::setBasicLayer() [%s]\n" "RegularLayer::setBasicLayer() [%s]\n"
" Reseting the basic layer is forbidden."; " Reseting the basic layer is forbidden.";
} }
namespace Hurricane { namespace Hurricane {
// ------------------------------------------------------------------- // -------------------------------------------------------------------
// Class : "Hurricane::RegularLayer_RegularLayers". // Class : "Hurricane::RegularLayer_RegularLayers".
@ -335,4 +323,4 @@ namespace Hurricane {
} }
} // End of Hurricane namespace. } // Hurricane namespace.

View File

@ -1,7 +1,6 @@
// -*- C++ -*- // -*- C++ -*-
// //
// Copyright (c) BULL S.A. 2000-2013, All Rights Reserved // Copyright (c) BULL S.A. 2000-2014, All Rights Reserved
// //
// This file is part of Hurricane. // This file is part of Hurricane.
// //
@ -19,10 +18,6 @@
// License along with Hurricane. If not, see // License along with Hurricane. If not, see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
// //
// ===================================================================
//
// $Id$
//
// +-----------------------------------------------------------------+ // +-----------------------------------------------------------------+
// | H U R R I C A N E | // | H U R R I C A N E |
// | V L S I B a c k e n d D a t a - B a s e | // | V L S I B a c k e n d D a t a - B a s e |
@ -30,7 +25,7 @@
// | Authors : Hugo Clement & Marek Sroka | // | Authors : Hugo Clement & Marek Sroka |
// | E-mail : Jean-Paul.Chaput@lip6.fr | // | E-mail : Jean-Paul.Chaput@lip6.fr |
// | =============================================================== | // | =============================================================== |
// | C++ Header : "./RoutingPad.h" | // | C++ Module : "./RoutingPad.cpp" |
// +-----------------------------------------------------------------+ // +-----------------------------------------------------------------+

View File

@ -1,7 +1,7 @@
// -*- C++ -*- // -*- C++ -*-
// //
// Copyright (c) BULL S.A. 2000-2009, All Rights Reserved // Copyright (c) BULL S.A. 2000-2014, All Rights Reserved
// //
// This file is part of Hurricane. // This file is part of Hurricane.
// //
@ -19,12 +19,7 @@
// License along with Hurricane. If not, see // License along with Hurricane. If not, see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
// //
// =================================================================== // +-----------------------------------------------------------------+
//
// $Id$
//
// x-----------------------------------------------------------------x
// | |
// | H U R R I C A N E | // | H U R R I C A N E |
// | V L S I B a c k e n d D a t a - B a s e | // | V L S I B a c k e n d D a t a - B a s e |
// | | // | |
@ -32,14 +27,11 @@
// | E-mail : Jean-Paul.Chaput@lip6.fr | // | E-mail : Jean-Paul.Chaput@lip6.fr |
// | =============================================================== | // | =============================================================== |
// | C++ Header : "./hurricane/RegularLayer.h" | // | C++ Header : "./hurricane/RegularLayer.h" |
// | *************************************************************** | // +-----------------------------------------------------------------+
// | U p d a t e s |
// | |
// x-----------------------------------------------------------------x
#ifndef __HURRICANE_REGULAR_LAYER__ #ifndef HURRICANE_REGULAR_LAYER_H
#define __HURRICANE_REGULAR_LAYER__ #define HURRICANE_REGULAR_LAYER_H
#include "hurricane/Layer.h" #include "hurricane/Layer.h"
#include "hurricane/RegularLayers.h" #include "hurricane/RegularLayers.h"
@ -98,10 +90,8 @@ namespace Hurricane {
inline BasicLayer* RegularLayer::getBasicLayer () const { return _basicLayer; } inline BasicLayer* RegularLayer::getBasicLayer () const { return _basicLayer; }
} // End of Hurricane namespace. } // Hurricane namespace.
INSPECTOR_P_SUPPORT(Hurricane::RegularLayer); INSPECTOR_P_SUPPORT(Hurricane::RegularLayer);
#endif // HURRICANE_REGULAR_LAYER_H
# endif

View File

@ -341,34 +341,37 @@ namespace Katabatic {
} }
void AutoContact::showTopologyError ( const std::string& message ) void AutoContact::showTopologyError ( const std::string& message, unsigned int flags )
{ {
Component* anchor = NULL; Component* anchor = NULL;
Horizontal** horizontals = new Horizontal* [10]; Horizontal** horizontals = new Horizontal* [10];
Vertical** verticals = new Vertical* [10]; Vertical** verticals = new Vertical* [10];
if (not (flags & KbCParanoid)) cparanoid.setStreamMask( mstream::PassThrough );
_getTopology ( anchor, horizontals, verticals, 10 ); _getTopology ( anchor, horizontals, verticals, 10 );
cerr << Error("In topology of %s",getString(this).c_str()) << endl; cparanoid << Error("In topology of %s",getString(this).c_str()) << endl;
if (anchor) cerr << " A: " << anchor << endl; if (anchor) cparanoid << " A: " << anchor << endl;
for ( size_t i=0 ; (i<10) and (horizontals[i] != NULL); ++i ) { for ( size_t i=0 ; (i<10) and (horizontals[i] != NULL); ++i ) {
AutoSegment* autoSegment = Session::lookup ( horizontals[i] ); AutoSegment* autoSegment = Session::lookup ( horizontals[i] );
if (autoSegment != NULL) if (autoSegment != NULL)
cerr << " " << (autoSegment->isGlobal()?'G':'L') << ": " << autoSegment << endl; cparanoid << " " << (autoSegment->isGlobal()?'G':'L') << ": " << autoSegment << endl;
else else
cerr << " ?: " << horizontals[i] << endl; cparanoid << " ?: " << horizontals[i] << endl;
} }
for ( size_t i=0 ; (i<10) and (verticals[i] != NULL); ++i ) { for ( size_t i=0 ; (i<10) and (verticals[i] != NULL); ++i ) {
AutoSegment* autoSegment = Session::lookup ( verticals[i] ); AutoSegment* autoSegment = Session::lookup ( verticals[i] );
if (autoSegment != NULL) if (autoSegment != NULL)
cerr << " " << (autoSegment->isGlobal()?'G':'L') << ": " << autoSegment << endl; cparanoid << " " << (autoSegment->isGlobal()?'G':'L') << ": " << autoSegment << endl;
else else
cerr << " ?: " << verticals[i] << endl; cparanoid << " ?: " << verticals[i] << endl;
} }
cerr << " " << message << endl; cparanoid << " " << message << endl;
if (not (flags & KbCParanoid)) cparanoid.unsetStreamMask( mstream::PassThrough );
delete [] horizontals; delete [] horizontals;
delete [] verticals; delete [] verticals;

View File

@ -298,7 +298,10 @@ namespace Katabatic {
ltrace(110) << "Cached: " << _segment << endl; ltrace(110) << "Cached: " << _segment << endl;
message << "Terminal horizontal segment Y " << DbU::getValueString(_segment->getY()) message << "Terminal horizontal segment Y " << DbU::getValueString(_segment->getY())
<< " axis is outside RoutingPad " << getUConstraints(KbVertical) << "."; << " axis is outside RoutingPad " << getUConstraints(KbVertical) << ".";
showTopologyError( message.str() );
unsigned int flags = 0;
if (_segment->isCreated()) flags |= KbCParanoid;
showTopologyError( message.str(), flags );
} else } else
setY( _segment->getY() ); setY( _segment->getY() );
} else { } else {
@ -306,7 +309,10 @@ namespace Katabatic {
ltrace(110) << "Cached: " << _segment << endl; ltrace(110) << "Cached: " << _segment << endl;
message << "Terminal vertical segment X" << DbU::getValueString(_segment->getX()) message << "Terminal vertical segment X" << DbU::getValueString(_segment->getX())
<< " axis is outside RoutingPad " << getUConstraints(KbHorizontal) << "."; << " axis is outside RoutingPad " << getUConstraints(KbHorizontal) << ".";
showTopologyError( message.str() );
unsigned int flags = 0;
if (_segment->isCreated()) flags |= KbCParanoid;
showTopologyError( message.str(), flags );
} else } else
setX( _segment->getX() ); setX( _segment->getX() );
} }

View File

@ -417,16 +417,16 @@ namespace Katabatic {
void AutoHorizontal::updatePositions () void AutoHorizontal::updatePositions ()
{ {
_sourcePosition = _horizontal->getSourceX() - Session::getExtensionCap(); _sourcePosition = _horizontal->getSourceX() - Session::getExtensionCap(getLayer());
_targetPosition = _horizontal->getTargetX() + Session::getExtensionCap(); _targetPosition = _horizontal->getTargetX() + Session::getExtensionCap(getLayer());
} }
bool AutoHorizontal::checkPositions () const bool AutoHorizontal::checkPositions () const
{ {
bool coherency = true; bool coherency = true;
DbU::Unit sourcePosition = _horizontal->getSourceX() - Session::getExtensionCap(); DbU::Unit sourcePosition = _horizontal->getSourceX() - Session::getExtensionCap(getLayer());
DbU::Unit targetPosition = _horizontal->getTargetX() + Session::getExtensionCap(); DbU::Unit targetPosition = _horizontal->getTargetX() + Session::getExtensionCap(getLayer());
if ( _sourcePosition != sourcePosition ) { if ( _sourcePosition != sourcePosition ) {
cerr << Error ( "%s\n Source position incoherency: " cerr << Error ( "%s\n Source position incoherency: "
@ -745,16 +745,14 @@ namespace Katabatic {
segment2->setFlags( (isSlackened()?SegSlackened:0) ); segment2->setFlags( (isSlackened()?SegSlackened:0) );
Session::dogleg( segment2 ); Session::dogleg( segment2 );
if (isStrongTerminal()) { if (isSourceTerminal()) {
if (autoSource->getAnchor()) {
segment1->setFlags( SegWeakTerminal1 ); segment1->setFlags( SegWeakTerminal1 );
segment2->setFlags( SegWeakTerminal1 ); segment2->setFlags( SegWeakTerminal1 );
} else { } else if (isTargetTerminal()) {
unsetFlags( SegStrongTerminal ); unsetFlags( SegTargetTerminal );
setFlags( SegWeakTerminal1 ); setFlags( SegWeakTerminal1 );
segment1->setFlags( SegWeakTerminal1 ); segment1->setFlags( SegWeakTerminal1 );
segment2->setFlags( SegStrongTerminal ); segment2->setFlags( SegTargetTerminal );
}
} else if (isWeakTerminal()) { } else if (isWeakTerminal()) {
segment1->setFlags( SegWeakTerminal1 ); segment1->setFlags( SegWeakTerminal1 );
segment2->setFlags( SegWeakTerminal1 ); segment2->setFlags( SegWeakTerminal1 );

View File

@ -325,7 +325,8 @@ namespace Katabatic {
_allocateds++; _allocateds++;
if (dynamic_cast<Horizontal*>(segment)) setFlags( SegHorizontal ); if (dynamic_cast<Horizontal*>(segment)) setFlags( SegHorizontal );
if (source->isTerminal() or target->isTerminal()) setFlags( SegStrongTerminal ); if (source->isTerminal()) setFlags( SegSourceTerminal );
if (target->isTerminal()) setFlags( SegTargetTerminal );
_gcell = source->getGCell(); _gcell = source->getGCell();
setOptimalMax ( isHorizontal() ? _gcell->getBoundingBox().getYMax() setOptimalMax ( isHorizontal() ? _gcell->getBoundingBox().getYMax()
@ -875,14 +876,19 @@ namespace Katabatic {
<< " T:" << target->isTerminal() << " T:" << target->isTerminal()
<< " " << this << endl; << " " << this << endl;
if (source->isTerminal() or target->isTerminal()) { if (source->isTerminal()) {
unsetFlags( SegWeakTerminal ); unsetFlags( SegWeakTerminal );
setFlags ( SegStrongTerminal ); setFlags ( SegSourceTerminal );
} else if (target->isTerminal()) {
unsetFlags( SegWeakTerminal );
setFlags ( SegTargetTerminal );
} else { } else {
unsigned int terminalFlag = 0; unsigned int terminalFlag = 0;
switch ( _getFlags() & SegWeakTerminal ) { switch ( _getFlags() & SegWeakTerminal ) {
case 0: break; case 0: break;
case SegStrongTerminal: terminalFlag = SegWeakTerminal1; break; case SegSourceTerminal|SegTargetTerminal:
case SegSourceTerminal:
case SegTargetTerminal: terminalFlag = SegWeakTerminal1; break;
case SegWeakTerminal1: terminalFlag = SegWeakTerminal1; break; case SegWeakTerminal1: terminalFlag = SegWeakTerminal1; break;
case SegWeakTerminal2: terminalFlag = SegWeakTerminal2; break; case SegWeakTerminal2: terminalFlag = SegWeakTerminal2; break;
default: default:
@ -1847,7 +1853,9 @@ namespace Katabatic {
) )
{ {
static const Layer* horizontalLayer = Session::getRoutingLayer( 1 ); static const Layer* horizontalLayer = Session::getRoutingLayer( 1 );
static DbU::Unit horizontalWidth = Session::getWireWidth ( 1 );
static const Layer* verticalLayer = Session::getRoutingLayer( 2 ); static const Layer* verticalLayer = Session::getRoutingLayer( 2 );
static DbU::Unit verticalWidth = Session::getWireWidth ( 2 );
bool reattachSource = false; bool reattachSource = false;
bool reattachTarget = false; bool reattachTarget = false;
@ -1922,6 +1930,7 @@ namespace Katabatic {
,getString(horizontal).c_str() ,getString(horizontal).c_str()
,getString(horizontalLayer).c_str()) << endl; ,getString(horizontalLayer).c_str()) << endl;
horizontal->setLayer( horizontalLayer ); horizontal->setLayer( horizontalLayer );
horizontal->setWidth( horizontalWidth );
} }
horizontal->setY( reference->getY() ); horizontal->setY( reference->getY() );
@ -1934,6 +1943,7 @@ namespace Katabatic {
,getString(vertical).c_str() ,getString(vertical).c_str()
,getString(verticalLayer).c_str()) << endl; ,getString(verticalLayer).c_str()) << endl;
vertical->setLayer( verticalLayer ); vertical->setLayer( verticalLayer );
vertical->setWidth( verticalWidth );
} }
vertical->setX( reference->getX() ); vertical->setX( reference->getX() );

View File

@ -360,16 +360,16 @@ namespace Katabatic {
void AutoVertical::updatePositions () void AutoVertical::updatePositions ()
{ {
_sourcePosition = _vertical->getSourceY() - Session::getExtensionCap(); _sourcePosition = _vertical->getSourceY() - Session::getExtensionCap(getLayer());
_targetPosition = _vertical->getTargetY() + Session::getExtensionCap(); _targetPosition = _vertical->getTargetY() + Session::getExtensionCap(getLayer());
} }
bool AutoVertical::checkPositions () const bool AutoVertical::checkPositions () const
{ {
bool coherency = true; bool coherency = true;
DbU::Unit sourcePosition = _vertical->getSourceY() - Session::getExtensionCap(); DbU::Unit sourcePosition = _vertical->getSourceY() - Session::getExtensionCap(getLayer());
DbU::Unit targetPosition = _vertical->getTargetY() + Session::getExtensionCap(); DbU::Unit targetPosition = _vertical->getTargetY() + Session::getExtensionCap(getLayer());
if ( _sourcePosition != sourcePosition ) { if ( _sourcePosition != sourcePosition ) {
cerr << Error ( "%s\n Source position incoherency: " cerr << Error ( "%s\n Source position incoherency: "
@ -665,16 +665,14 @@ namespace Katabatic {
segment2->setFlags( (isSlackened()?SegSlackened:0) ); segment2->setFlags( (isSlackened()?SegSlackened:0) );
Session::dogleg( segment2 ); Session::dogleg( segment2 );
if (isStrongTerminal()) { if (isSourceTerminal()) {
if (autoSource->getAnchor()) {
segment1->setFlags( SegWeakTerminal1 ); segment1->setFlags( SegWeakTerminal1 );
segment2->setFlags( SegWeakTerminal1 ); segment2->setFlags( SegWeakTerminal1 );
} else { } else if (isTargetTerminal()) {
unsetFlags( SegStrongTerminal ); unsetFlags( SegTargetTerminal );
setFlags( SegWeakTerminal1 ); setFlags( SegWeakTerminal1 );
segment1->setFlags( SegWeakTerminal1 ); segment1->setFlags( SegWeakTerminal1 );
segment2->setFlags( SegStrongTerminal ); segment2->setFlags( SegTargetTerminal );
}
} else if (isWeakTerminal()) { } else if (isWeakTerminal()) {
segment1->setFlags( SegWeakTerminal1 ); segment1->setFlags( SegWeakTerminal1 );
segment2->setFlags( SegWeakTerminal1 ); segment2->setFlags( SegWeakTerminal1 );

View File

@ -22,6 +22,7 @@
#include "hurricane/Error.h" #include "hurricane/Error.h"
#include "hurricane/Technology.h" #include "hurricane/Technology.h"
#include "hurricane/DataBase.h" #include "hurricane/DataBase.h"
#include "hurricane/RegularLayer.h"
#include "hurricane/Cell.h" #include "hurricane/Cell.h"
#include "crlcore/Utilities.h" #include "crlcore/Utilities.h"
#include "crlcore/CellGauge.h" #include "crlcore/CellGauge.h"
@ -47,6 +48,7 @@ namespace Katabatic {
using Hurricane::Error; using Hurricane::Error;
using Hurricane::Technology; using Hurricane::Technology;
using Hurricane::DataBase; using Hurricane::DataBase;
using Hurricane::RegularLayer;
using CRL::AllianceFramework; using CRL::AllianceFramework;
using CRL::RoutingGauge; using CRL::RoutingGauge;
using CRL::RoutingLayerGauge; using CRL::RoutingLayerGauge;
@ -68,7 +70,7 @@ namespace Katabatic {
: Configuration () : Configuration ()
, _cg (NULL) , _cg (NULL)
, _rg (NULL) , _rg (NULL)
, _extensionCap (DbU::lambda(0.5)) , _extensionCaps ()
, _saturateRatio (Cfg::getParamPercentage("katabatic.saturateRatio",80.0)->asDouble()) , _saturateRatio (Cfg::getParamPercentage("katabatic.saturateRatio",80.0)->asDouble())
, _saturateRp (Cfg::getParamInt ("katabatic.saturateRp" ,8 )->asInt()) , _saturateRp (Cfg::getParamInt ("katabatic.saturateRp" ,8 )->asInt())
, _globalThreshold(0) , _globalThreshold(0)
@ -98,15 +100,26 @@ namespace Katabatic {
_globalThreshold = DbU::fromLambda _globalThreshold = DbU::fromLambda
( (double)Cfg::getParamInt("katabatic.globalLengthThreshold",29*DbU::toLambda(sliceHeight))->asInt() ); ( (double)Cfg::getParamInt("katabatic.globalLengthThreshold",29*DbU::toLambda(sliceHeight))->asInt() );
vector<RoutingLayerGauge*>::const_iterator ilayerGauge = rg->getLayerGauges().begin(); const vector<RoutingLayerGauge*>& layerGauges = rg->getLayerGauges();
for ( ; ilayerGauge != rg->getLayerGauges().end() ; ++ilayerGauge ) { for ( size_t depth=0 ; depth < layerGauges.size() ; ++depth ) {
RoutingLayerGauge* layerGauge = (*ilayerGauge); const RegularLayer* regularLayer = dynamic_cast<const RegularLayer*>( layerGauges[depth]->getLayer() );
if (layerGauge->getType() != Constant::Default) continue; if (regularLayer)
_extensionCaps.push_back( regularLayer->getExtentionCap() );
else {
_extensionCaps.push_back( 0 );
cerr << Warning( "Routing layer at depth %d is *not* a RegularLayer, cannot guess extension cap.\n"
" (%s)"
, depth
, getString(layerGauges[depth]->getLayer()).c_str()
) << endl;
}
if (layerGauge->getDirection() == Constant::Horizontal) { if (layerGauges[depth]->getType() != Constant::Default) continue;
_hEdgeCapacity += layerGauge->getTrackNumber ( 0, sliceHeight ) - 1;
} else if (layerGauge->getDirection() == Constant::Vertical) { if (layerGauges[depth]->getDirection() == Constant::Horizontal) {
_vEdgeCapacity += layerGauge->getTrackNumber( 0, sliceHeight ) - 1; _hEdgeCapacity += layerGauges[depth]->getTrackNumber( 0, sliceHeight ) - 1;
} else if (layerGauges[depth]->getDirection() == Constant::Vertical) {
_vEdgeCapacity += layerGauges[depth]->getTrackNumber( 0, sliceHeight ) - 1;
} }
} }
} }
@ -119,7 +132,7 @@ namespace Katabatic {
, _gcontact (other._gcontact) , _gcontact (other._gcontact)
, _cg (NULL) , _cg (NULL)
, _rg (NULL) , _rg (NULL)
, _extensionCap (other._extensionCap) , _extensionCaps (other._extensionCaps)
, _saturateRatio (other._saturateRatio) , _saturateRatio (other._saturateRatio)
, _globalThreshold (other._globalThreshold) , _globalThreshold (other._globalThreshold)
, _allowedDepth (other._allowedDepth) , _allowedDepth (other._allowedDepth)
@ -185,10 +198,6 @@ namespace Katabatic {
{ return _rg->getContactLayer(depth); } { return _rg->getContactLayer(depth); }
DbU::Unit ConfigurationConcrete::getExtensionCap () const
{ return _extensionCap; }
DbU::Unit ConfigurationConcrete::getSliceHeight () const DbU::Unit ConfigurationConcrete::getSliceHeight () const
{ return _cg->getSliceHeight(); } { return _cg->getSliceHeight(); }
@ -205,6 +214,10 @@ namespace Katabatic {
{ return getOffset( getLayerDepth(layer) ); } { return getOffset( getLayerDepth(layer) ); }
DbU::Unit ConfigurationConcrete::getExtensionCap ( const Layer* layer ) const
{ return getExtensionCap( getLayerDepth(layer) ); }
DbU::Unit ConfigurationConcrete::getWireWidth ( const Layer* layer ) const DbU::Unit ConfigurationConcrete::getWireWidth ( const Layer* layer ) const
{ return getWireWidth( getLayerDepth(layer) ); } { return getWireWidth( getLayerDepth(layer) ); }
@ -248,6 +261,10 @@ namespace Katabatic {
{ return _rg->getLayerWireWidth(depth); } { return _rg->getLayerWireWidth(depth); }
DbU::Unit ConfigurationConcrete::getExtensionCap ( size_t depth ) const
{ return _extensionCaps[depth]; }
unsigned int ConfigurationConcrete::getDirection ( size_t depth ) const unsigned int ConfigurationConcrete::getDirection ( size_t depth ) const
{ return _rg->getLayerDirection(depth); } { return _rg->getLayerDirection(depth); }

View File

@ -446,11 +446,16 @@ namespace {
DbU::Unit height = abs( target.getY() - source.getY() ); DbU::Unit height = abs( target.getY() - source.getY() );
unsigned int flags = 0; unsigned int flags = 0;
// HARDCODED VALUE.
flags |= (width < 3*Session::getPitch(anchorDepth)) ? HSmall : 0; flags |= (width < 3*Session::getPitch(anchorDepth)) ? HSmall : 0;
flags |= (height < 3*Session::getPitch(anchorDepth)) ? VSmall : 0; flags |= (height < 3*Session::getPitch(anchorDepth)) ? VSmall : 0;
flags |= ((width == 0) && (height == 0)) ? Punctual : 0; flags |= ((width == 0) && (height == 0)) ? Punctual : 0;
ltrace(99) << "::checkRoutingPadSize(): pitch[" << anchorDepth << "]:"
<< DbU::toLambda(Session::getPitch(anchorDepth)) << " "
<< ((flags & HSmall) ? "HSmall " : " ")
<< ((flags & VSmall) ? "VSmall " : " ")
<< endl;
return flags; return flags;
} }
@ -1104,11 +1109,21 @@ namespace {
doRp_AutoContacts( gcell, rp, rpContactSource, rpContactTarget, flags ); doRp_AutoContacts( gcell, rp, rpContactSource, rpContactTarget, flags );
if ( not (flags & HAccess) and (flags & HSmall) ) { if (flags & HAccess) {
if (flags & VSmall) {
AutoContact* subContact1 = AutoContactTurn::create( gcell, rp->getNet(), Session::getContactLayer(1) );
AutoContact* subContact2 = AutoContactTurn::create( gcell, rp->getNet(), Session::getContactLayer(1) );
AutoSegment::create( rpContactSource, subContact1, KbHorizontal );
AutoSegment::create( subContact1, subContact2, KbVertical );
rpContactSource = subContact2;
}
} else {
if (flags & HSmall) {
AutoContact* subContact1 = AutoContactTurn::create( gcell, rp->getNet(), Session::getContactLayer(1) ); AutoContact* subContact1 = AutoContactTurn::create( gcell, rp->getNet(), Session::getContactLayer(1) );
AutoSegment::create( rpContactSource, subContact1, KbHorizontal ); AutoSegment::create( rpContactSource, subContact1, KbHorizontal );
rpContactSource = subContact1; rpContactSource = subContact1;
} }
}
ltraceout(99); ltraceout(99);

View File

@ -144,7 +144,7 @@ namespace Katabatic {
virtual void updateCache () = 0; virtual void updateCache () = 0;
virtual void updateGeometry () = 0; virtual void updateGeometry () = 0;
virtual void updateTopology () = 0; virtual void updateTopology () = 0;
void showTopologyError ( const std::string& ); void showTopologyError ( const std::string&, unsigned int flags=0 );
virtual void checkTopology (); virtual void checkTopology ();
inline void setFlags ( unsigned int ); inline void setFlags ( unsigned int );
inline void unsetFlags ( unsigned int ); inline void unsetFlags ( unsigned int );

View File

@ -74,11 +74,13 @@ namespace Katabatic {
, SegTargetTop = 0x00000400 , SegTargetTop = 0x00000400
, SegTargetBottom = 0x00000800 , SegTargetBottom = 0x00000800
, SegLayerChange = 0x00001000 , SegLayerChange = 0x00001000
, SegStrongTerminal = 0x00002000 // Replace Terminal. , SegSourceTerminal = 0x00002000 // Replace Terminal.
, SegWeakTerminal1 = 0x00004000 // Replace TopologicalEnd. , SegTargetTerminal = 0x00004000 // Replace Terminal.
, SegWeakTerminal2 = 0x00008000 // Replace TopologicalEnd. , SegStrongTerminal = SegSourceTerminal|SegTargetTerminal
, SegNotSourceAligned = 0x00010000 , SegWeakTerminal1 = 0x00008000 // Replace TopologicalEnd.
, SegNotTargetAligned = 0x00020000 , SegWeakTerminal2 = 0x00010000 // Replace TopologicalEnd.
, SegNotSourceAligned = 0x00020000
, SegNotTargetAligned = 0x00040000
, SegUnbound = 0x00100000 , SegUnbound = 0x00100000
, SegHalfSlackened = 0x00200000 , SegHalfSlackened = 0x00200000
, SegSlackened = 0x00400000 , SegSlackened = 0x00400000
@ -164,6 +166,8 @@ namespace Katabatic {
inline bool isNotTargetAligned () const; inline bool isNotTargetAligned () const;
inline bool isNotAligned () const; inline bool isNotAligned () const;
bool isStrongTerminal ( unsigned int flags=0 ) const; bool isStrongTerminal ( unsigned int flags=0 ) const;
inline bool isSourceTerminal () const;
inline bool isTargetTerminal () const;
bool isSameLayerDogleg () const; bool isSameLayerDogleg () const;
inline bool isLayerChange () const; inline bool isLayerChange () const;
inline bool isSpinTop () const; inline bool isSpinTop () const;
@ -426,6 +430,8 @@ namespace Katabatic {
inline bool AutoSegment::isWeakTerminal () const { return _flags & SegWeakTerminal; } inline bool AutoSegment::isWeakTerminal () const { return _flags & SegWeakTerminal; }
inline bool AutoSegment::isWeakTerminal1 () const { return _flags & SegWeakTerminal1; } inline bool AutoSegment::isWeakTerminal1 () const { return _flags & SegWeakTerminal1; }
inline bool AutoSegment::isWeakTerminal2 () const { return _flags & SegWeakTerminal2; } inline bool AutoSegment::isWeakTerminal2 () const { return _flags & SegWeakTerminal2; }
inline bool AutoSegment::isSourceTerminal () const { return _flags & SegSourceTerminal; }
inline bool AutoSegment::isTargetTerminal () const { return _flags & SegTargetTerminal; }
inline bool AutoSegment::isTerminal () const { return _flags & SegStrongTerminal; } inline bool AutoSegment::isTerminal () const { return _flags & SegStrongTerminal; }
inline bool AutoSegment::isNotSourceAligned () const { return _flags & SegNotSourceAligned; } inline bool AutoSegment::isNotSourceAligned () const { return _flags & SegNotSourceAligned; }
inline bool AutoSegment::isNotTargetAligned () const { return _flags & SegNotTargetAligned; } inline bool AutoSegment::isNotTargetAligned () const { return _flags & SegNotTargetAligned; }

View File

@ -18,6 +18,7 @@
#define KATABATIC_CONFIGURATION_H #define KATABATIC_CONFIGURATION_H
#include <string> #include <string>
#include <vector>
#include "hurricane/DbU.h" #include "hurricane/DbU.h"
namespace Hurricane { namespace Hurricane {
@ -68,16 +69,17 @@ namespace Katabatic {
virtual RoutingLayerGauge* getLayerGauge ( size_t depth ) const = 0; virtual RoutingLayerGauge* getLayerGauge ( size_t depth ) const = 0;
virtual const Layer* getRoutingLayer ( size_t depth ) const = 0; virtual const Layer* getRoutingLayer ( size_t depth ) const = 0;
virtual Layer* getContactLayer ( size_t depth ) const = 0; virtual Layer* getContactLayer ( size_t depth ) const = 0;
virtual DbU::Unit getExtensionCap () const = 0;
virtual DbU::Unit getSliceHeight () const = 0; virtual DbU::Unit getSliceHeight () const = 0;
virtual DbU::Unit getSliceStep () const = 0; virtual DbU::Unit getSliceStep () const = 0;
virtual DbU::Unit getPitch ( size_t depth, unsigned int flags ) const = 0; virtual DbU::Unit getPitch ( size_t depth, unsigned int flags ) const = 0;
virtual DbU::Unit getOffset ( size_t depth ) const = 0; virtual DbU::Unit getOffset ( size_t depth ) const = 0;
virtual DbU::Unit getWireWidth ( size_t depth ) const = 0; virtual DbU::Unit getWireWidth ( size_t depth ) const = 0;
virtual DbU::Unit getExtensionCap ( size_t depth ) const = 0;
virtual unsigned int getDirection ( size_t depth ) const = 0; virtual unsigned int getDirection ( size_t depth ) const = 0;
virtual DbU::Unit getPitch ( const Layer*, unsigned int flags ) const = 0; virtual DbU::Unit getPitch ( const Layer*, unsigned int flags ) const = 0;
virtual DbU::Unit getOffset ( const Layer* ) const = 0; virtual DbU::Unit getOffset ( const Layer* ) const = 0;
virtual DbU::Unit getWireWidth ( const Layer* ) const = 0; virtual DbU::Unit getWireWidth ( const Layer* ) const = 0;
virtual DbU::Unit getExtensionCap ( const Layer* ) const = 0;
virtual unsigned int getDirection ( const Layer* ) const = 0; virtual unsigned int getDirection ( const Layer* ) const = 0;
virtual float getSaturateRatio () const = 0; virtual float getSaturateRatio () const = 0;
virtual size_t getSaturateRp () const = 0; virtual size_t getSaturateRp () const = 0;
@ -124,16 +126,17 @@ namespace Katabatic {
virtual RoutingLayerGauge* getLayerGauge ( size_t depth ) const; virtual RoutingLayerGauge* getLayerGauge ( size_t depth ) const;
virtual const Layer* getRoutingLayer ( size_t depth ) const; virtual const Layer* getRoutingLayer ( size_t depth ) const;
virtual Layer* getContactLayer ( size_t depth ) const; virtual Layer* getContactLayer ( size_t depth ) const;
virtual DbU::Unit getExtensionCap () const;
virtual DbU::Unit getSliceHeight () const; virtual DbU::Unit getSliceHeight () const;
virtual DbU::Unit getSliceStep () const; virtual DbU::Unit getSliceStep () const;
virtual DbU::Unit getPitch ( size_t depth, unsigned int flags ) const; virtual DbU::Unit getPitch ( size_t depth, unsigned int flags ) const;
virtual DbU::Unit getOffset ( size_t depth ) const; virtual DbU::Unit getOffset ( size_t depth ) const;
virtual DbU::Unit getWireWidth ( size_t depth ) const; virtual DbU::Unit getWireWidth ( size_t depth ) const;
virtual DbU::Unit getExtensionCap ( size_t depth ) const;
virtual unsigned int getDirection ( size_t depth ) const; virtual unsigned int getDirection ( size_t depth ) const;
virtual DbU::Unit getPitch ( const Layer*, unsigned int flags ) const; virtual DbU::Unit getPitch ( const Layer*, unsigned int flags ) const;
virtual DbU::Unit getOffset ( const Layer* ) const; virtual DbU::Unit getOffset ( const Layer* ) const;
virtual DbU::Unit getWireWidth ( const Layer* ) const; virtual DbU::Unit getWireWidth ( const Layer* ) const;
virtual DbU::Unit getExtensionCap ( const Layer* ) const;
virtual unsigned int getDirection ( const Layer* ) const; virtual unsigned int getDirection ( const Layer* ) const;
virtual float getSaturateRatio () const; virtual float getSaturateRatio () const;
virtual size_t getSaturateRp () const; virtual size_t getSaturateRp () const;
@ -155,7 +158,7 @@ namespace Katabatic {
const Layer* _gcontact; const Layer* _gcontact;
CellGauge* _cg; CellGauge* _cg;
RoutingGauge* _rg; RoutingGauge* _rg;
DbU::Unit _extensionCap; std::vector<DbU::Unit> _extensionCaps;
float _saturateRatio; float _saturateRatio;
size_t _saturateRp; size_t _saturateRp;
DbU::Unit _globalThreshold; DbU::Unit _globalThreshold;

View File

@ -45,6 +45,7 @@ namespace Katabatic {
, KbNoCheckLayer = 0x00400000 , KbNoCheckLayer = 0x00400000
, KbHalfSlacken = 0x00800000 , KbHalfSlacken = 0x00800000
, KbNoGCellShrink = 0x01000000 , KbNoGCellShrink = 0x01000000
, KbCParanoid = 0x02000000
, KbDirectionMask = KbHorizontal|KbVertical , KbDirectionMask = KbHorizontal|KbVertical
}; };

View File

@ -230,7 +230,6 @@ namespace Katabatic {
inline DbU::Unit KatabaticEngine::getGlobalThreshold () const { return _configuration->getGlobalThreshold(); } inline DbU::Unit KatabaticEngine::getGlobalThreshold () const { return _configuration->getGlobalThreshold(); }
inline float KatabaticEngine::getSaturateRatio () const { return _configuration->getSaturateRatio(); } inline float KatabaticEngine::getSaturateRatio () const { return _configuration->getSaturateRatio(); }
inline size_t KatabaticEngine::getSaturateRp () const { return _configuration->getSaturateRp(); } inline size_t KatabaticEngine::getSaturateRp () const { return _configuration->getSaturateRp(); }
inline DbU::Unit KatabaticEngine::getExtensionCap () const { return _configuration->getExtensionCap(); }
inline const AutoContactLut& KatabaticEngine::_getAutoContactLut () const { return _autoContactLut; } inline const AutoContactLut& KatabaticEngine::_getAutoContactLut () const { return _autoContactLut; }
inline const AutoSegmentLut& KatabaticEngine::_getAutoSegmentLut () const { return _autoSegmentLut; } inline const AutoSegmentLut& KatabaticEngine::_getAutoSegmentLut () const { return _autoSegmentLut; }
inline void KatabaticEngine::setState ( EngineState state ) { _state = state; } inline void KatabaticEngine::setState ( EngineState state ) { _state = state; }

View File

@ -103,6 +103,7 @@ namespace Katabatic {
static inline DbU::Unit getOffset ( const Layer* ); static inline DbU::Unit getOffset ( const Layer* );
static inline DbU::Unit getWireWidth ( const Layer* ); static inline DbU::Unit getWireWidth ( const Layer* );
static inline DbU::Unit getViaWidth ( const Layer* ); static inline DbU::Unit getViaWidth ( const Layer* );
static inline DbU::Unit getExtensionCap ( const Layer* );
static inline size_t getSegmentStackSize (); static inline size_t getSegmentStackSize ();
static inline size_t getContactStackSize (); static inline size_t getContactStackSize ();
static inline const vector<AutoSegment*>& getInvalidateds (); static inline const vector<AutoSegment*>& getInvalidateds ();
@ -198,7 +199,6 @@ namespace Katabatic {
inline void Session::dogleg ( AutoSegment* autoSegment ) { return get("dogleg(AutoSegment*)")->_dogleg(autoSegment); } inline void Session::dogleg ( AutoSegment* autoSegment ) { return get("dogleg(AutoSegment*)")->_dogleg(autoSegment); }
inline void Session::destroyRequest ( AutoSegment* autoSegment ) { return get("destroyRequest(AutoSegment*)")->_destroyRequest(autoSegment); } inline void Session::destroyRequest ( AutoSegment* autoSegment ) { return get("destroyRequest(AutoSegment*)")->_destroyRequest(autoSegment); }
inline DbU::Unit Session::getExtensionCap () { return getConfiguration()->getExtensionCap(); }
inline size_t Session::getAllowedDepth () { return getConfiguration()->getAllowedDepth(); } inline size_t Session::getAllowedDepth () { return getConfiguration()->getAllowedDepth(); }
inline DbU::Unit Session::getSliceHeight () { return getCellGauge()->getSliceHeight(); } inline DbU::Unit Session::getSliceHeight () { return getCellGauge()->getSliceHeight(); }
@ -217,6 +217,7 @@ namespace Katabatic {
inline DbU::Unit Session::getOffset ( const Layer* layer ) { return getOffset ( getLayerDepth(layer) ); } inline DbU::Unit Session::getOffset ( const Layer* layer ) { return getOffset ( getLayerDepth(layer) ); }
inline DbU::Unit Session::getWireWidth ( const Layer* layer ) { return getWireWidth( getLayerDepth(layer) ); } inline DbU::Unit Session::getWireWidth ( const Layer* layer ) { return getWireWidth( getLayerDepth(layer) ); }
inline DbU::Unit Session::getViaWidth ( const Layer* layer ) { return getViaWidth ( getViaDepth(layer) ); } inline DbU::Unit Session::getViaWidth ( const Layer* layer ) { return getViaWidth ( getViaDepth(layer) ); }
inline DbU::Unit Session::getExtensionCap ( const Layer* layer ) { return getConfiguration()->getExtensionCap(layer); }
inline unsigned int Session::getDirection ( const Layer* layer ) { return getDirection( getLayerDepth(layer) ); } inline unsigned int Session::getDirection ( const Layer* layer ) { return getDirection( getLayerDepth(layer) ); }
inline void Session::_dogleg ( AutoSegment* segment ) { _doglegs.push_back(segment); } inline void Session::_dogleg ( AutoSegment* segment ) { _doglegs.push_back(segment); }

View File

@ -871,6 +871,7 @@ namespace {
_planes.insert( make_pair(regular->getBasicLayer(),new Plane(regular,rp)) ); _planes.insert( make_pair(regular->getBasicLayer(),new Plane(regular,rp)) );
if (lg->getType() == Constant::PinOnly) continue;
const BasicLayer* blockageLayer = regular->getBasicLayer()->getBlockageLayer(); const BasicLayer* blockageLayer = regular->getBasicLayer()->getBlockageLayer();
if (not blockageLayer) continue; if (not blockageLayer) continue;
@ -1014,10 +1015,6 @@ namespace {
PowerRailsPlanes::Plane* activePlane = _powerRailsPlanes.getActivePlane(); PowerRailsPlanes::Plane* activePlane = _powerRailsPlanes.getActivePlane();
if (not activePlane) return; if (not activePlane) return;
// if (activePlane->getRoutingPlane()->getLayerGauge()->getType() == Constant::PinOnly) {
// cmess1 << " - PowerRails in " << activePlane->getLayer()->getName() << " - Skipped (PinOnly layer)." << endl;
// return;
// }
cmess1 << " - PowerRails in " << activePlane->getLayer()->getName() << " ..." << endl; cmess1 << " - PowerRails in " << activePlane->getLayer()->getName() << " ..." << endl;
Query::doQuery(); Query::doQuery();

View File

@ -165,6 +165,10 @@ namespace Kite {
{ return _base->getWireWidth(depth); } { return _base->getWireWidth(depth); }
DbU::Unit Configuration::getExtensionCap ( size_t depth ) const
{ return _base->getExtensionCap(depth); }
unsigned int Configuration::getDirection ( size_t depth ) const unsigned int Configuration::getDirection ( size_t depth ) const
{ return _base->getDirection(depth); } { return _base->getDirection(depth); }
@ -185,8 +189,8 @@ namespace Kite {
{ return _base->getDirection(layer); } { return _base->getDirection(layer); }
DbU::Unit Configuration::getExtensionCap () const DbU::Unit Configuration::getExtensionCap ( const Layer* layer ) const
{ return _base->getExtensionCap(); } { return _base->getExtensionCap(layer); }
float Configuration::getSaturateRatio () const float Configuration::getSaturateRatio () const

View File

@ -449,6 +449,9 @@ namespace Kite {
createGlobalGraph( mode ); createGlobalGraph( mode );
// Test signals from <multi4_a>.
//DebugSession::addToTrace( getCell(), "aux34" );
// Test signals from <addaccu>. // Test signals from <addaccu>.
//DebugSession::addToTrace( getCell(), "auxsc37" ); //DebugSession::addToTrace( getCell(), "auxsc37" );
// Test signals from <amd2901_core_flat>. // Test signals from <amd2901_core_flat>.

View File

@ -271,7 +271,7 @@ namespace Kite {
bool Manipulator::relax ( Interval interval, unsigned int flags ) bool Manipulator::relax ( Interval interval, unsigned int flags )
{ {
interval.inflate( - Session::getExtensionCap() ); interval.inflate( - Session::getExtensionCap(getLayer()) );
ltrace(200) << "Manipulator::relax() of: " << _segment << " " << interval << endl; ltrace(200) << "Manipulator::relax() of: " << _segment << " " << interval << endl;
if (_segment->isFixed()) return false; if (_segment->isFixed()) return false;
@ -741,7 +741,7 @@ namespace Kite {
if ( event3->getTracksFree() == 1 ) { if ( event3->getTracksFree() == 1 ) {
ltrace(200) << "Potential left intrication with other perpandicular." << endl; ltrace(200) << "Potential left intrication with other perpandicular." << endl;
if ( isegment3->getAxis() == segment2->getTargetU() - Session::getExtensionCap() ) { if ( isegment3->getAxis() == segment2->getTargetU() - Session::getExtensionCap(getLayer()) ) {
leftIntrication = true; leftIntrication = true;
leftAxisHint = isegment3->getAxis(); leftAxisHint = isegment3->getAxis();
} }
@ -755,7 +755,7 @@ namespace Kite {
break; break;
if ( event3->getTracksFree() == 1 ) { if ( event3->getTracksFree() == 1 ) {
ltrace(200) << "Potential right intrication with other perpandicular." << endl; ltrace(200) << "Potential right intrication with other perpandicular." << endl;
if ( isegment3->getAxis() == segment2->getSourceU() + Session::getExtensionCap() ) { if ( isegment3->getAxis() == segment2->getSourceU() + Session::getExtensionCap(getLayer()) ) {
rightIntrication = true; rightIntrication = true;
rightAxisHint = isegment3->getAxis(); rightAxisHint = isegment3->getAxis();
} }
@ -861,8 +861,8 @@ namespace Kite {
Net* ownerNet = _segment->getNet(); Net* ownerNet = _segment->getNet();
set<TrackElement*> canonicals; set<TrackElement*> canonicals;
bool success = true; bool success = true;
DbU::Unit leftExtend = _segment->getSourceU() + Session::getExtensionCap(); DbU::Unit leftExtend = _segment->getSourceU() + Session::getExtensionCap(getLayer());
DbU::Unit rightExtend = _segment->getSourceU() - Session::getExtensionCap(); DbU::Unit rightExtend = _segment->getSourceU() - Session::getExtensionCap(getLayer());
ltrace(200) << "Manipulator::shrinkToTrack()" << endl; ltrace(200) << "Manipulator::shrinkToTrack()" << endl;
@ -1377,10 +1377,10 @@ namespace Kite {
// Ugly: ExtensionCap usage. // Ugly: ExtensionCap usage.
if ( moveLeft ) { if ( moveLeft ) {
if ( perpandicular->getTargetU()-Session::getExtensionCap() == _event->getAxisHistory() ) if ( perpandicular->getTargetU()-Session::getExtensionCap(getLayer()) == _event->getAxisHistory() )
_fsm.addAction ( perpandicular, SegmentAction::OtherRipupPerpandAndPacking ); _fsm.addAction ( perpandicular, SegmentAction::OtherRipupPerpandAndPacking );
} else { } else {
if ( perpandicular->getSourceU()+Session::getExtensionCap() == _event->getAxisHistory() ) if ( perpandicular->getSourceU()+Session::getExtensionCap(getLayer()) == _event->getAxisHistory() )
_fsm.addAction ( perpandicular, SegmentAction::OtherRipupPerpandAndPacking ); _fsm.addAction ( perpandicular, SegmentAction::OtherRipupPerpandAndPacking );
} }
} }

View File

@ -1,8 +1,7 @@
// -*- C++ -*- // -*- C++ -*-
// //
// This file is part of the Coriolis Software. // This file is part of the Coriolis Software.
// Copyright (c) UPMC 2008-2013, All Rights Reserved // Copyright (c) UPMC 2008-2014, All Rights Reserved
// //
// +-----------------------------------------------------------------+ // +-----------------------------------------------------------------+
// | C O R I O L I S | // | C O R I O L I S |
@ -238,7 +237,7 @@ namespace Kite {
Interval blockageSpan; Interval blockageSpan;
autoSegment->getCanonical( fixedSpan ); autoSegment->getCanonical( fixedSpan );
fixedSpan.inflate( Session::getExtensionCap()-1 ); fixedSpan.inflate( Session::getExtensionCap(autoSegment->getLayer())-1 );
track->getOverlapBounds( fixedSpan, begin, end ); track->getOverlapBounds( fixedSpan, begin, end );
for ( ; (begin < end) ; begin++ ) { for ( ; (begin < end) ; begin++ ) {
@ -249,7 +248,7 @@ namespace Kite {
if (not other->isBlockage()) continue; if (not other->isBlockage()) continue;
other->getCanonical( blockageSpan ); other->getCanonical( blockageSpan );
blockageSpan.inflate( Session::getExtensionCap() ); blockageSpan.inflate( Session::getExtensionCap(autoSegment->getLayer()) );
ltrace(200) << " fixed:" << fixedSpan << " vs. blockage:" << blockageSpan << endl; ltrace(200) << " fixed:" << fixedSpan << " vs. blockage:" << blockageSpan << endl;

View File

@ -161,7 +161,7 @@ namespace Kite {
: _cloned (false) : _cloned (false)
, _processed (false) , _processed (false)
, _disabled (false) , _disabled (false)
, _canHandleConstraints(false) , _overConstrained (false)
, _minimized (false) , _minimized (false)
, _forceToHint (false) , _forceToHint (false)
, _ripedByLocal (false) , _ripedByLocal (false)
@ -397,7 +397,7 @@ namespace Kite {
DebugSession::open( _segment->getNet(), 148 ); DebugSession::open( _segment->getNet(), 148 );
ltrace(500) << "Deter| Event" ltrace(500) << "Deter| Event "
<< getProcesseds() << getProcesseds()
<< "," << getEventLevel() << "," << getEventLevel()
<< "," << setw(6) << getPriority() << "," << setw(6) << getPriority()
@ -468,7 +468,7 @@ namespace Kite {
ltrace(200) << "| " << fsm.getCost(itrack) << endl; ltrace(200) << "| " << fsm.getCost(itrack) << endl;
itrack = 0; itrack = 0;
if (Manipulator(_segment,fsm).canRipup()) { if ( (not isOverConstrained()) and Manipulator(_segment,fsm).canRipup() ) {
if (fsm.getCosts().size() and fsm.getCost(itrack).isFree()) { if (fsm.getCosts().size() and fsm.getCost(itrack).isFree()) {
ltrace(200) << "Insert in free space " << this << endl; ltrace(200) << "Insert in free space " << this << endl;
resetInsertState(); resetInsertState();
@ -501,6 +501,10 @@ namespace Kite {
} }
} else { } else {
// Ripup limit has been reached. // Ripup limit has been reached.
if (isOverConstrained()) {
ltrace(200) << "Immediate slackening due to overconstraint" << endl;
fsm.getData()->setState( DataNegociate::Slacken );
}
if (not fsm.slackenTopology()) { if (not fsm.slackenTopology()) {
fsm.setState( SegmentFsm::SelfMaximumSlack ); fsm.setState( SegmentFsm::SelfMaximumSlack );
} }
@ -606,7 +610,7 @@ namespace Kite {
setAxisHintFromParent(); setAxisHintFromParent();
ltrace(200) << "axisHint:" << DbU::getValueString(getAxisHint()) << endl; ltrace(200) << "axisHint:" << DbU::getValueString(getAxisHint()) << endl;
_canHandleConstraints = true; _overConstrained = false;
_segment->base()->getConstraints( _constraints ); _segment->base()->getConstraints( _constraints );
_segment->base()->getOptimal ( _optimal ); _segment->base()->getOptimal ( _optimal );
@ -644,12 +648,12 @@ namespace Kite {
if ( track && (track->getAxis() < _constraints.getVMin()) ) track = track->getNextTrack(); if ( track && (track->getAxis() < _constraints.getVMin()) ) track = track->getNextTrack();
for ( ; track && (track->getAxis() <= _constraints.getVMax()) for ( ; track && (track->getAxis() <= _constraints.getVMax())
; track = track->getNextTrack(), _tracksNb++ ); ; track = track->getNextTrack(), _tracksNb++ );
_canHandleConstraints = false;
} }
if (not _tracksNb) { if (not _tracksNb) {
ltrace(200) << "| Pure constraints are too tight." << endl; ltrace(200) << "| Pure constraints are too tight." << endl;
_canHandleConstraints = false; if (_segment->base())
_overConstrained = _segment->base()->getAutoSource()->isTerminal()
and _segment->base()->getAutoTarget()->isTerminal();
} }
_priority _priority

View File

@ -71,12 +71,13 @@ namespace Kite {
virtual DbU::Unit getPitch ( size_t depth, unsigned int flags ) const; virtual DbU::Unit getPitch ( size_t depth, unsigned int flags ) const;
virtual DbU::Unit getOffset ( size_t depth ) const; virtual DbU::Unit getOffset ( size_t depth ) const;
virtual DbU::Unit getWireWidth ( size_t depth ) const; virtual DbU::Unit getWireWidth ( size_t depth ) const;
virtual DbU::Unit getExtensionCap ( size_t depth ) const;
virtual unsigned int getDirection ( size_t depth ) const; virtual unsigned int getDirection ( size_t depth ) const;
virtual DbU::Unit getPitch ( const Layer*, unsigned int flags ) const; virtual DbU::Unit getPitch ( const Layer*, unsigned int flags ) const;
virtual DbU::Unit getOffset ( const Layer* ) const; virtual DbU::Unit getOffset ( const Layer* ) const;
virtual DbU::Unit getWireWidth ( const Layer* ) const; virtual DbU::Unit getWireWidth ( const Layer* ) const;
virtual unsigned int getDirection ( const Layer* ) const; virtual unsigned int getDirection ( const Layer* ) const;
virtual DbU::Unit getExtensionCap () const; virtual DbU::Unit getExtensionCap ( const Layer* ) const;
virtual float getSaturateRatio () const; virtual float getSaturateRatio () const;
virtual size_t getSaturateRp () const; virtual size_t getSaturateRp () const;
virtual DbU::Unit getGlobalThreshold () const; virtual DbU::Unit getGlobalThreshold () const;

View File

@ -56,6 +56,7 @@ namespace Kite {
inline TrackElement* getSegment () const; inline TrackElement* getSegment () const;
inline DataNegociate* getData () const; inline DataNegociate* getData () const;
inline RoutingEvent* getEvent () const; inline RoutingEvent* getEvent () const;
inline const Layer* getLayer () const;
inline DbU::Unit getPitch () const; inline DbU::Unit getPitch () const;
inline DbU::Unit getPPitch () const; inline DbU::Unit getPPitch () const;
bool canRipup ( unsigned int flags=0 ) const; bool canRipup ( unsigned int flags=0 ) const;
@ -93,6 +94,7 @@ namespace Kite {
inline TrackElement* Manipulator::getSegment () const { return _segment; } inline TrackElement* Manipulator::getSegment () const { return _segment; }
inline DataNegociate* Manipulator::getData () const { return _data; } inline DataNegociate* Manipulator::getData () const { return _data; }
inline RoutingEvent* Manipulator::getEvent () const { return _event; } inline RoutingEvent* Manipulator::getEvent () const { return _event; }
inline const Layer* Manipulator::getLayer () const { return _segment->getLayer(); }
inline DbU::Unit Manipulator::getPitch () const { return _segment->getPitch(); } inline DbU::Unit Manipulator::getPitch () const { return _segment->getPitch(); }
inline DbU::Unit Manipulator::getPPitch () const { return _segment->getPPitch(); } inline DbU::Unit Manipulator::getPPitch () const { return _segment->getPPitch(); }

View File

@ -1,7 +1,7 @@
// -*- C++ -*- // -*- C++ -*-
// //
// This file is part of the Coriolis Software. // This file is part of the Coriolis Software.
// Copyright (c) UPMC 2008-2013, All Rights Reserved // Copyright (c) UPMC 2008-2014, All Rights Reserved
// //
// +-----------------------------------------------------------------+ // +-----------------------------------------------------------------+
// | C O R I O L I S | // | C O R I O L I S |
@ -113,6 +113,7 @@ namespace Kite {
inline bool isForcedToHint () const; inline bool isForcedToHint () const;
inline bool isSheared () const; inline bool isSheared () const;
inline bool isRipedByLocal () const; inline bool isRipedByLocal () const;
inline bool isOverConstrained () const;
inline unsigned int getId () const; inline unsigned int getId () const;
inline bool getMode () const; inline bool getMode () const;
inline bool canMinimize () const; inline bool canMinimize () const;
@ -172,7 +173,7 @@ namespace Kite {
mutable bool _cloned; mutable bool _cloned;
bool _processed; bool _processed;
bool _disabled; bool _disabled;
bool _canHandleConstraints; bool _overConstrained;
bool _minimized; bool _minimized;
bool _forceToHint; bool _forceToHint;
bool _ripedByLocal; bool _ripedByLocal;
@ -202,6 +203,7 @@ namespace Kite {
inline bool RoutingEvent::isDisabled () const { return _disabled; } inline bool RoutingEvent::isDisabled () const { return _disabled; }
inline bool RoutingEvent::isForcedToHint () const { return _forceToHint; } inline bool RoutingEvent::isForcedToHint () const { return _forceToHint; }
inline bool RoutingEvent::isRipedByLocal () const { return _ripedByLocal; } inline bool RoutingEvent::isRipedByLocal () const { return _ripedByLocal; }
inline bool RoutingEvent::isOverConstrained () const { return _overConstrained; }
inline unsigned int RoutingEvent::getId () const { return _id; } inline unsigned int RoutingEvent::getId () const { return _id; }
inline bool RoutingEvent::getMode () const { return _mode; } inline bool RoutingEvent::getMode () const { return _mode; }
inline bool RoutingEvent::canMinimize () const { return !_minimized; } inline bool RoutingEvent::canMinimize () const { return !_minimized; }

View File

@ -1,7 +1,7 @@
// -*- C++ -*- // -*- C++ -*-
// //
// This file is part of the Coriolis Software. // This file is part of the Coriolis Software.
// Copyright (c) UPMC 2008-2013, All Rights Reserved // Copyright (c) UPMC 2008-2014, All Rights Reserved
// //
// +-----------------------------------------------------------------+ // +-----------------------------------------------------------------+
// | C O R I O L I S | // | C O R I O L I S |

View File

@ -119,7 +119,7 @@ namespace Metis {
bool MetisEngine::isHMetisCapable () bool MetisEngine::isHMetisCapable ()
{ {
#ifdef HAVE_HMETIS_LIB #ifdef HAVE_HMETIS_LIB
return true; return false;
#else #else
return false; return false;
#endif // HAVE_HMETIS_LIB #endif // HAVE_HMETIS_LIB