Mitch Bailey
11/18/2021, 10:21 PMsram_1rw1r_32_256_8_sky130.sp
(W=0.21 L=0.15
) and those of the newer unscaled sky130_sram_1kbyte_1rw1r_32x256_8.lvs.sp
(W=0.21u L=0.15u
) in the sky130_sram_macros
repo. I believe the sky130 magic extraction rules use the scaled w=70000u l=150000u
(=W=0.21 L=0.15
).Matthew Guthaus
11/18/2021, 10:33 PMMatthew Guthaus
11/18/2021, 10:55 PMMatthew Guthaus
11/18/2021, 10:56 PMMatthew Guthaus
11/18/2021, 10:56 PMMatthew Guthaus
11/18/2021, 10:56 PMMatthew Guthaus
11/18/2021, 11:26 PMMatthew Guthaus
11/18/2021, 11:27 PMMitch Bailey
11/18/2021, 11:42 PMMitch Bailey
11/18/2021, 11:50 PMsky130_fd_sc_hd.spice
file, and it appears the parameters are w=420000u l=150000u
, which I believe matches the default magic extraction style.
I found this in the tech file
style ngspice variants (),(orig),(si)
cscale 1
# NOTE: SkyWater SPICE libraries use .option scale 1E6 so all
# dimensions must be in units of microns in the extract file.
# Use extract style "ngspice(si)" to override this and produce
# a file with SI units for length/area.
Maybe you're using the si
style for the newer modules?Matthew Guthaus
11/19/2021, 2:03 AMMatthew Guthaus
11/19/2021, 2:04 AMMitch Bailey
11/19/2021, 2:21 AMrun_ext.sh
script in the repo and found
extract style ngspice(si)
So that's where it's coming from. Now what to do about it?Mitch Bailey
11/19/2021, 2:29 AMMitch Bailey
11/19/2021, 2:30 AMMatthew Guthaus
11/19/2021, 2:31 AMMitch Bailey
11/19/2021, 2:32 AMopen_pdks
build.Matthew Guthaus
11/19/2021, 2:32 AMMatthew Guthaus
11/19/2021, 2:33 AMMatthew Guthaus
11/19/2021, 2:35 AMMitch Bailey
11/19/2021, 2:54 AMbuild pdk
copies the sky130_sram_macro
data to pdks/sky130A/libs.ref/sky130_sram_macros/spice
directory, it just copies *.lvs.sp
to *.spice
. The *.lvs.sp
version has W/L parameters in si
units which don't match the rest of the sky130A/lib.ref
libraries.
The sky130_sram_macro
repo also contains *.sp
files which have the expected W/L units. Do you see any problems with copying *.sp
instead of *.lvs.sp
?
It's not a simple change of `open_pdks/sky130/Makefile`'s
-spice %l/*/*.lvs.sp filter=custom/scripts/sp_to_spice.py \
to
-spice %l/*/*.sp filter=custom/scripts/sp_to_spice.py \
because there are 3 files in each module directory that end in .sp
. For example,
functional_stim.sp
sky130_sram_1kbyte_1rw1r_32x256_8.lvs.sp
sky130_sram_1kbyte_1rw1r_32x256_8.sp
Maybe
-spice %l/*/*[0-9].sp filter=custom/scripts/sp_to_spice.py \
Matthew Guthaus
11/19/2021, 2:57 AMMatthew Guthaus
11/19/2021, 2:57 AMMitch Bailey
11/19/2021, 3:03 AMMatthew Guthaus
11/19/2021, 3:08 AMMitch Bailey
11/19/2021, 12:50 PMrun_lvs.sh
script in the repo I get
bash-4.2$ netgen -batch
Netgen 1.5.208 compiled on Fri Nov 12 03:05:51 UTC 2021
bash-4.2$ magic -dnull -noc
Magic 8.3 revision 225 - Compiled on Fri Nov 12 03:02:01 UTC 2021.
bash-4.2$ run_lvs.sh
...
Circuit 1 contains 89357 devices, Circuit 2 contains 89357 devices.
Circuit 1 contains 20507 nets, Circuit 2 contains 19488 nets. *** MISMATCH ***
Result: Cells failed matching, or top level cell failed pin matching.
Logging to file "sky130_sram_1kbyte_1rw1r_32x256_8.lvs.report" disabled
LVS Done.
Fri Nov 19 11:21:27 UTC 2021: Finished (0) LVS using Netgen /build/bin/netgen
I've made some experimental changes to my local copy of netgen that are intended to clear up some of the problems with pin count mismatches. I'm running that now.Mitch Bailey
11/19/2021, 1:19 PMCircuit 1 contains 90512 devices, Circuit 2 contains 90512 devices.
Circuit 1 contains 21112 nets, Circuit 2 contains 20093 nets. *** MISMATCH ***
Final result:
Netlists do not match.
Is the clean LVS log file from your run available? Also, what versions of magic and netgen are you using?Tim Edwards
11/19/2021, 1:57 PMTim Edwards
11/19/2021, 2:12 PM*[0-9].sp
and it works, so I'm going ahead and making that change to the open_pdks sky130 Makefile.Mitch Bailey
11/19/2021, 2:12 PMMitch Bailey
12/04/2021, 1:10 PMMagic 8.3 revision 233
Netgen 1.5.206 (modified)
Some of the vdd connections to the memory cells aren't being connected so I ran the extracted spice through this sed
s,vdd_uq1854,vdd,
s,vdd_uq3134,vdd,
s,vdd_uq1982,vdd,
s,vdd_uq1918,vdd,
s,vdd_uq3838,vdd,
s,vdd_uq2622,vdd,
s,vdd_uq3070,vdd,
s,vdd_uq2558,vdd,
s,vdd_uq2686,vdd,
s,vdd_uq4030,vdd,
s,vdd_uq3902,vdd,
s,vdd_uq3774,vdd,
s,vdd_uq2238,vdd,
s,vdd_uq3966,vdd,
s,vdd_uq2366,vdd,
s,vdd_uq2174,vdd,
s,vdd_uq2302,vdd,
s,vdd_uq2750,vdd,
s,vdd_uq2430,vdd,
s,vdd_uq3582,vdd,
s,vdd_uq3646,vdd,
s,vdd_uq2814,vdd,
s,vdd_uq4094,vdd,
s,vdd_uq3006,vdd,
s,vdd_uq3454,vdd,
s,vdd_uq3518,vdd,
s,vdd_uq2110,vdd,
Maybe that's fixed with the latest magic update. I'll check next week. netgen (my version) took a little over an hour.
@User A couple weeks ago, the change to use sky130_sram_*.sp
instead of sky130_sram_*.lvs.sp
when creating sky130_sram_*.spice
was suggested and incorporated into open_pdks. Unfortunately, even though this corrects the device size problems, the sky130_sram_*.sp
memory cells do not contain the parasitic transistor necessary to match the extracted version. Fixing the sizes in sky130_sram_*.lvs.sp
yields a match (with the extracted vdd changes mentioned above). These are the sed commands I used.
s/\([Ww]=[0-9\.]*\)u/\1/
s/\([Ll]=[0-9\.]*\)u/\1/
Matthew Guthaus
12/04/2021, 3:09 PMMatthew Guthaus
12/04/2021, 3:10 PMMatthew Guthaus
12/04/2021, 3:10 PMTim Edwards
12/04/2021, 6:20 PMMatthew Guthaus
12/04/2021, 6:24 PMMatthew Guthaus
12/04/2021, 6:25 PMMitch Bailey
12/04/2021, 11:06 PMMitch Bailey
12/05/2021, 6:22 PMMitch Bailey
12/05/2021, 7:02 PM