Illinois Institute of Technology · ECE 429

Lab 3 Tutorial: Inverter Layout, LVS, PEX, and Post-Layout Simulation

Create the physical layout of the Lab 02 CMOS inverter using FreePDK45, verify it with Calibre DRC and LVS, extract layout parasitics, and measure post-layout propagation delay with HSPICE and Synopsys WaveView.

Created by Jia Wang, Aug. 2011. Revised by Erdal Oruklu, February 2013. Revised by Dr. Ken Choi, Feb. 2020; Jan. 2021; Sep. 2026.

1. Setting up Your Account Environment

Use the ECE teaching server Endeavour at endeavour.ece.iit.edu.

Lab 03 continues directly from Lab 02. Return to the same working directory that contains the Cadence library and files created during Lab 02. Do not create a separate unrelated directory.

cd ~/ece429
source /import/scripts/ece429.cshrc

The command above is the only environment setup command required for the current ECE 429 flow.

Important: Every time you open a new terminal, return to the Lab 02 working directory and run source /import/scripts/ece429.cshrc before launching the CAD tools.

Verify that your existing Cadence library, such as my429, is present.

Lab 02 working directory
Figure 1. Return to the Lab 02 working directory before beginning Lab 03.

Launch Virtuoso:

virtuoso

2. Create the Layout View for the Lab 02 Inverter

In the Library Manager, select the library created in Lab 02, such as my429, and select the inverter cell lab02. The schematic and symbol views should already exist.

  1. Select library my429.
  2. Select cell lab02.
  3. Choose File → New → Cell View.
  4. Keep the Library and Cell fields as my429 and lab02.
  5. Set the new View to layout.
  6. Click OK.
Do not create a different cell name. The schematic and layout must remain under the same lab02 cell so that LVS can compare them later.
Create layout cell view
Figure 2. Create a new layout view for the existing lab02 cell.
Virtuoso Layout Suite XL
Figure 3. Virtuoso Layout Suite XL opened for the lab02 layout.

3. Configure the Layout Grid for FreePDK45

Before drawing anything, configure the grid correctly. This step is compulsory because incorrect snap spacing can produce off-grid or unintended geometry and may cause DRC/LVS problems later.

Choose Options → Display. In Grid Controls, use:

SettingValue
Typedots
Minor Spacing0.01
Major Spacing0.1
X Snap Spacing0.01
Y Snap Spacing0.01

The units are micrometers: 0.01 µm = 10 nm and 0.1 µm = 100 nm.

Grid options
Figure 4. Configure the display and snap grid to 0.01 µm.

Click OK, press Ctrl+G to refresh/show the grid, and press F to fit the view.

Checkpoint: Move the cursor and verify that the X/Y values change consistently with the 0.01 µm snap grid. If they do not, stop and contact the TA before drawing.
Configured layout grid
Figure 5. Layout grid after refreshing with Ctrl+G and fitting the view.

4. Reference: Final Inverter Layout

The completed inverter layout is shown below for reference. The PMOS is on top, the NMOS is on the bottom, the gate is shared through polysilicon, VDD is at the top, and GND is at the bottom.

Reference only: Do not draw the whole layout at once. Build it layer by layer using the dimensions in the following sections.
Final inverter reference
Figure 6. Completed FreePDK45 CMOS inverter layout used as the Lab 03 reference.

5. Useful Virtuoso Layout Editor Tips

ActionShortcut / Method
Draw rectangleSelect the layer and press r
Measure / rulerk
MoveSelect object, then m
CopySelect object, then c
Stretch / resizeSelect object, then s
Zoom inCtrl+Z
Zoom outShift+Z
PanArrow keys or mouse wheel
Exit active commandEsc

Press Esc after completing each operation. The active command is also visible through the cursor/status area.

Tip: Use the ruler tool (k) continuously. Measuring while you draw is much easier than correcting many DRC errors later.

6. NMOS Transistor Layout

6.1 Draw the NMOS Active Region

The NMOS has width 90 nm and gate length 50 nm. With a vertical poly gate, the active-region height is 90 nm.

10 + 70 + 40 + 50 + 40 + 70 + 10 = 290 nm

Select active | drw, press r, and draw a 290 nm × 90 nm rectangle. Verify it with k.

NMOS active
Figure 7. NMOS active region: 290 nm × 90 nm.

6.2 Add Source/Drain Contacts and Poly

Use contact | drw for two 70 nm × 70 nm contacts. Use approximately 10 nm active enclosure and 40 nm contact-to-poly spacing. Then select poly | drw and draw a vertical 50 nm-wide gate.

Extend the poly at least 60 nm beyond active; this tutorial uses about 70 nm.

NMOS contacts and poly
Figure 8. NMOS contacts and 50 nm polysilicon gate.

6.3 Create the NMOS Body Tap

Create a separate 90 nm × 90 nm active region with a 70 nm × 70 nm contact. Keep approximately 80 nm spacing from the NMOS active region.

NMOS body tap
Figure 9. NMOS body-tap active region and contact.

6.4 Add the P-Well

Select pwell | drw and draw a P-well around the transistor and body tap. The tutorial uses approximately 580 nm × 210 nm with about 60 nm active enclosure.

NMOS pwell
Figure 10. P-well surrounding the NMOS transistor and body tap.

6.5 Add Implant Layers

Important: NMOS source/drain active uses nimplant | drw. The NMOS body tap uses pimplant | drw.
Implant detail
Figure 11. Implant geometry and dimensions.
NMOS implants
Figure 12. Correct implant layers for the NMOS transistor and body tap.

6.6 Clean Up Rulers and Layer Selectability

Remove unnecessary ruler annotations before screenshots. Pay attention to the S (Selectability) column in the layer palette; if a layer is not selectable, you will not be able to move, copy, stretch, or edit its shapes.

Clean NMOS view
Figure 13. Clean NMOS view after dimension verification.

6.7 Add Metal1 and GND

Metal1 itemTutorial value
Minimum width70 nm
Minimum spacing70 nm
Contact enclosure40 nm

Select metal1 | drw, connect the NMOS source/body tap to GND, and draw the GND rail.

NMOS Metal1 ground
Figure 14. Completed NMOS section with Metal1 and GND rail.

7. Design Rule Checking (DRC)

Run DRC frequently while the layout is still simple.

Choose Calibre → Run DRC. The FreePDK45 rule file should already be loaded, normally similar to:

$PDK_DIR/ncsu_basekit/techfile/calibre/calibreDRC.rul

Click Run DRC.

Calibre DRC window
Figure 15. Calibre Interactive DRC using the FreePDK45 rules.

In Calibre RVE, a clean layout shows a result count of 0 for every rule.

RVE zero violations
Figure 16. NMOS section with zero DRC violations.

8. Create the PMOS Transistor from the NMOS Layout

Use the NMOS as a template. Make only the active, contact, and poly layers selectable, box-select those shapes, press c, and place the copy above the NMOS.

PMOS copy template
Figure 17. Copy the NMOS active/contact/poly geometry for the PMOS.

8.1 Stretch the PMOS to 180 nm

The PMOS width is 180 nm. Use s to stretch the copied active region from 90 nm to 180 nm and extend the poly as required. Keep the horizontal dimensions unchanged.

PMOS stretched
Figure 18. PMOS active region stretched to 180 nm.

8.2 Add PMOS Implant, N-Well, and Body Tap

Layer assignment: PMOS source/drain active uses pimplant | drw; PMOS body tap uses nimplant | drw; PMOS structures are enclosed by nwell | drw.

9. Run DRC Again After Creating the PMOS

Run Calibre DRC again. If errors appear, expand the failing rule in RVE and use highlight/navigation controls to locate the exact geometry.

In the current example, Calibre reports three Contact.3 violations:

Contact.3: Contact must be inside Metal1 and active or poly.

Correct the highlighted geometry and maintain approximately 40 nm Metal1 enclosure around the contact for this tutorial geometry. Rerun DRC until the violations are removed.

Contact3 errors
Figure 19. Calibre RVE highlighting Contact.3 violations.

10. Complete the Inverter Interconnects

Use metal1 | drw to complete the inverter:

  • Create the top VDD rail.
  • Connect the PMOS source and body tap to VDD.
  • Keep the NMOS source/body tap connected to GND.
  • Join the PMOS and NMOS drains to create the output.
  • Connect the PMOS and NMOS gates to create the common input.
VDD Metal1
Figure 20. PMOS Metal1 connections and VDD rail.
Completed inverter
Figure 21. Completed CMOS inverter layout before final verification.

11. Final DRC Verification

Run Calibre DRC one final time.

Required result: 0 DRC violations
Required report screenshot: Show the completed inverter layout and Calibre/RVE result with zero errors. Keep the Endeavour username/name and system date/time visible. Do not crop them out.
Final DRC zero
Figure 22. Final inverter layout with zero DRC violations.

12. Layout vs. Schematic (LVS) Verification

DRC checks physical design rules, but it does not prove that the layout is electrically equivalent to the Lab 02 schematic. LVS compares the extracted layout connectivity against the schematic.

12.1 Complete the Input Metal1 Connection

Before creating pins, connect the common PMOS/NMOS polysilicon gate to Metal1 using the appropriate contact structure so that the inverter input can be accessed as a layout pin.

Input Metal1 connection
Figure 23. Metal1 connection added to the common polysilicon gate for the inverter input.
Before adding pins: Run DRC again and confirm zero violations after the input connection is added.

12.2 Create the Layout Pins

Choose Create → Pin and create these four pins exactly:

vdd!
gnd!
in
out

For each pin, enable Create Label. Click Options and set the label height to approximately 0.05. Use metal1 with purpose drawing.

Create Pin dialog
Figure 24. Create Pin dialog configured for a Metal1 pin such as vdd!.
PinPlace it on
vdd!Top VDD Metal1 rail
gnd!Bottom GND Metal1 rail
inMetal1 connected to the common poly gate
outMetal1 connected to the common PMOS/NMOS drain node
Important: Use the names exactly as shown, including the exclamation marks in vdd! and gnd!.
Layout with pins
Figure 25. Completed inverter layout with the four LVS pins.

After creating all pins, use File → Check and Save.

13. Run Calibre LVS

Choose Calibre → Run LVS.

In the current Calibre Inputs page, verify both the layout and source in the same window.

Layout PathSource Path
Layout Format = GDSIISource Format = SPICE
Export from layout viewer = checkedExport from source viewer = checked
Library = my429Library = my429
Top Cell = lab02Top Cell = lab02
View = layoutView = schematic
Calibre LVS inputs
Figure 26. Current Calibre nmLVS Inputs window showing layout and schematic sources.

Click Run LVS. A successful result should show:

CORRECT
LVS correct
Figure 27. Calibre LVS report and RVE showing a successful CORRECT comparison.
Required report screenshot: Capture the successful LVS result with the system timestamp and identifying information visible.

13.1 If LVS Reports an Error

Use Calibre RVE to expand the discrepancy. Common causes include missing/incorrect pins, shorts, opens, wrong body connections, wrong transistor type, or device dimensions that do not match the schematic.

The older screenshot below is included only as an example of how a property mismatch can appear in RVE.

Example LVS property error
Figure 28. Example of an LVS property mismatch. Use current RVE messages to identify the actual problem.
Final LVS requirement: DRC = 0 violations and LVS = CORRECT.

14. Parasitic Extraction and Post-Layout Simulation

Post-layout simulation includes parasitic effects introduced by the physical layout. Calibre PEX extracts these parasitic resistances and capacitances so that HSPICE can simulate a more realistic inverter model.

14.1 Run Calibre PEX

Choose Calibre → Run PEX.

In Inputs, verify:

Layout PathSource Path
Layout Format = GDSIISource Format = SPICE
Export from layout viewer = checkedExport from source viewer = checked
Library = my429Library = my429
Top Cell = lab02Top Cell = lab02
View = layoutView = schematic
PEX inputs
Figure 29. Calibre PEX Inputs page for the lab02 layout and schematic.

14.2 Verify PEX Output Settings

Click Outputs. Leave the current default settings unchanged:

Extraction Mode          = xRC
Level                    = Transistor Level
Resistance/Capacitance   = RCC
Inductance               = No Inductance
PEX outputs
Figure 30. Current Calibre PEX output settings.

14.3 Run PEX

Click Run PEX. The current flow does not require a separate extracted-layout window to appear. Verify the transcript.

A successful run should show:

xRC Errors = 0
xRC run finished with exit code 0

Warnings may be present. For this lab, the required condition is zero xRC errors.

PEX zero errors
Figure 31. Successful Calibre PEX run showing zero xRC errors.

Save your work and close Virtuoso. Keep a terminal open in the same ECE 429 working directory.

14.5 Post-Layout Simulation with HSPICE

14.5.1 Locate the Extracted Netlist

After PEX, the working directory should contain the extracted parasitic netlist:

lab02.pex.netlist

The original Lab 02 simulation file lab02.sp should also still be present.

PEX files directory
Figure 32. Working directory containing lab02.pex.netlist and the Lab 02 simulation files.

14.5.2 Create the Lab 03 SPICE File

cp lab02.sp lab03.sp
gedit lab03.sp
Initial lab03 sp
Figure 33. Create lab03.sp from the Lab 02 HSPICE simulation file.

14.6 Replace the Schematic Subcircuit

In lab03.sp, comment out every line of the original schematic subcircuit from .subckt lab02 ... through .ends lab02 by adding * at the beginning of each line.

*.subckt lab02 in out
*m0 ...
*m1 ...
*.ends lab02

.INCLUDE "lab02.pex.netlist"

14.7 Verify the Extracted Pin Order

Open lab02.pex.netlist and find the extracted subcircuit declaration. In the current extraction it is:

.SUBCKT LAB02 IN GND! VDD! OUT

The instance in lab03.sp must use this exact terminal order.

14.8 Update the Inverter Instance

Replace the original schematic instance:

xi0 input output lab02

with:

xi0 input gnd! vdd! output lab02
PEX pin order and SPICE edits
Figure 34. Verify the extracted subcircuit pin order and update lab03.sp accordingly.
Checkpoint: The instance terminal order in lab03.sp must exactly match the .SUBCKT order in lab02.pex.netlist.

14.9 Run the Post-Layout HSPICE Simulation

hspice lab03.sp | tee lab03.hspice.output
Running postlayout HSPICE
Figure 35. Run the post-layout HSPICE simulation using lab03.sp.

A successful run ends with:

hspice job concluded
HSPICE concluded
Figure 36. Successful post-layout HSPICE run ending with hspice job concluded.

14.10 View the Post-Layout Waveforms and Measure Delay

Launch Synopsys WaveView:

wv

Open lab03.tr0, expand the top-level signals, and display:

v(input)
v(output)

14.11 Measure Post-Layout Propagation Delay

Use Measurement Tool → Time Domain → Delay. Set:

Signal      = v(output)
Ref. Signal = v(input)
Measurement level = 50%

For a 0–1.1 V logic swing, the 50% crossing is 0.55 V.

DelayOutput transitionInput reference
tPHLHigh → LowLow → High
tPLHLow → HighHigh → Low
tpd = (tPHL + tPLH) / 2
WaveView postlayout delays
Figure 37. Post-layout input/output waveforms and propagation-delay measurements in Synopsys WaveView.
Example only: The screenshot shows delays around 10.2 ps and 7.9 ps. Students must report the values measured from their own simulation.

14.12 Compare Schematic and Post-Layout Delay

SimulationtPHLtPLHtpd
Lab 02 schematicYour valueYour valueYour value
Lab 03 post-layoutYour valueYour valueYour value

The post-layout delay generally differs from the schematic-only delay because the PEX model includes physical interconnect/device parasitic resistance and capacitance.

Required Lab 03 evidence:
  • Completed inverter layout.
  • Final DRC result with 0 violations.
  • LVS result showing CORRECT.
  • PEX result showing 0 xRC errors.
  • Successful HSPICE run ending with hspice job concluded.
  • WaveView plot showing v(input), v(output), and post-layout delay measurements.
  • Schematic-vs-post-layout delay comparison.
Lab 03 flow complete: Layout → DRC → Pins → LVS → PEX → Post-Layout HSPICE Simulation → Delay Comparison.