innovus中自動(dòng)在frame和coreArea之間的channal插入RouteBlockage的tcl腳本
可以自動(dòng)識(shí)別所有金屬層次。pin出口處不能自動(dòng)識(shí)別。
=================================================
set core2Top [dbGet top.FPlan.core2Top]
set core2Bot [dbGet top.FPlan.core2Bot]
set core2Left [dbGet top.FPlan.core2Left]
set core2Right [dbGet top.FPlan.core2Right]
set layerType [dbGet head.layers.type]
set layerName [dbGet head.layers.name]
set layernum [llength [dbGet head.layers.name]]
set num 0
set layerList ""
while {$num < $layernum} {
? ? ? ? if {[string match routing [lindex $layerType $num]]} {
? ? ? ? set layer_n [lindex $layerName $num]
? ? ? ? set layerList [concat $layerList $layer_n]
? ? ? ? }
? ? ? ? incr num
}? ? ?
#puts $layerList
set box [dbGet top.FPlan.box]
#set box [dbGet top.fPlan.boxes]
set coreBox [dbGet top.FPlan.coreBox]
set coreBox_org [dbGet top.FPlan.coreBox]
set Cutnum 0
dbForEachFPlanPtnCut [dbHeadFPlan] ptnCut {
incr Cutnum
set ptnCutBox [dbPtnCutBox $ptnCut]
set ptnCutBox_llx [dbDBUToMicrons [lindex $ptnCutBox 0]]
set ptnCutBox_lly [dbDBUToMicrons [lindex $ptnCutBox 1]]
set ptnCutBox_urx [dbDBUToMicrons [lindex $ptnCutBox 2]]
set ptnCutBox_ury [dbDBUToMicrons [lindex $ptnCutBox 3]]
set cutBox "{$ptnCutBox_llx $ptnCutBox_lly $ptnCutBox_urx $ptnCutBox_ury}"
set box [dbShape $box XOR $cutBox]
set cutBoxCore_llx [expr $ptnCutBox_llx - $core2Left]
set cutBoxCore_lly [expr $ptnCutBox_lly - $core2Bot]
set cutBoxCore_urx [expr $ptnCutBox_urx + $core2Right]
set cutBoxCore_ury [expr $ptnCutBox_ury + $core2Top]
set cutBoxCore "{$cutBoxCore_llx $cutBoxCore_lly $cutBoxCore_urx $cutBoxCore_ury}"
set coreBox [dbShape $coreBox XOR $cutBoxCore]
}
puts "CutArea number : $Cutnum"
set coreBoxReal [dbShape $coreBox_org AND $coreBox]
set dieChannalArea [dbShape $box XOR $coreBoxReal]
puts "dieChannalArea : $dieChannalArea"
puts "Create tcl file: createRouteBlk_channalArea.tcl ..."
set tclFile "createRouteBlk_channalArea.tcl"
set createRouteBlk [open $tclFile w]
foreach layer $layerList {
foreach dieChannalArea_n $dieChannalArea {
puts $createRouteBlk "createRouteBlk -name defLayerBlkName -layer $layer -boxList { $dieChannalArea_n }"
}
}
close $createRouteBlk
source $tclFile
puts "Source \"createRouteBlk_channalArea.tcl\" End.\n"