4.2.9 · HinglishVLSI Design

Layout vs schematic (LVS)

2,346 words11 min readRead in English

4.2.9 · Hardware › VLSI Design


LVS exist kyun karta hai?

Teen sign-off checks physical verification mein:

  • DRC (Design Rule Check): Kya layout manufacturable hai? (spacing/width rules)
  • LVS (Layout vs Schematic): Kya layout intended circuit se match karta hai?
  • ERC (Electrical Rule Check): Kya koi electrical bugs hain? (floating gates, etc.)

LVS functional-equivalence ka sawaal answer karta hai, manufacturability ka nahi.


LVS precisely kya hai?

Do netlists equivalent hoti hain jab woh same labeled graph hoti hain:

  • Nodes = electrical nets (wires)
  • Edges/vertices = devices (transistors, R, C) apne terminals aur parameters ke saath

LVS kaise kaam karta hai? (first principles se derivation)

LVS engine ko do graphs build aur compare karne wala socho. Hum har stage derive karte hain.

Stage 1 — Layout extraction (layout graph banao)

Net formation (polygons par union-find). Har polygon ko apni net maan ke shuru karo. Nets merge karo jab:

  • do shapes same layer par overlap/abut karti hain, ya
  • do layers ki shapes ek contact/via se judi hain jahan woh layers connect hone allowed hain.

Yeh exactly ek union-find (disjoint-set) problem hai. Agar polygons hain aur overlap/via relations hain, toh sabhi nets label karne ka cost hai

Yeh formula kyun? Union-find with path compression + union by rank, merges aur finds mein se har ek near-constant amortized time mein karta hai (inverse Ackermann ≈ 4 kisi bhi real chip ke liye). Toh yeh essentially geometry mein linear hai.

Device recognition. Ek device overlapping layers ka ek pattern hai. Ek MOS transistor = poly crossing diffusion:

  • poly-over-diffusion overlap region gate/channel hai,
  • dono taraf ka diffusion = source aur drain,
  • underlying well ⇒ NMOS vs PMOS.

Gate width = poly–diffusion crossing edge ki length; length = current flow ke across poly dimension. Toh parameters seedha geometry se aate hain:

Stage 1 ka output hai layout netlist: devices + extracted nets + .

Stage 2 — Reference netlist

Schematic compile hoti hai (ya ek SPICE netlist di jati hai) same graph form mein. Koi extraction nahi chahiye — connectivity already named hai.

Stage 3 — Graph matching (comparison)

Trick: coloring / partition refinement (Weisfeiler–Leman idea).

  1. Har node ko ek initial color do local invariants se jo woh fake nahi kar sakta: ek net ke liye, jaise (#transistor gates us par, #sources, #drains, #passives). Ek device ke liye, uska type aur parameters.
  2. Refine karo: har node ko neighbor colors ke multiset use karke recolor karo. Repeat karo.
  3. Refinement ke baad, colors nodes ko classes mein partition karte hain. Do graphs mein classes match karo.
  4. Agar dono graphs identical color histograms par converge karein aur har class ka unique pairing ho ⇒ LVS clean. Koi bhi leftover ambiguity/mismatch ⇒ ek discrepancy report karo.

Refinement chhote rounds chalati hai (jab tak stable na ho), har round , toh practically

well-structured chips par near-linear (hierarchy bahut help karta hai — tum ek cell ek baar match karte ho aur reuse karte ho).

Figure — Layout vs schematic (LVS)

Typical LVS error classes (aur woh kaise dikhte hain)

Error Physical cause Graph symptom
Short do nets touch karti hain jo nahi karni chahiye do schematic nets ek layout net se map hoti hain
Open wire tooti / via missing ek schematic net do layout nets mein split hoti hai
Missing device transistor place karna bhool gaye device count mismatch
Parameter mismatch galat isomorphic graph lekin differ karte hain
Property/label error galat port/pin label boundary par matching fail hoti hai

Worked examples


Common mistakes (steel-manned)


80/20 — woh 20% jo 80% deta hai

  1. LVS = layout-netlist extract karo → schematic ke saath graph-compare karo.
  2. Yeh devices + connectivity + parameters check karta hai, isomorphism se, name se nahi.
  3. Main errors: short, open, missing/extra device, param mismatch.
  4. DRC≠LVS≠ERC; LVS clean ≠ correct schematic.

Recall Feynman: ek 12-year-old ko explain karo

Socho tumhare paas LEGO instructions hain (schematic) aur woh model jo tumhare dost ne actually banaya (layout). LVS ek robot hai jo bane hue model ko dekhta hai, figure out karta hai ki kaun si bricks kaun si bricks se connect hain, aur check karta hai ki woh exactly instructions se match karta hai ya nahi. Agar tumhare dost ne accidentally do towers ek saath chipka di (short) ya do bricks click karna bhool gaya (open), toh robot chillata hai kaun sa piece galat hai — iska, sab kuch glue karne aur undo na kar paane se pehle.

LVS kya verify karta hai?
Ki extracted layout netlist schematic netlist ke saath graph-isomorphic hai — same devices, connectivity, aur parameters.
LVS ke do main stages kya hain?
(1) Layout extraction → layout netlist, (2) schematic netlist ke against graph comparison/matching.
LVS nets ko name se match kyun nahi kar sakta?
Layout nets auto-generated hoti hain (jaise N$27); matching graph structure (connectivity + device fingerprints) se honi chahiye, names se nahi.
Layout connectivity polygons se build karne ke liye algorithm kaunsa use hota hai?
Union-find (disjoint-set) overlapping/abutting shapes aur via-connected layers ko merge karta hai, ~O((N+E)·α(N)).
Extraction mein ek MOS transistor kaise recognize hota hai?
Poly crossing diffusion se — overlap gate/channel hai; dono taraf ka diffusion = source/drain; well type NMOS/PMOS deta hai.
Extraction mein W aur L kaise milte hain?
W = poly–diffusion crossing edge ki length; L = current flow ke along poly dimension.
DRC aur LVS mein kya fark hai?
DRC manufacturability check karta hai (spacing/width); LVS check karta hai ki layout intended circuit implement karta hai.
LVS mein ek short kaise dikhta hai?
Do schematic nets ek layout net se map hoti hain.
LVS mein ek open kaise dikhta hai?
Ek schematic net do layout nets mein split ho jati hai.
Kya LVS clean ho sakta hai lekin topology phir bhi galat sizes ke saath 'pass' ho?
Haan — parameter mismatch (jaise galat W/L) ek alag LVS discrepancy hai, chahe connectivity match kare.
Kya LVS clean chip ka correct function guarantee karta hai?
Nahi — yeh sirf prove karta hai ki layout diye gaye schematic ke barabar hai; ek buggy schematic phir bhi pass ho jati hai.
LVS mein graph matching ke neeche kaun si technique hai?
Iterative coloring / partition refinement (Weisfeiler–Leman style) local device/net invariants use karke.

Connections

  • Design Rule Check (DRC) — sibling physical-verification check (manufacturability).
  • Electrical Rule Check (ERC) — floating gates, over-driven nets.
  • Parasitic Extraction (PEX) — extraction ko R/C ke liye timing tak extend karta hai.
  • Netlist and SPICE — reference-netlist format.
  • CMOS Inverter Layout — canonical LVS example.
  • Union-Find (Disjoint Set) — connectivity engine.
  • Graph Isomorphism — matching ka theoretical core.
  • Physical Design Flow / Tape-out — sign-off mein LVS kahan aata hai.

Concept Map

intended circuit

extraction

input graph

reference graph

tests

match nodes

match devices

connectivity by geometry

forms

part of

manufacturability

electrical bugs

prevents costly

Schematic netlist

LVS check

Layout polygons

Extracted netlist

Graph isomorphism

Nets = wires

Devices + W/L params

Union-find on polygons

Physical sign-off

DRC

ERC

Tape-out errors