Added a few lines of code to the toolkit management to work around
the issue of a device name in a netlist having different case than the procedures defined for the device in the PDK. The difference in case is transparent to SPICE, so it should also be transparent to the PDK.
This commit is contained in:
parent
a9673e45ae
commit
2d5c4be6dd
|
|
@ -362,6 +362,27 @@ proc magic::generate_layout_add {subname subpins complist library} {
|
|||
}
|
||||
}
|
||||
|
||||
# Check if devtype has routines by looking for ${devtype}_defaults.
|
||||
# If not found, do a case-insensitive check against all devices
|
||||
# before deciding that devtype is a subcircuit and not a device.
|
||||
# If found by case-insensitive check, then change the device name
|
||||
# to the one used in the library.
|
||||
|
||||
if {$library != ""} {
|
||||
set alldevices [namespace eval ::${library} {info procs}]
|
||||
} else {
|
||||
set alldevices [namespace eval ::${PDKNAMESPACE} {info procs}]
|
||||
}
|
||||
set devdefault [lsearch $alldevices ${devtype}_defaults]
|
||||
if {$devdefault == -1} {
|
||||
set devdefault [lsearch -nocase $alldevices ${devtype}_defaults]
|
||||
if {$devdefault != -1} {
|
||||
set devprocname [lindex $alldevices $devdefault]
|
||||
set devproclist [split $devprocname "_"]
|
||||
set devtype [lindex $devproclist 0]
|
||||
}
|
||||
}
|
||||
|
||||
# devtype is assumed to be in library. If not, it will attempt to
|
||||
# use 'getcell' on devtype. Note that this code depends on the
|
||||
# PDK setting varible PDKNAMESPACE.
|
||||
|
|
|
|||
Loading…
Reference in New Issue