Languages

CommunityCategory: MODELZENExtracting models from netlists that include PODE (poly over diffusion edge) instances

MODELZEN

Extracting models from netlists that include PODE (poly over diffusion edge) instances

SA Support Team Staff 2021-03-25

I am using an advanced technology and the foundry PDK sometimes creates additional device instances in the netlists that are not shown on the schematics. For example, depending on the options set on the transistor instances, a transistor may be netlisted into two separate instances: one describing the transistor itself and the other describing the RC parasitics of its poly over diffusion edge (PODE). See an example below. The PDK netlister netlisted a transistor as a combination of two instances 'M1' and 'M1__macro', and also created new nets such as 'A_dmy', 'B_dmy', and 'C_dmy' that connect between the two instances. The instance 'M1__macro' describes the additional resistance and capacitance present on the drain, gate, and source terminals of the transistor.

M1 ( A_dmy  B_dmy  C_dmy  D ) nch_svt_mac l=0.008u w=0.308u …
M1__macro ( A  B  C  D  A_dmy  B_dmy  C_dmy  D ) nch_svt_mac_pode l=72n …

This "expansion" of a single instance on the schematic into multiple instances in the netlist causes many problems when extracting models with MODELZEN. For example, when I select a group of transistors as a UDM, only the core transistor instances get included in the selection, leaving the PODE instances out. Is there a way I can let MODELZEN treat these expanded instances as one combined set? I think that would solve all the problems.

1 Answers
Best Answer
SA Support Team Staff 2021-03-25

You are right on! Indeed, all the problems can be solved by telling MODELZEN how to combine those expanded instances into a group. You can do so by assigning a 'group' attribute to the device mapping entries listed in the 'devo_devicemap' dictionary of the technology configuration file.

Let’s say you'd like MODELZEN to treat two instances with the following patterns as a single transistor. That is, you'd like MODELZEN to take a pair of 'nch_svt_mac' and 'nch_svt_mac_pode' instances connected to the nets 'A', 'B', 'C', and 'D':

M1 ( A_dmy  B_dmy  C_dmy  D ) nch_svt_mac l=0.008u w=0.308u …
M1__macro ( A  B  C  D  A_dmy  B_dmy  C_dmy  D ) nch_svt_mac_pode l=72n …

and convert them into a single 'nmosfet' instance with its drain, gate, source, and bulk terminals connected to the nets 'A', 'B', 'C', and 'D', respectively.

nmosfet  M1 (.d(A), .g(B), .s(C), .b(D));

Here is how you can describe the corresponding grouping rules in the technology configuration file. For your convenience, first define a dictionary (e.g. named 'group_pode') that defines the naming patterns of the instances to be grouped and their terminal lists. Here is an example for our case:

# group property to merge transistor instances with their PODE instances
group_pode = {
    "@(INSTNAME)"           : dict(terms=['*', '*', '*', 'b']),
    "@(INSTNAME)__macro"    : dict(terms=['d', 'g', 's', 'b', '*', '*', '*']),
}

It says, if a transistor instance is found with another instance with a '__macro' suffix in its name, MODELZEN shall group them using the nets listed in the positions of 'd', 'g', 's', and 'b' as the drain, gain, source, and bulk terminals of the combined transistor instance, respectively. Here, the "@(INSTNAME)" is an embedded Python expression where 'INSTNAME' is a variable containing the instance name under consideration. With this embedded Python expression, you can describe various naming patterns. For example, "X@(INSTNAME[1:])" is the instance name of which prefix is replaced with an 'X' and "@(INSTNAME.upper())" is the instance name all of which letters are converted to uppercases. On the other hand, the asterisks '*' in the terminal lists denote the internal nets.

Next, assign this dictionary as the 'group' attribute of the devices listed in the 'devo_devicemap' dictionary of the technology configuration file. The example shown below specifies that the instances of 'nmos_svt_mac', 'pmos_svt_mac', 'nmos_lvt_mac', and 'pmos_lvt_mac' shall be grouped with their PODE instances if the instances with the said naming patterns are found in the netlist.

# global device mapping
devo_devicemap = {
    "nmos_svt_mac"  : dict(type="nmosfet", vmax=1.2, max_leveldc=3, group=group_pode),
    "pmos_svt_mac"  : dict(type="pmosfet", vmax=1.2, max_leveldc=3, group=group_pode),
    "nmos_lvt_mac"  : dict(type="nmosfet", vmax=1.2, max_leveldc=3, group=group_pode),
    "pmos_lvt_mac"  : dict(type="pmosfet", vmax=1.2, max_leveldc=3, group=group_pode),
}

Lastly, make sure the 'dev_model' entry in the technology configuration file contains a line that includes the SPICE model library defining the PODE devices (e.g. the subcircuit definition for 'nch_svt_mac_pode' and so on), since MODELZEN will now characterize the combined set of these instances as a single transistor. Otherwise, MODELZEN may fail during the SPICE/Spectre characterization phase with an error message saying that the definition for the said model or subcircuit is not found.

MODELZEN

PODE 인스턴스들이 포함된 netlist로부터 모델 추출하는 법

SA Support Team Staff 2021-03-25

최신 공정을 사용하고 있는데, 파운드리 PDK가 스키매틱에서 netlist를 추출할때 스키매틱 상에는 없는 추가 인스턴스들을 만들어내곤 합니다. 예를 들면, 트랜지스터 인스턴스에 정의된 옵션에 따라서, 하나의 트랜지스터가 두 개의 인스턴스로 넷리스팅될 수가 있습니다. 하나의 인스턴스는 트랜지스터 자체를 표현하고, 다른 하나의 인스턴스는 디퓨션 경계의 폴리실리콘 구조(poly over diffusion edge; PODE)와 관계된 RC 기생성분을 표현합니다. 아래의 예를 참고하세요. 이 경우, PDK netlister가 하나의 트랜지스터를 'M1''M1__macro'라는 이름의 두개의 인스턴스의 조합으로 넷리스팅했는데요, 이 둘을 연결하기 위해 'A_dmy', 'B_dmy''C_dmy'와 같은 net들도 새로 만들었습니다. 이중 'M1_macro' 인스턴스는 트랜지스터의 드레인, 게이트, 소스 단자에 존재하는 추가 저항 및 커패시터 성분들을 표현하고 있습니다.

M1 ( A_dmy  B_dmy  C_dmy  D ) nch_svt_mac l=0.008u w=0.308u …
M1__macro ( A  B  C  D  A_dmy  B_dmy  C_dmy  D ) nch_svt_mac_pode l=72n …

문제는, 스키매틱 상에서는 하나의 인스턴스가 netlist 상에서는 복수의 인스턴스들로 변환되면서, MODELZEN 모델 추출과정에서 여러가지 문제를 발생시킨다는 것입니다. 예를 들어, 트랜지스터들을 묶어 하나의 UDM으로 설정할때, 코어 트랜지스터 인스턴스들만 UDM으로 묶이고, 추가로 생성된 PODE 인스턴스들은 안 묶이면서 모델 생성과정에서 오류들이 발생합니다. MODELZEN이 이렇게 변환된 복수의 인스턴스들을 하나의 묶음으로 보게 하는 방법이 있을까요? 그렇게만 할 수 있다면 모든 문제가 해결될 것 같은데요.

1 Answers
Best Answer
SA Support Team Staff 2021-03-25

You are right on! Indeed, all the problems can be solved by telling MODELZEN how to combine those expanded instances into a group. You can do so by assigning a 'group' attribute to the device mapping entries listed in the 'devo_devicemap' dictionary of the technology configuration file.

Let’s say you'd like MODELZEN to treat two instances with the following patterns as a single transistor. That is, you'd like MODELZEN to take a pair of 'nch_svt_mac' and 'nch_svt_mac_pode' instances connected to the nets 'A', 'B', 'C', and 'D':

M1 ( A_dmy  B_dmy  C_dmy  D ) nch_svt_mac l=0.008u w=0.308u …
M1__macro ( A  B  C  D  A_dmy  B_dmy  C_dmy  D ) nch_svt_mac_pode l=72n …

and convert them into a single 'nmosfet' instance with its drain, gate, source, and bulk terminals connected to the nets 'A', 'B', 'C', and 'D', respectively.

nmosfet  M1 (.d(A), .g(B), .s(C), .b(D));

Here is how you can describe the corresponding grouping rules in the technology configuration file. For your convenience, first define a dictionary (e.g. named 'group_pode') that defines the naming patterns of the instances to be grouped and their terminal lists. Here is an example for our case:

# group property to merge transistor instances with their PODE instances
group_pode = {
    "@(INSTNAME)"           : dict(terms=['*', '*', '*', 'b']),
    "@(INSTNAME)__macro"    : dict(terms=['d', 'g', 's', 'b', '*', '*', '*']),
}

It says, if a transistor instance is found with another instance with a '__macro' suffix in its name, MODELZEN shall group them using the nets listed in the positions of 'd', 'g', 's', and 'b' as the drain, gain, source, and bulk terminals of the combined transistor instance, respectively. Here, the "@(INSTNAME)" is an embedded Python expression where 'INSTNAME' is a variable containing the instance name under consideration. With this embedded Python expression, you can describe various naming patterns. For example, "X@(INSTNAME[1:])" is the instance name of which prefix is replaced with an 'X' and "@(INSTNAME.upper())" is the instance name all of which letters are converted to uppercases. On the other hand, the asterisks '*' in the terminal lists denote the internal nets.

Next, assign this dictionary as the 'group' attribute of the devices listed in the 'devo_devicemap' dictionary of the technology configuration file. The example shown below specifies that the instances of 'nmos_svt_mac', 'pmos_svt_mac', 'nmos_lvt_mac', and 'pmos_lvt_mac' shall be grouped with their PODE instances if the instances with the said naming patterns are found in the netlist.

# global device mapping
devo_devicemap = {
    "nmos_svt_mac"  : dict(type="nmosfet", vmax=1.2, max_leveldc=3, group=group_pode),
    "pmos_svt_mac"  : dict(type="pmosfet", vmax=1.2, max_leveldc=3, group=group_pode),
    "nmos_lvt_mac"  : dict(type="nmosfet", vmax=1.2, max_leveldc=3, group=group_pode),
    "pmos_lvt_mac"  : dict(type="pmosfet", vmax=1.2, max_leveldc=3, group=group_pode),
}

Lastly, make sure the 'dev_model' entry in the technology configuration file contains a line that includes the SPICE model library defining the PODE devices (e.g. the subcircuit definition for 'nch_svt_mac_pode' and so on), since MODELZEN will now characterize the combined set of these instances as a single transistor. Otherwise, MODELZEN may fail during the SPICE/Spectre characterization phase with an error message saying that the definition for the said model or subcircuit is not found.