coriolis/crlcore/etc/node600/phenitec/kite.py

231 lines
15 KiB
Python
Raw Normal View History

Support for full Database clear & restart. * New: In CRL/etc/node600/phenitec, ported configuration of Phenitec 0.6um Compliant with DataBase reset. * New: In CRL/python/helpers, added function "unloadUserSettings()" to unload Python modules prior to a full reset. Added "resetCoriolis()" to perform full DataBase reset. * Change: In CRL::AllianceFramework, make it a derived class of DBo so the destroy() is now provided. * Bug: In CRL::AllianceFramework::getCell(), do not attempt any load if the library list is empty. Should never occur except in case of a botched databse reset. * New: In CRL::AllianceFramework, new method "saveCATAL()" to write back the catalog of a library and "saveCells()" to write back the cells. Note: only cells actually loaded in memory will be write back. * New: In CRL::Catalog, add method "saveToFile()" to write back the CATAL of a library. * Change: In CRL::ParserDriver, replace "const string&" by "string" (improved string support of the GNU STL). * Change: In CRL::ParserSlot, use string instead of Name. * Change: In CRL::ApParser, make _layerInformation an ordinary attribute instead of a static one. This allow for it's correct resetting across databas resets. * Change: In CRL::VstParserGrammar, reinitialize Vst::framework at each parser call. Needed to support database reset. * New: In Hurricane::DBo, add an object counter to be sure that when we perform a reset, no remaining DBo is allocated. This is different of the object id which is ever increasing. Note that, at reset, we check against "1" remaining element as at this point only Database is still allocated. Add a new "resetId()" method. MUST NEVER BE CALLED except by DataBase::_preDestroy(). * New: In Hurricane::Database, new clear() method to remove the Cells of all the libraries in reverse hierarchical depth order. Make use of the new CellsSort class. * Change: In Hurricane::DataBase::_preDestroy(), call "clear()" and DBo::resetId(). * Change: In Hurricane::Breakpoint, change the default callback to be a static function. So we can restore it later. * Bug: In Hurricane::Instance::_preDestroy(), there was yet another loop of deletion over a collection for the shared pathes. Replace it by the repetitive deletion of the first element. * Bug: In Hurricane::Net::_preDestroy(), RoutingPads must be destroyed prior to any other component. * New: In Hurricane::ColorScale, add a "qtFree()" method for freeing the Qt Brush, Pen & Color. * New: In Hurricane::DrawingStyle, add a "qtFree()" method for freeing the Qt Brush, Pen & Color. * New: In Hurricane::Graphics, add a "disable()" method to call the various "qtFree()" of the sub-objects.
2020-02-29 09:55:14 -06:00
# This file is part of the Coriolis Software.
# Copyright (c) UPMC 2019-2019, All Rights Reserved
#
# +-----------------------------------------------------------------+
# | C O R I O L I S |
# | Alliance / Hurricane Interface |
# | |
# | Author : Jean-Paul CHAPUT |
# | E-mail : Jean-Paul.Chaput@lip6.fr |
# | =============================================================== |
# | Python : "./etc/node600/phenitec/kite.py" |
# +-----------------------------------------------------------------+
import Cfg
import helpers.io
helpers.io.vprint( 2, ' - "%s".' % helpers.truncPath(__file__) )
from Hurricane import DataBase
from CRL import AllianceFramework
from CRL import RoutingGauge
from CRL import RoutingLayerGauge
from CRL import CellGauge
from helpers import l, n, u
import common.kite
p = Cfg.getParamDouble ( 'lefImport.minTerminalWidth' ).setDouble ( 0.0 )
p = Cfg.getParamString ( 'katabatic.routingGauge' ).setString ( 'nsxlib-3M' )
p = Cfg.getParamInt ( "katabatic.globalLengthThreshold" ).setInt ( 1450 )
p = Cfg.getParamPercentage( "katabatic.saturateRatio" ).setPercentage( 80 )
p = Cfg.getParamInt ( "katabatic.saturateRp" ).setInt ( 8 )
p = Cfg.getParamString ( 'katabatic.topRoutingLayer' ).setString ( 'METAL3' )
# Kite parameters.
p = Cfg.getParamInt( "kite.hTracksReservedLocal" ); p.setInt( 4 ); p.setMin( 0 ); p.setMax( 18 )
p = Cfg.getParamInt( "kite.vTracksReservedLocal" ); p.setInt( 3 ); p.setMin( 0 ); p.setMax( 18 )
p = Cfg.getParamInt( "kite.eventsLimit" ); p.setInt( 4000002 )
p = Cfg.getParamInt( "kite.ripupCost" ); p.setInt( 3 ); p.setMin( 0 )
p = Cfg.getParamInt( "kite.strapRipupLimit" ); p.setInt( 16 ); p.setMin( 1 )
p = Cfg.getParamInt( "kite.localRipupLimit" ); p.setInt( 9 ); p.setMin( 1 )
p = Cfg.getParamInt( "kite.globalRipupLimit" ); p.setInt( 5 ); p.setMin( 1 )
p = Cfg.getParamInt( "kite.longGlobalRipupLimit" ); p.setInt( 5 ); p.setMin( 1 )
# Anabatic & Katana parameters are temporarily hosted here.
p = Cfg.getParamString ( 'anabatic.routingGauge' ); p.setString ( 'nsxlib-3M' )
p = Cfg.getParamInt ( "anabatic.globalLengthThreshold" ); p.setInt ( 1450 )
p = Cfg.getParamPercentage( "anabatic.saturateRatio" ); p.setPercentage( 80 )
p = Cfg.getParamInt ( "anabatic.saturateRp" ); p.setInt ( 8 )
p = Cfg.getParamString ( 'anabatic.topRoutingLayer' ); p.setString ( 'METAL3' )
p = Cfg.getParamInt ( "anabatic.edgeLength" ); p.setInt ( 48 )
p = Cfg.getParamInt ( "anabatic.edgeWidth" ); p.setInt ( 8 )
p = Cfg.getParamDouble ( "anabatic.edgeCostH" ); p.setDouble ( 19.0 )
p = Cfg.getParamDouble ( "anabatic.edgeCostK" ); p.setDouble ( -60.0 )
p = Cfg.getParamDouble ( "anabatic.edgeHInc" ); p.setDouble ( 1.0 )
p = Cfg.getParamDouble ( "anabatic.edgeHScaling" ); p.setDouble ( 1.0 )
p = Cfg.getParamInt ( "anabatic.globalIterations" ); p.setInt ( 20 ); p.setMin(1); p.setMax(100)
p = Cfg.getParamEnumerate ( "anabatic.gcell.displayMode" ); p.setInt ( 1 )
p.addValue( "Boundary", 1 )
p.addValue( "Density" , 2 )
p = Cfg.getParamInt ( "katana.hTracksReservedLocal" ); p.setInt ( 5 ); p.setMin(0); p.setMax(20)
p = Cfg.getParamInt ( "katana.vTracksReservedLocal" ); p.setInt ( 3 ); p.setMin(0); p.setMax(20)
p = Cfg.getParamInt ( "katana.termSatReservedLocal" ); p.setInt ( 5 )
p = Cfg.getParamInt ( "katana.termSatThreshold" ); p.setInt ( 11 )
p = Cfg.getParamInt ( "katana.eventsLimit" ); p.setInt ( 4000002 )
p = Cfg.getParamInt ( "katana.ripupCost" ); p.setInt ( 3 ); p.setMin(0)
p = Cfg.getParamInt ( "katana.strapRipupLimit" ); p.setInt ( 16 ); p.setMin(1)
p = Cfg.getParamInt ( "katana.localRipupLimit" ); p.setInt ( 9 ); p.setMin(1)
p = Cfg.getParamInt ( "katana.globalRipupLimit" ); p.setInt ( 5 ); p.setMin(1)
p = Cfg.getParamInt ( "katana.longGlobalRipupLimit" ); p.setInt ( 5 ); p.setMin(1)
p = Cfg.getParamString( 'chip.padCoreSide' ); p.setString( 'South' )
tech = DataBase.getDB().getTechnology()
af = AllianceFramework.get()
rg = RoutingGauge.create( 'nsxlib-4M' )
rg.addLayerGauge( RoutingLayerGauge.create( tech.getLayer('METAL1') # metal.
, RoutingLayerGauge.Vertical # preferred routing direction.
, RoutingLayerGauge.PinOnly # layer usage.
, 0 # depth.
, 0.0 # density (deprecated).
, l(0) # track offset from AB.
, l(10) # track pitch.
, l(3) # wire width.
, l(2) # VIA side (that is VIA12).
, l(7) # obstacle dW.
) )
rg.addLayerGauge( RoutingLayerGauge.create( tech.getLayer('METAL2') # metal.
, RoutingLayerGauge.Horizontal # preferred routing direction.
, RoutingLayerGauge.Default # layer usage.
, 1 # depth.
, 0.0 # density (deprecated).
, l(0) # track offset from AB.
, l(10) # track pitch.
, l(3) # wire width.
, l(2) # VIA side (that is VIA23).
, l(8) # obstacle dW.
) )
rg.addLayerGauge( RoutingLayerGauge.create( tech.getLayer('METAL3') # metal.
, RoutingLayerGauge.Vertical # preferred routing direction.
, RoutingLayerGauge.Default # layer usage.
, 2 # depth.
, 0.0 # density (deprecated).
, l(0) # track offset from AB.
, l(10) # track pitch.
, l(3) # wire width.
, l(2) # VIA side (that is VIA34).
, l(8) # obstacle dW.
) )
rg.addLayerGauge( RoutingLayerGauge.create( tech.getLayer('METAL4') # metal.
, RoutingLayerGauge.Horizontal # preferred routing direction.
, RoutingLayerGauge.Default # layer usage.
, 3 # depth.
, 0.0 # density (deprecated).
, l(0) # track offset from AB.
, l(15) # track pitch.
, l(6) # wire width.
, l(4) # VIA side (that is VIA23).
, l(8) # obstacle dW.
) )
af.addRoutingGauge( rg )
rg = RoutingGauge.create( 'nsxlib-3M' )
rg.addLayerGauge( RoutingLayerGauge.create( tech.getLayer('METAL1') # metal.
, RoutingLayerGauge.Vertical # preferred routing direction.
, RoutingLayerGauge.PinOnly # layer usage.
, 0 # depth.
, 0.0 # density (deprecated).
, l(0) # track offset from AB.
, l(10) # track pitch.
, l(3) # wire width.
, l(2) # VIA side (that is VIA12).
, l(7) # obstacle dW.
) )
rg.addLayerGauge( RoutingLayerGauge.create( tech.getLayer('METAL2') # metal.
, RoutingLayerGauge.Horizontal # preferred routing direction.
, RoutingLayerGauge.Default # layer usage.
, 1 # depth.
, 0.0 # density (deprecated).
, l(0) # track offset from AB.
, l(10) # track pitch.
, l(3) # wire width.
, l(2) # VIA side (that is VIA23).
, l(8) # obstacle dW.
) )
rg.addLayerGauge( RoutingLayerGauge.create( tech.getLayer('METAL3') # metal.
, RoutingLayerGauge.Vertical # preferred routing direction.
, RoutingLayerGauge.Default # layer usage.
, 2 # depth.
, 0.0 # density (deprecated).
, l(0) # track offset from AB.
, l(10) # track pitch.
, l(3) # wire width.
, l(2) # VIA side (that is VIA34).
, l(8) # obstacle dW.
) )
af.addRoutingGauge( rg )
rg = RoutingGauge.create( 'nsxlib-2M' )
rg.addLayerGauge( RoutingLayerGauge.create( tech.getLayer('METAL1') # metal.
, RoutingLayerGauge.Horizontal # preferred routing direction.
, RoutingLayerGauge.Default # layer usage.
, 0 # depth.
, 0.0 # density (deprecated).
, l(0) # track offset from AB.
, l(10) # track pitch.
, l(3) # wire width.
, l(3) # VIA side (that is VIA12).
, l(7) # obstacle dW.
) )
rg.addLayerGauge( RoutingLayerGauge.create( tech.getLayer('METAL2') # metal.
, RoutingLayerGauge.Vertical # preferred routing direction.
, RoutingLayerGauge.Default # layer usage.
, 1 # depth.
, 0.0 # density (deprecated).
, l(0) # track offset from AB.
, l(10) # track pitch.
, l(3) # wire width.
, l(3) # VIA side (that is VIA23).
, l(8) # obstacle dW.
) )
af.addRoutingGauge( rg )
af.setRoutingGauge( 'nsxlib-3M' )
# Gauge for standard cells.
cg = CellGauge.create( 'nsxlib-4M'
, 'metal2' # pin layer name.
, l( 10.0) # pitch.
, l(100.0) # cell slice height.
, l( 10.0) # cell slice step.
)
af.addCellGauge( cg )
cg = CellGauge.create( 'nsxlib-3M'
, 'metal2' # pin layer name.
, l( 10.0) # pitch.
, l(100.0) # cell slice height.
, l( 10.0) # cell slice step.
)
af.addCellGauge( cg )
cg = CellGauge.create( 'nsxlib-2M'
, 'metal2' # pin layer name.
, l( 10.0) # pitch.
, l(100.0) # cell slice height.
, l( 10.0) # cell slice step.
)
af.addCellGauge( cg )
# Gauge for Alliance symbolic I/O pads.
cg = CellGauge.create( 'phlib80'
, 'metal2' # pin layer name.
, l( 10.0) # pitch.
, l(312.0) # cell slice height.
, l(246.0) # cell slice step.
)
af.addCellGauge( cg )