import Katana
import Unicorn
from helpers import l, u, n
+import clocktree.ClockTree
import plugins.RSavePlugin
+import plugins.ClockTreePlugin
import symbolic.cmos
af = CRL.AllianceFramework.get()
#Cfg.getParamInt ( 'misc.minTraceLevel' ).setInt ( 159 )
#Cfg.getParamInt ( 'misc.maxTraceLevel' ).setInt ( 160 )
Cfg.getParamEnumerate ( 'etesian.effort' ).setInt ( 2 )
-Cfg.getParamPercentage( 'etesian.spaceMargin' ).setPercentage( 20.0 )
+Cfg.getParamPercentage( 'etesian.spaceMargin' ).setPercentage( 10.0 )
Cfg.getParamPercentage( 'etesian.aspectRatio' ).setPercentage( 100.0 )
Cfg.getParamBool ( 'etesian.uniformDensity' ).setBool ( True )
Cfg.getParamInt ( 'anabatic.edgeLenght' ).setInt ( 24 )
Cfg.getParamInt ( 'anabatic.edgeWidth' ).setInt ( 8 )
Cfg.getParamString ( 'anabatic.topRoutingLayer' ).setString ( 'METAL5')
Cfg.getParamInt ( 'katana.eventsLimit' ).setInt ( 1000000 )
-#Cfg.getParamInt ( 'katana.hTracksReservedLocal' ).setInt ( 7 )
-#Cfg.getParamInt ( 'katana.vTracksReservedLocal' ).setInt ( 6 )
+Cfg.getParamInt ( 'katana.hTracksReservedLocal' ).setInt ( 7 )
+Cfg.getParamInt ( 'katana.vTracksReservedLocal' ).setInt ( 6 )
#Cfg.getParamInt ( 'clockTree.minimumSide' ).setInt ( l(1000) )
env = af.getEnvironment()
print db, dir(db)
metal2 = DataBase.getDB().getTechnology().getLayer( 'metal2' )
metal3 = DataBase.getDB().getTechnology().getLayer( 'metal3' )
+ metal5 = DataBase.getDB().getTechnology().getLayer( 'metal5' )
###################
# add
return False
kw[ 'cell' ] = cell
- height = 1100.0
+ width = 400.0
+ height = 350.0
ab = Box( l( 0.0 )
, l( 0.0 )
- , l( 200.0 )
+ , l( width )
, l( height ) )
+ cellGauge = af.getCellGauge()
+ spaceMargin = (Cfg.getParamPercentage('etesian.spaceMargin').asPercentage()+5) / 100.0
+ aspectRatio = Cfg.getParamPercentage('etesian.aspectRatio').asPercentage() / 100.0
+ clocktree.ClockTree.computeAbutmentBox( cell, spaceMargin, aspectRatio, cellGauge )
+ ab = cell.getAbutmentBox()
+ print "calc box", ab, ab.getHeight(), ab.getWidth()
+
+ #height = ab.getHeight()
+ #width = ab.getWidth()
+
UpdateSession.open()
cell.setAbutmentBox( ab )
for i in range(16):
Pin.create( cell.getNet('a(%d)' % i)
, 'a(%d).0' % i
- , Pin.Direction.SOUTH
- , Pin.PlacementStatus.UNPLACED
+ , Pin.Direction.NORTH
+ , Pin.PlacementStatus.FIXED
, metal2
- , l( 10.0*i + 5.0 ) , l( 0.0 ) # Position.
+ , l( 20.0*i + 25.0 ), l( height + 35) # Position.
, l( 2.0 ) , l( 2.0 ) # Size.
)
if True:
Pin.create( cell.getNet('b(%d)' % i)
, 'b(%d).0' % i
- , Pin.Direction.SOUTH
- , Pin.PlacementStatus.UNPLACED
- , metal3
- , l( 10.0*i + 10.0 ) , l( 0.0 ) # Position.
- #, l( 0.0 ), l( 100.0*i + 50.0 ) # Position.
+ , Pin.Direction.NORTH
+ , Pin.PlacementStatus.FIXED
+ , metal2
+ , l( 20.0*i + 20.0 ), l( height + 35) # Position.
, l( 2.0 ) , l( 2.0 ) # Size.
)
if True:
Pin.create( cell.getNet('o(%d)' % i)
, 'o(%d).0' % i
- , Pin.Direction.NORTH
+ , Pin.Direction.SOUTH
, Pin.PlacementStatus.FIXED
- , metal3
- , l( 10.0*i + 10.0 ) , l( height ) # Position.
+ , metal2
+ , l( 10.0*i + 100.0 ), l( 0) # Position.
, l( 2.0 ) , l( 2.0 ) # Size.
)
katana = Katana.KatanaEngine.create(cell)
katana.digitalInit ()
- #katana.runNegociatePreRouted()
+ katana.runNegociatePreRouted()
print dir(katana)
katana.runGlobalRouter (0)
katana.loadGlobalRouting ( Anabatic.EngineLoadGrByNet )