get_lib_cells don't require library/
This commit is contained in:
parent
658be26021
commit
6d06cb22d8
25
tcl/Cmds.tcl
25
tcl/Cmds.tcl
|
|
@ -1475,6 +1475,31 @@ proc get_lib_cell_arg { arg_name arg error_proc } {
|
|||
return $lib_cell
|
||||
}
|
||||
|
||||
proc get_lib_cells_arg { arg_name arglist error_proc } {
|
||||
set lib_cells {}
|
||||
# Copy backslashes that will be removed by foreach.
|
||||
set arglist [string map {\\ \\\\} $arglist]
|
||||
foreach arg $arglist {
|
||||
if {[llength $arg] > 1} {
|
||||
# Embedded list.
|
||||
set lib_cells [concat $lib_cells [get_lib_cells_arg $arg_name $arg $warn_error]]
|
||||
} elseif { [is_object $arg] } {
|
||||
set object_type [object_type $arg]
|
||||
if { $object_type == "LibertyCell" } {
|
||||
lappend lib_cells $arg
|
||||
} else {
|
||||
sta_warn_error $warn_error "unsupported object type $object_type."
|
||||
}
|
||||
} elseif { $arg != {} } {
|
||||
set arg_lib_cells [get_lib_cells -quiet $arg]
|
||||
if { $arg_lib_cells != {} } {
|
||||
set lib_cells [concat $lib_cells $arg_lib_cells]
|
||||
}
|
||||
}
|
||||
}
|
||||
return $lib_cells
|
||||
}
|
||||
|
||||
proc get_instance_error { arg_name arg } {
|
||||
set inst "NULL"
|
||||
if {[llength $arg] > 1} {
|
||||
|
|
|
|||
12
tcl/Sdc.tcl
12
tcl/Sdc.tcl
|
|
@ -629,8 +629,11 @@ proc get_lib_cells { args } {
|
|||
set cell_regexp [cell_wild_regexp $divider]
|
||||
set quiet [info exists flags(-quiet)]
|
||||
foreach pattern $patterns {
|
||||
if {[regexp $cell_regexp $pattern ignore lib_name cell_pattern]} {
|
||||
# SDC does not allow wildcards in the library name.
|
||||
if { ![regexp $cell_regexp $pattern ignore lib_name cell_pattern]} {
|
||||
set lib_name "*"
|
||||
set cell_pattern $pattern
|
||||
}
|
||||
# Allow wildcards in the library name (incompatible).
|
||||
set libs [get_libs -quiet $lib_name]
|
||||
if { $libs == {} } {
|
||||
if {!$quiet} {
|
||||
|
|
@ -650,11 +653,6 @@ proc get_lib_cells { args } {
|
|||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if {!$quiet} {
|
||||
sta_warn "library/cell not found in $pattern."
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return $cells
|
||||
|
|
|
|||
Loading…
Reference in New Issue