RTimothyEdwards / open_pdks

PDK installer for open-source EDA tools and toolchains. Distributed with setups for the SkyWater 130nm and Global Foundries 180nm open processes.
http://opencircuitdesign.com/open_pdks
Apache License 2.0
292 stars 86 forks source link

sky130 gpio LVS: Resistor recognition layers on parent hierarchy ignored. #422

Open d-m-bailey opened 11 months ago

d-m-bailey commented 11 months ago

In the sky130_fd_io library, the top_gpiov2 layout contains a cell, the res250only_small, that has resistor definition layers on li1 67/15, poly 66/13, and met1 68/15, but no actual mask layers. magic only recognizes devices if all the relevant layers are on the same hierarchy level.

If the underling cell, res250_sub_small is flattened, the resistor devices are recognized. If it is not flattened, the resistors are ignored.

Currently, the corresponding spice netlist has these resistors commented out.

.SUBCKT sky130_fd_io__res250only_small PAD ROUT
*.PININFO PAD:B ROUT:B

* NOTE: Removed all but the primary resistor;  the other devices do not
* show up in the layout.
*
* RI175 net12 net16 sky130_fd_pr__res_generic_po W=2 L=10.07 m=1
* RI229 net16 ROUT sky130_fd_pr__res_generic_po W=2 L=0.17 m=1
* RI228 PAD net12 sky130_fd_pr__res_generic_po W=2 L=0.17 m=1
* RI237<1> net16 ROUT short 
* RI237<2> net16 ROUT short
* RI234<1> PAD net12 short
* RI234<2> PAD net12 short

RI175 PAD ROUT sky130_fd_pr__res_generic_po W=2 L=10.07 m=1
.ENDS sky130_fd_io__res250only_small

Flattening res250_sub_small, extracts a netlist equivalent to

.SUBCKT sky130_fd_io__res250only_small PAD ROUT
*.PININFO PAD:B ROUT:B

* NOTE: Removed all but the primary resistor;  the other devices do not
* show up in the layout.
*
R0 PAD PAD sky130_fd_pr__res_generic_l1 w=0.27 l=0.005
R9 PAD PAD sky130_fd_pr__res_generic_l1 w=0.23 l=0.005
R5 PAD PAD sky130_fd_pr__res_generic_m1 w=2.01 l=0.01
R3 PAD PAD sky130_fd_pr__res_generic_po w=0.34 l=0.085
R7 PAD PAD sky130_fd_pr__res_generic_po w=0.3 l=0.085
R1 ROUT ROUT sky130_fd_pr__res_generic_l1 w=0.23 l=0.005
R10 ROUT ROUT sky130_fd_pr__res_generic_l1 w=0.27 l=0.005
R6 ROUT ROUT sky130_fd_pr__res_generic_m1 w=2.01 l=0.01
R4 ROUT ROUT sky130_fd_pr__res_generic_po w=0.34 l=0.085
R8 ROUT ROUT sky130_fd_pr__res_generic_po w=0.3 l=0.085

R2 PAD ROUT sky130_fd_pr__res_generic_po w=2 l=10.07
.ENDS sky130_fd_io__res250only_small

Note the unexpected dimensions on the li1 and poly resistors.

To duplicate, flatglob res250_sub_small when reading the gds file before extraction.

Open pdks 78b7bc32ddb4b6f14f76883c2e2dc5b5de9d1cbc magic 8.3.442