Diagnosing a Real LVS Mismatch
When an LVS comparison fails, Netgen generates a diagnostic report detailing netlist discrepancies. Interpreting these reports allows designers to distinguish between open circuits, electrical shorts, and component mismatches. This laboratory exercise introduces a deliberate layout defect and analyzes the resulting LVS signature.
Inducing an Electrical Open Circuit
Open Magic and delete a single via1 connecting met1 to met2 on net baud_div_out:
load uart_top
box 76.400um 48.220um 76.460um 48.280um
select area via1
what
delete
save uart_top_broken
gds write uart_top_broken.gds
The met1 and met2 traces remain intact, satisfying all DRC spacing rules. However, removing the via breaks the electrical connection to the GATE pin of clock gating cell sky130_fd_sc_hd__dlclkp_1.
Extracting and Comparing the Defective Layout
Extract the modified layout and execute Netgen LVS:
magic -dnull -noconsole \
-rcfile "$PDK_ROOT/sky130A/libs.tech/magic/sky130A.magicrc" <<'EOF'
gds read uart_top_broken.gds
load uart_top_broken
select top cell
extract do local
extract all
ext2spice lvs
ext2spice -o uart_broken_extracted.spice
quit -noprompt
EOF
netgen -batch lvs \
"uart_broken_extracted.spice uart_top_broken" \
"runs/uart_full/results/final/verilog/gl/uart_top.v uart_top" \
"$PDK_ROOT/sky130A/libs.tech/netgen/sky130A_setup.tcl" \
uart_lvs_broken.report
Review the error section of uart_lvs_broken.report:
Number of devices: 1406 |Number of devices: 1406
Number of nets: 1843 **Mismatch** |Number of nets: 1842 **Mismatch**
...
Net: baud_div_out |Net: baud_div_out
sky130_fd_sc_hd__dfxtp_2/Q = 1 | sky130_fd_sc_hd__dfxtp_2/Q = 1
sky130_fd_sc_hd__and2_1/A = 2 | sky130_fd_sc_hd__and2_1/A = 2
sky130_fd_sc_hd__nor2_1/B = 1 | sky130_fd_sc_hd__nor2_1/B = 1
| sky130_fd_sc_hd__dlclkp_1/GATE = 1
Net: a_76400_48220# |(no matching net)
sky130_fd_sc_hd__dlclkp_1/GATE = 1 |
...
Netlists do not match.
Interpreting Mismatch Signatures
The table below correlates Netgen report characteristics with physical defect types:
| Defect Type | Net Count Relationship | Pin Distribution Behavior |
|---|---|---|
| Open Circuit | Layout has more nets than schematic | The logical net splits into two or more layout fragments. A new auto-named net holds the isolated pins |
| Short Circuit | Layout has fewer nets than schematic | Two distinct schematic nets merge into a single layout net containing the combined pin list |
| Device Mismatch | Net counts can match; device counts differ | A component instance connects to incorrect pins or uses an incorrect library cell type |
Figure 1 outlines the diagnostic process. In this run, the layout contains 1,843 nets while the schematic contains 1,842 nets. Net baud_div_out split into two pieces. The isolated GATE pin received an auto-generated net name derived from its coordinates (a_76400_48220#). This signature indicates an open circuit.
Repairing the Defect and Re-Verifying
Restore the missing via in Magic:
load uart_top_broken
box 76.400um 48.220um 76.460um 48.280um
paint via1
save uart_top_fixed
gds write uart_top_fixed.gds
Re-extract the SPICE netlist and execute Netgen. The two disconnected segments merge into a single five-pin net. The net count balances at 1,842 nets, and Netgen reports: Circuits match uniquely.
Practice Exercise
A Netgen report indicates that the layout has one fewer net than the reference netlist. The report shows that net rx_data_ready and net rx_parity_err merge into a single node in the layout. Identify the defect type and specify the layout repair action.
Solution
This defect is an electrical short circuit.
Two distinct logical nets merge into a single physical conductor. Inspect the layout for overlapping or touching metal shapes between rx_data_ready and rx_parity_err. Separate the conflicting traces to restore electrical isolation, and verify that the new spacing satisfies DRC rules.
LVS confirms that physical shapes preserve logical circuit connectivity. Section 8.3 introduces process antenna rules and demonstrates diode protection against gate dielectric breakdown.