Lab 1
Lab 1
LAB 1
Cell Design and Verification
Issue 1.0
Contents
1 Introduction.............................................................................................1
1.1 Lab overview..........................................................................................................................1
2 Learning Objectives..................................................................................1
3 Overview of VLSI CAD Tools.....................................................................2
4 Tool Setup............................................................................................... 2
5 Start Virtuoso.......................................................................................... 2
5.1 Library Manager.....................................................................................................................3
5.2 Create a library......................................................................................................................3
This lab introduces you to the basics of how to use Cadence to design, simulate, and verify
schematics and layout of logic gates. It also serves as a stand-alone tutorial to quickly get up to
speed with the Cadence tools. This lab is divided into two parts.
In the first part of this lab, you will draw transistor-level schematics to build cells for NAND, NOT,
and AND gates and create a symbol for each cell. You will then simulate each cell by applying digital
inputs and checking that the outputs match your expectations.
In the second part of this lab, you will draw a layout for each gate you created in part 1. The layout
indicates how the transistors and wires are physically arranged on the chip. Using design rules check
(DRC) and layout versus schematic check (LVS), which is provided by the tool, the layout is checked
to ensure it satisfies the design rules and that the transistors match the schematic.
Finally, you will apply what you have learned by independently designing NOR and OR gates.
The next three labs extend this one to build the simple 8-bit microprocessor chip described in the
Getting Started guide. Most of the microprocessor is provided, but one of each interesting piece has
been removed. In Lab 2, you will use the AND and OR gates to complete an arithmetic/logic unit
(ALU) and then finish the datapath. In Lab 3, you will design the aludecoder logic by hand and then
synthesize, place, and route a controller. In Lab 4, you will place the controller, aludecoder, and
datapath together, including the input/output pads and autoroute the whole design to form the
complete chip.
2 Learning Objectives
At the end of this lab, you should be able to:
Draw transistor-level cell schematics using Cadence Virtuoso
Simulate transistor-level schematics using NC-Verilog
Draw cell symbols using Cadence Virtuoso
Draw cell layouts using Cadence Virtuoso
Perform design rule checking (DRC) and fix discrepancies
Perform layout vs. schematic (LVS) checking and fix discrepancies
Construct, simulate, and verify hierarchical cells
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 1
3 Overview of VLSI CAD Tools
This set of laboratories uses the Cadence and Synopsys Electronic Design Automation (EDA) tools
which when correctly set up are easy to use, as this tutorial will demonstrate.
There are two general strategies for chip design. Custom design involves specifying how every
transistor is connected and physically arranged on the chip. Synthesized design involves describing
the function of a digital chip in a hardware description language such as Verilog or VHDL and then
using a computer-aided design tool to automatically generate a set of gates that perform this
function, place the gates on the chip, and route the wires to connect the gates.
Most commercial designs are synthesized today because synthesis takes less engineering time.
However, custom design gives more insight into how chips are built and into what to do when things
go wrong. Custom design also offers higher performance, lower power, and smaller chip size.
4 Tool Setup
These labs assume that your institution has the Cadence and Synopsys tools installed on a suitable
Linux server as described in the Getting Started Guide. They also assume you have a way to connect
to the server from a laptop or desktop computer and to run X Windows applications.
The tools generate a bunch of random files. It’s best to keep them in one place. In your home
directory, create some directories by typing:
mkdir IC_CAD
mkdir IC_CAD/cadence
5 Start Virtuoso
Before you start the Cadence tools, open a terminal and change into the cadence directory:
cd ~/IC_CAD/cadence
Start Cadence with the NCSU extensions using the following command:
cad-ncsu &
The above command starts the Virtuoso software and will open the Virtuoso
Design Environment and the Library Manager windows.
A “What’s New” and a Library Manager window may open. You can turn off the “What’s New”
window in the future by choosing Edit • Off at Startup.
You may see some warnings about “no route to host” and missing fonts in the terminal; you can
safely ignore these. Scroll through the Virtuoso window and look at the messages displayed as
the tool loads up. Get in the habit of watching for the messages and recognizing any that are out
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 2
of the ordinary. This is very helpful when you encounter problems. At present, you shouldn’t see
any warnings in Virtuoso.
If Cadence crashes, it might leave your locks on open files in place. If your lock shouldn’t be there,
you can manually remove it by going into the library directory and deleting the .cdslck files. As
always, be careful when deleting files.
Familiarize yourself with the Library Manager. Your cds.lib file includes many libraries from the
North Carolina State University Cadence Design Kit supporting the different MOSIS processes. It
also includes libraries from the University of Utah. The File menu allows you to create new libraries
and cells within a library, while the Edit menu allows you to copy, rename, delete, and change the
access permissions.
If the Library Manager window is not open, you can open it from the
Virtuoso window by selecting: Tools • Library Manager.
Leave the path blank, and it will be put in your current working directory
(~/IC_CAD/cadence). Set the following options.
1
Copying a library with cp -r <srcpath> <dstpath> does work correctly, and you
will find this helpful when working with a partner on the final project.
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 3
UofU_TechLib_ami06 is a technology file for the American Microsystems
(now ON Semiconductor) 0.6 μm process, containing design rules for layout.
You should see the new library lab1_xx listed (left side) among other libraries in the Library Manager
Window.
To create a schematic view, in the Library Manager, highlight the library lab1_xx and then:
You may get a window asking you to confirm that cmos_sch should be
associated with this tool (click Yes), or one complaining that it failed to
check out the license for Virtuoso_Schematic_Editor_L (Click Session).
Your goal is to draw a gate like the one shown in Figure 1. We are working in a 0.6 μm process with λ
= 0.3 μm. Our NAND gate will use 12 λ (3.6 μm) nMOS and pMOS transistors.
To create the schematic as shown in Figure 1, you will need to create instances of transistors (nmos
and pmos), power, and pins and connect them using wires.
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 4
Figure 1: nand2 cmos_sch
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 5
6.3 Useful shortcuts
The following are shortcuts that will be useful when using Cadence tools.
Exit a mode when in editor: ctrl+c OR Esc (press Esc twice if a dialog box is open)
The bottom of the schematic editor window (see Figure 2) shows you the mode you are in.
showClickInfo() is the normal mode
Undo: u (note that saving clears your undo history)
Copy: Edit • Copy (c)
Move: Edit • Move (m)
Delete: Edit • Delete (Del).
Properties: Edit • Properties • Object (q)
Enter “a b” (no quotation marks, and a space between the two pin names).
Set direction to “input.” The tools are case-sensitive, so use lower case everywhere.
Place the pins, being sure that a is the bottom one. Pin order doesn’t matter logically, it
does matter physically and electrically, so you will get errors if you reverse the order.
Also place an output pin y.
It is a good idea to name every net (wire) in a design as this will aid in tracking down
a problem later on one of the unnamed nets. Every net in your schematic is
connected to a named pin or to power or ground except the net between the two
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 6
series nMOS transistors.
Choose Create • Wire name… (l)
Enter mid or something like that as the name
Click on the wire to name it
You’ll probably get one warning about a “solder dot on crossover” at the 4-way junction on the
output node. To stop this, go to
Check • Rules Setup… and click on the Physical tab in the dialog.
Change Solder On CrossOver from “warning” to “ignored” and close the dialog.
Then, click Check and Save again and the warning should be gone.
Fix any other warnings. A common mistake is wires that look like they might touch but don’t actually
connect. Delete the wire and redraw it.
Poke around the menus and familiarize yourself with the other capabilities of the schematic editor.
Logic verification involves proving that the cells perform the correct function. One way to do this is
to simulate the cell and apply a set of 1’s and 0’s called test vectors to the inputs and then check that
the outputs match expectation.
Typically, logic verification is done first on the RTL to check that the specification is correct. A
testbench written in Verilog or VHDL automates the process of applying and checking all the vectors.
The same test vectors are then applied to the schematic to check that the schematic matches the
RTL.
You will begin by simulating an RTL description of the NAND gate to become familiar with reading
RTL and understanding a testbench. In this tutorial, the RTL and testbench are written in System
Verilog, which is a 2005 update to the popular Verilog hardware description language.
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 7
This tutorial describes how to use NC-Verilog, which integrates gracefully with the other Cadence
tools. NC- Verilog compiles your Verilog into an executable program and runs it directly, making it
faster than the older interpreted simulators.
Make a new directory for simulation (e.g., nand2sim). Copy nand2.sv, nand2.tv from the course
directory into your new directory and copy nand2.testfixture, renaming it to testfixture.verilog. Use
the commands below to do this:
mkdir nand2sim
cd nand2sim
cp /courses/cmosvlsi/20/lab1/nand2.sv .
cp /courses/cmosvlsi/20/lab1/nand2.tv .
cp /courses/cmosvlsi/20/lab1/nand2.testfixture
testfixture.verilog
nand2.sv is the SystemVerilog RTL file, which includes a behavioral description of a nand2 module
and a simple self-checking testbench that includes testfixture.verilog.
testfixture.verilog reads in testvectors from nand2.tv and applies them to pins of the nand2 module.
After each cycle, it compares the output of the nand2 module to the expected output and prints an
error if they do not match. Look over each of these files and understand how they work.
First, you will simulate the nand2 RTL to practice the process and ensure that the testbench works.
Later, you will replace the behavioral nand2 module with one generated from your schematic and
will resimulate to check that your schematic performs the correct function.
You’ll be left at the ncsim command prompt. Type quit to finish the simulation.
If the simulation hadn’t run correctly, it would be helpful to be able to view the results.
NC-Verilog has a graphical user interface called SimVision. The GUI takes a few seconds to load,
so you may prefer to run it only when you need to debug. To rerun the simulation with the GUI,
type:
sim-ncg nand2.sv
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 8
Figure 3: SimVision Design Browser
You’ll see the waveforms of your simulation; inspect them to ensure they are
correct. The 0 errors message should also appear in the console.
If you needed to change something in your code or testbench or test vectors, or wanted to add
other signals, do so and then click Simulation • Reinvoke Simulator to recompile everything and
bring you back to the start. Then, choose Run again.
Make a habit of looking at the messages in the console window and learning what is
normal. Warnings and errors should be taken seriously; they usually indicate real
problems that will catch you later if you don’t fix them.
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 9
8 Part 1c: Schematic Simulation
You will verify your schematic by generating a Verilog deck using the NC-Verilog tool and pasting it
into the RTL Verilog file.
Initialize Design
Generate Netlist
Simulate
Figure 5: NC-Verilog
If a dialog pops up asking if you want to keep the previously run directory environment, click
No.
If a dialog pops up asking if you want to initialize simulation environment, click OK.
Look in the Virtuoso window for errors and correct them. You should see that the pmos, nmos, and
nand2 cells were all netlisted.
Beware that the netlister indicates “successful” even if it produces garbage! In the case
that the netlister fails, try removing the directory created and redoing the process.
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 10
8.2 Edit the generated files and create test vectors
In your Linux terminal window, cd into the directory that was created. You’ll find quite a few files.
The most important are verilog.inpfiles, testfixture.template, and testfixture.verilog.
The file verilog.inpfiles states where they are. Take a look at the netlist and other files.
The file testfixture.template defines the top-level module that instantiates the device under test
and invokes testfixture.verilog.
Run the following commands to copy your testfixture.verilog and test vectors from your nand2sim
directory to your nand2_run1 directory.
cp ../nand2sim/testfixture.verilog .
cp ../nand2sim/nand2.tv .
This will print the results in simout.tmp. The –sv flag indicates that the simulator
should accept SystemVerilog syntax used in the testfixture.verilog.
Set the Simulator mode to “Batch” and click on the Simulate button.
You should get a message that the batch simulation succeeded. This doesn’t
mean that it is correct, merely that it run.
In the terminal window, view the simout.tmp file. It will give some statistics about the compilation
and then should indicate that the 4 tests were completed with 0 errors.
If the simulation fails, the simout.tmp file will have clues about the problems. One common source
of problem is when you renetlist after you have copied over testfixture.verilog, rewriting your
testfixture with a default one that does nothing.
Change the simulator mode to Interactive to rerun with the GUI. Be patient; the GUI takes several
seconds to start and gives no sign of life until then.
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 11
Add the waveforms again and run the simulation. You may need to zoom to fit all the waves. For
some reason, SimVision doesn’t print the $display message about the simulation succeeding with no
errors. You will have to read the simout.tmp file at the command line to verify that the test vectors
passed. If you find any logic errors, correct the schematic and resimulate.
When creating your symbol, it is a good idea to keep everything aligned to the grid; this will make
connecting symbols simpler and cleaner when you need it for another cell.
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 12
The green body of the NAND is formed from an open C-shaped polygon, a semicircle, and a small
circle.
Move the lines and terminals around to make it pretty. The Edit • Stretch command may be
helpful.
Finally,
This creates a red box around the symbol that will define where to click to select the symbol
when it appears in another schematic.
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 13
11 Part 1f: Hierarchical Schematic
A CMOS AND gate consists of a NAND gate followed by a NOT gate. The schematic is constructed
by connecting the symbols for the two gates that you have already drawn. This is an example of
hierarchical design, reusing pre-existing components to save work.
Create a schematic Cell named and2 and enter schematic for the View.
This time, it is schematic and not cmos_sch because the cell will instantiate other
cells rather than transistors.
Copy the nand2.tv and testfixture.verilog files to the run directory for your and2 gate and modify
them to contain the proper vectors for the and2 function.
Make a symbol for the and2. It should be similar to the nand2 but should leave off the output
bubble. You may save yourself some time with judicious use of copy and paste or by using the copy
command in the Library Manager.
The nand2 has two nMOS transistors in series between GND and Y. It has two pMOS transistors
in parallel between VDD and Y. The blue power and ground busses run horizontally in metal1. A
bus means a wire in this context.
The green n+ diffusion (ndiff) runs parallel to and just above the GND bus. The yellow p+
diffusion (pdiff) runs parallel to and just below the VDD bus.
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 14
The inputs run vertically on polysilicon, crossing diffusion to form the four transistors. Metal1 and
contacts are used within the cell to connect the transistors to GND, VDD, and the output Y.
The transistors fit on the same pitch as the metal tracks, so the cell must be 3 tracks wide to
accommodate the three contacts on the pMOS transistors.
All cells should be drawn so that they “snap together” like LEGOs when placed adjacently.
Therefore, we establish a set of rules for our cell library so they will satisfy design rules alone and
also when connected together.
In our system,
metal2 will run vertically. Each contacted metal2 track has a pitch of 8 λ (4 λ width + 4 λ
spacing to the next track).
Metal3 will run horizontally. Each contacted metal3 track has a pitch of 10 λ (6 λ width + 4
λ spacing).
To avoid wasted space, each cell should be a multiple of the track pitches in size. Hence, it
should be a multiple of 8 λ wide and 10 λ tall.
All the cells in the same library need to be the same height so they can snap together. Thus, the
cell height may be set by the tallest cell (generally a complex cell such as a flip-flop) with the
widest transistors.
The cell height must also be tall enough to allow all of the horizontal wires in a datapath to pass
overhead, which depends on the datapath being built. For the labs, we use a 10-track library with
room for 10 horizontal metal3 lines to pass overhead. Based on the past experience, this is
sufficient to easily build complex cells and to route interesting datapaths. Hence,
The width of the cell depends on the connections inside the cell. Conveniently, the metal1 and
metal2 pitch is the same (8 λ),
from the nand2 stick diagram, the cell must be 3 tracks (24 λ) wide.
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 15
Although metal1 can be 4 λ wide, we draw the GND and VDD busses 8 λ wide to carry the larger
currents needed in the power supply.
In this context, there is ambiguity about width and length vs. width and height. We normally refer
to a wire as having a length and width. The length is the long dimension and the width is the
skinny dimension.
Thus, wires have a width of 8 and a length of 24 to run horizontally over the whole cell. But a
rectangle has a width and a height, with the width being the x dimension and height being the y
dimension. Thus, the width of the rectangles is 24 and the height is 8.
The origin of the cell is (x = 0; y = 0). Let us define x = 0 λ as the left side of the cell. Hence, x = 24 λ
is the right side of the cell. See Figure 11.
Let us center the GND bus on y = 0. The bus has a width of 8, so it extends 4 above and below the
center. Hence, the corners of the GND bus are (0, -4) and (24, 4). See Figure 11.
For a 10-track tall cell, the VDD bus must be 9 tracks higher, or centered at 90 λ. Hence, its corners
are (0, 86 and 24, 94). See Figure 11.
Figure 11: VDD and GND busses Figure 12: Well and substrate contacts
Each cell has well and substrate contacts centered under the VDD and GND busses, to tie the
bodies of the transistors to the supply voltages. The pitch of the contacts is also 8 λ, so the
number of contacts is the same as the number of tracks. These are shown in Figure 12.
The design rules call for a spacing of 4 λ between metal and diffusion. To make cells snap
together nicely, avoid putting any transistors or internal wires (excluding VDD and GND) closer
than 2 λ to the left or right boundaries of the cell. Hence, adjacent cells will have a spacing of at
least 4 λ between their internal contents.
To keep vertical metal 2 λ from the cell boundary, the leftmost vertical metal track should start at
x = 2 and extend to x = 6. In other words, they are centered on x = 4. The track pitch is 8 λ, so the
subsequent tracks are centered on x = 12, x = 20, etc.
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 16
Polysilicon has a width of 2 and is placed between the metal tracks to make transistors. Hence, it
should be centered on x = 8, and x = 16. It has a minimum separation of 3 λ from unrelated
diffusion. Hence, to avoid the substrate and well contacts, it must start 1 λ above GND and end 1 λ
below VDD, as shown in Figure 13.
Polysilicon extends at least 2 λ past diffusion when forming a transistor. Hence, the ndiff must
start 3 λ above GND. The pdiff must start 3 λ below VDD. Like metal, beware of the ambiguity in
the meaning of width of diffusion. Because poly is running vertically and diffusion is running
horizontally, the width of a transistor corresponds to the height of the diffusion.
In our nand2 cell, the heights of the ndiff and pdiff are both 12 λ because those are the widths of
the nMOS and pMOS transistors in the schematic. In the schematic, we specified the width as
3.6u.
Recall that 1 λ = 0.3u (0.3 μm), so the height is 3.6u × 1 λ / 0.3u = 12 λ. Therefore, we need to
draw strips of ndiff and pdiff starting and ending 2 λ from the ends of the cell (to give clearance to
the next cell) and starting 2 λ above or below the polysilicon gates and extending vertically by 12
λ, as shown in Figure 14.
The pMOS transistors must be surrounded by an n-well by at least 6 λ on each side, and the well
should be separated from the nMOS transistors by at least 6 λ. The well should be the same size in
all cells to avoid interreference with nMOS in neighboring cells, and also to notch errors when
cells are abutted. In our library, we choose to bring the n-well down to y = 40. This gives slightly
more space for pMOS than nMOS transistors, which is a good choice because the pMOS are
typically wider than nMOS. The n-well extends up to y = 96 to sufficiently enclose the well
contacts. To surround transistors by 6, it must extend 4 λ left and right of the VDD bus, as shown
in Figure 15.
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 17
Figure 15: n-well Figure 16: n-select and p-select
The MOSIS design rules call for n-select and p-select layers enclosing the ndiff and pdiff by at
least 2 λ. Each is a rectangle. The n-select starts 1 λ above GND and ends 4 λ below the n-well. The
p-select starts 1 λ below VDD and ends 4 λ above the n-well boundary. Both extend the full width
of the GND/VDD metal lines, as shown in Figure 16. Hence, when cells are abutted, the active
regions also abut, and there are no notches.
All leaf cells resemble Figure 16, with power and ground, n-well, well and substrate contacts,
horizontal strips of diffusion, and vertical polysilicon inputs. Different cells will have different
widths, but the template is otherwise the same.
The cells are customized by adding metal1 and contacts to connect the power, ground, and inputs
and outputs. Most cells can be built using no metal2 or metal3 wires inside the cell, so wires can
easily be routed over the cell in these layers without interference. Stick diagrams show poly
running purely vertically, but we often bend the poly to bring transistors closer together if there is
no contact required between them. This is worth the trouble because it reduces the capacitance,
improving speed and power consumption.
First, create a new cellview for nand2 called layout. It should be of type layout and
always open with Layout GXL.2
Click OK to accept nand2 cmos_sch when prompted about the Source View
Definition. You may also get some warnings about Assura.
2
If you use Layout L instead of GXL, you may have LVS errors later.
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 18
Your goal is to draw a layout exactly like the one shown in Figure 17. Neatness and precision are
imperative to get a good layout. Keep in mind the principles described above so the reasons for the
dimensions are clear.
The University of Utah technology file is configured on a half-lambda grid, so grid units are 0.15 μm.
Take care that everything you do is an integer multiple of λ so you don’t come to grief later on. The
heavy dots are on a 10-λ grid and the smaller dots are on a 2-λ grid. Also, units are listed in
microns, so you will have to mentally convert 1 λ = 0.3 μm.
In this design process, nactive and pactive stand for n+ diffusion and p+ diffusion, respectively. They
must be surrounded by a rectangle of nselect or pselect, respectively; in a cleaner flow, the select
layers might be automatically generated.
By default, the Layout editor snaps to a 0.5 λ (0.15 μm) grid. Getting off the lambda grid will cause
you grief, so start by changing this.
Chose Options • Display… (e) and set the X and Y snap spacing to 0.3 (the units are
microns).
Set the major grid spacing to 3 microns (10 λ)
Set the minor grid spacing to 0.3 micron (1 λ).
Using the save option, you may save your display settings to a file and reload it
whenever you restart Cadence or the Layout editor using the load option.
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 19
Some useful menu options when drawing the layout are:
Zoom in and zoom out. There are several zoom commands under the window menu.
Pan with the arrow keys.
To create a rule for measurement, use Tools • Create Measurement (k).
o Use the ruler to measure distances
o Use Tools • Clear All Rulers to eliminate them when you are done.
To stretch a drawing, use Edit • Stretch (s).
To change the size or layer of a shape, use Edit • Properties (q)
To merge multiple selected rectangles on a given layer into a single convenient polygon, use
Edit • Basic • Merge (shift + m).
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 20
12.2.6 n-well and select layers
Now is a good time to draw the n-well and the select layers.
The n-well should extend from 40 λ to 96 λ vertically and should extend 4 λ beyond the
edge of the cell in both directions (-4 to 28 λ).
The p-select should extend from 44 to 85 λ vertically and should be as wide as the power
line (0 to 24 λ).
The n-select should extend from 5 to 36 λ vertically and should also be as wide as the
power line.
Another rectangle of n-select must be drawn exactly covering the power line to surround
the n-well taps.
A rectangle of p-select should be drawn covering the ground line to surround the substrate
taps.
Figure 18 shows the routing grid superimposed on the cell. The metal2 wires will run in the same
columns as the well and substrate contacts, centered 4, 12, 20 λ, etc. right of the cell origin. The
metal3 wires will run 0, 10, 20, 30, 40, 50, 60, 70, 80, and 90 λ up from the cell origin. Inputs and
outputs should be placed on 4 × 4 λ squares of metal2 in the appropriate columns. For example, a,
b, and y are all on this grid.
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 21
12.2.8 Input and output pins
To create the inputs, you will need a stack going all the way from metal2 down to polysilicon:
metal2, via, metal1, cc, and poly.
The metal can be 4 × 4 λ, and the contacts/vias 2 × 2 λ, but the poly may need to extend a
bit further to reach the main polysilicon lines.
The output is already on metal1, so you only must add metal2 and a via.
Finally, place pins to define where the cell connects to other cells at the next level of the hierarchy.
Select metal2 in the layer window.
Your design should now resemble Figure 18 and should pass DRC. Save the layout.
12.3.2 LVS
The next step is to prove that the layout matches the schematic. This is done by
extracting the transistors and their connections from the layout and then running a
layout-vs.-schematic (LVS) tool.
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 22
12.3.2.1 Extract transistors and connections
To extract the transistors and connection, in the layout editor,
Got to: Verify • Extract… and run it with the default settings to create an extracted
cellview. Make sure “Extract Method” is “flat.”
Look in the Virtuoso window for errors. You may wish to open the new view from the library
manager to see what was produced.
The default settings for LVS are good, but if they get cleared, LVS will
mysteriously not work sometimes, so if you are sure a cell should be passing LVS
and it doesn’t, check that the Run Directory is LVS, the Rules File is divaLVS.rul,
and the Rules Library is checked and is UofU_TechLib_ami06.
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 23
If you are lucky, you will get a window popping up saying that the job succeeded. This doesn’t mean
that LVS passed, but merely that it ran. Click the Output button to look at the results. Familiarize
yourself with the results. You want to see a statement that “The net-lists match.” Tracking
mismatches is an acquired skill and can be tricky. Start with a careful visual examination of both the
layout and schematic to be sure you’ve drawn what you intended. Often, looking in the LVS
directory mentioned in the report will give more information about problems. This may involve a
tedious effort of reading the netlist file and sketching a diagram of the mismatched components.
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 24
Switch back to the LVS window (not the layout window) and click Error Display. A new
window should open. It can be helpful to change the Error Color to white. Select the Auto-
Zoom checkbox and click First. The Extracted view should zoom in and highlight
approximately where the error might be, as seen in Figure 21. In this case, it detected that
the nMOS transistors are in the wrong order, so it is highlighting one edge of them. The
message in the Error Display window might also be useful.
The Error Display can sometimes work on the schematic view, which is often easier to understand.
Do not be discouraged by a high number of errors, as a single problem may cause dozens of errors to
show up in this display.
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 25
When you draw layouts, follow these guidelines:
• Place the nMOS transistors close to GND and the pMOS transistors close to power (with
poly ending 1 λ away from the wide wire). The largest transistors that can be drawn are
27 λ for nMOS and 37 λ for pMOS.
• Place input and output pins on metal2. The pins should fall on the routing grid.
There should never be more than one pin in a column.
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 26
Figure 22: and2 layout Figure 23: and2 hierarchical layout view
Now you will need new pins at this level of hierarchy for a, b, y (from the inverter output), vdd! and
gnd! The inputs and outputs should be 4 × 4 metal2 squares on top of the pins from the lower level
of hierarchy, while the power and ground should be metal pins covering the entire power/ground
busses.
Check your design with DRC and LVS and fix any errors.
• 2-input NOR gate: nor2 (use transistor widths of 8 λ for the nMOS and 16 λ for the
pMOS)
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 27
15 What to Turn In
Please provide a hard copy of each of the following items. You may wish to use the Windows
Snipping Tool or the Mac Grab program to take screenshots of your designs.
1. Please indicate how many hours you spent on this lab. This will not affect your grade, but will
be helpful for calibrating the workload for the future.
6. A printout of your or2 test vectors. Does the schematic pass simulation?
Copyright © 2025 Arm Limited (or its affiliates). All rights reserved.
Page 28