Transcript

Parallel VLSI CAD Algorithms

Lecture 1 IntroductionZhuo Feng

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.11

■ Prof. Zhuo Feng► Office: EERC 513► Phone: 487-3116 ► Email: [email protected]

■ Class Website ■ Class Website ► http://www.ece.mtu.edu/~zhuofeng/EE5900Spring2012.html► Check the class website for lecture materials, assignments

and announcementsand announcements

Schedule■ Schedule► TR 9:35am-10:50am EERC 218► Office hours: TR 4:30pm – 5:30pm or by appointments

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.22

Textbook► Pillage, Rohrer and Visweswariah, Electronic circuit and

system simulation methods, McGraw-Hill, 1995.

References► [1] Various IEEE journal and conference papers: IEEE► [1] Various IEEE journal and conference papers: IEEE

Trans. on CAD, IEEE/ACM Design Automation Conference, IEEE/ACM Intl. Conf. on CAD, IEEE Trans. on Circuits and Systems.Systems.

► [2] Farid Najm, Circuit simulation, Wiley-IEEE Press, 2010.► [3] Kundert, White and Sangiovanni-Vincentelli, “Steady-

state methods for simulating analog and microwavestate methods for simulating analog and microwave circuits,” Kluwer, 1990.

► [4] Celik, Pileggi and Odabasioglu, “IC interconnect analysis” Kluwer 2002

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.33

analysis , Kluwer 2002.

Topics (tentative)■ Introduction■ Brief review of matrix theory, linear algebra and

numerical methods numerical methods ■ Basic circuit analysis methods (Part 1, Part 2) ■ IC interconnect modeling methodsg■ Model order reduction techniques (AWE, PRIMA)■ RF circuit simulation methods■ Introduction to emerging heterogeneous parallel

computing platforms ■ Parallel GPU based simulation methods for power ■ Parallel GPU-based simulation methods for power

delivery networks. ■ Full-chip thermal analysis on GPUs

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.44

p y■ Parallel 3D capacitance extraction on GPU

■ Project► This is a project/research oriented course. ► Research explorations are strongly encouraged.► Students are expected to read research papers assigned► Students are expected to read research papers assigned

before lectures and actively participate in class discussions.

G di■ Grading► Assignment (course projects): 70%► Exams: 30%

■ No plagiarism !

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.55

■ A plethora of VLSI CAD problems

Devices, interconnects, circuits, systems, i l l di it l

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.66

signal, power, analog, digital …..

■ Where are we in the design flow?Specifications

System-level DesignSystem level Design

RTL-level Design

Gate-level DesignTop-down Design

Bottom-up Verification

Transistor/Circuit Level

Electrical & Th l P ti

Final Verification

LayoutThermal Properties,Delays, Waveforms,Parasitics Effects, Coupling Noise …

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.77

Final VerificationCoupling Noise …

■ Why circuit analysis?y y

►Performance verification

▼A critical step for evaluating expected performanceprior to manufacturing

▼Simulation is always cheaper and more efficient than actually making the chip

▼True more than ever for today’s high manufacturing costs

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.88

■ Why circuit simulation (cont’d) ?

► Design optimization/synthesis

▼Need to evaluate circuit performances many times in an optimization loop before meeting all the specs

▼Can only be practically achieved via simulation (models)

Circuit Optimizer Meet all specs? ConvergenceCircuit Optimizer

Update design parameters

Meet all specs?

YesNo

Convergence

SimulationEngine

PerformanceEvaluation

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.99

■ Why models?► Models are integral parts of system simulation and/or optimization

Abstract Executable Models

Abstract Executable Models

High

Cycle AccurateModels

Cycle AccurateModels Speed

Low

VHDL/Verilog Models

VHDL/Verilog Models

InterconnectGate ModelsInterconnectGate Models

Cost

LowGate ModelsGate Models

Device ModelsDevice ModelsHigh

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.1010

High

■ Assessment of simulators

Accuracy

Robustness/

Accuracy

Robustness/Applicability

RuntimeMemory

RuntimeMemory

Accuracy

Runtime

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.1111

RuntimeMemory

■ Selected Topicsp

►Classical circuit simulation methods (SPICE)▼LU factorization, Newton’s method▼LU factorization, Newton s method

▼(Modified) nodal formulation (MNA)

▼Nonlinear DC analysisy

▼AC analysis

▼Linear/nonlinear transient analyses

▼SPICE device models

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.1212

■ Many problems are modeled by some form of coupled (nonlinear) first order differential equations(nonlinear) first-order differential equations

F i it bl thi i ll d i MNA ■ For circuit problems this is usually done using MNA formulation

f(v)i 1v2v 4vR

3v

Cv 3v

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.1313

■ Write KCL (Kirchoff’s Current Law) at node 1:

0)()()(12

4131 vvfR

vvdt

vvdC

■ If we do this for all N nodes:

0))(),(),(( tutxtxF Xx

)0(

N dimensional vector of unknownnode voltages

)(tx

vector of independent sources

nonlinear operator

)(tu

F

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.1414

nonlinear operatorF

How can we solve this set of nonlinear differential equations?

0))(),(),(( tutxtxF Xx

)0(

■ Closed-form formula/hand analysis easily b i f iblbecomes infeasible

■ Need to develop computer programs (circuit i l t ) t l f th l ti i llsimulators) to solve for the solution numerically

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.1515

■ Selected Topics► Elmore delay► Timing simulation► Intend to evaluate the circuit timing quickly

▼ Crucial for large VLSI circuit synthesis/optimization▼ Provide delay estimation or waveform approximation ▼ o de de ay est at o o a e o app o at o

using easy-to-compute metrics or (approximated) timing simulation

R4R4

C4R1 R2 R3

44)432(2432114

CRCCCRCCCCRTD

C1 C2 C3

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.1616

44)432(2 CRCCCR

■ Selected Topics

► Model order reduction

► Key drivers for achieving feasible simulation y g▼ IC interconnect analysis ▼Whole system verification▼Design space explorationg p p

MacromodelingFullSystem Model

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.1717

■ Selected topics►Parallel CAD

Courtesy Intel Courtesy AMD Courtesy TI

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.1818

GPU Computing for CADGPU Computing for CAD■ Dedicated for graphics rendering

CPUVideo Out CPU(host)

GPU is connected to MCHvia 16x PCI-Expressvia 16x PCI-Express

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.1919

■ Reading assignments► T tb k Ch t 1 d 2► Textbook. Chapters 1 and 2

■ History of SPICEy► CANCER at UCB: Computer Analysis of Nonlinear Circuits

Excluding Radiation

► Government project SCEPTRE: System for Circuit Evaluation and Prediction of Transient Radiation Effects

► CANCER evolved to SPICE: Simulation Program with Integrated Circuit Emphasis

► SPICE became the industry standard

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.2020

■ SPICE overview►N equations in terms of N unknown Node voltages►More generally using modified nodal analysis

G(v)i vv vR

G(v)i 1v2v 4vC

R

v

3v

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.2121

Time Domain Equations at node 1:Time Domain Equations at node 1:

0)()()(12

4131 vvGR

vvdt

vvdC

If we do this for all N nodes:

0))(),(),(( tutxtxF Xx

)0(

N dimensional vector of unknownnode voltages

)(tx

vector of independent sources

nonlinear operator

)(tu

F

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.2222

nonlinear operatorF

■ Closed form solution is not possible for bit d f diff ti l tiarbitrary order of differential equations

■ We must approximate the solution of:

0))(),(),(( tutxtxF Xx

)0(

■ This is facilitated in SPICE via numerical solutions

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.2323

■ Basic circuit analyses►(Nonlinear) DC analysis

▼Finds the DC operating point of the circuit▼Solves a set of nonlinear algebraic eqnsg q

►AC analysis▼Performs frequency domain small signal analysis▼Performs frequency-domain small-signal analysis▼Require a preceding DC analysis▼Solves a set of complex linear eqns

►(Nonlinear) transient analysis▼Computes the time-domain circuit transient response▼Solves a set of nonlinear different eqns▼Converts to a set nonlinear algebraic of eqns using

numerical integration

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.2424

■ SPICE offers practical techniques to solve circuit problems in time & freq domainsproblems in time & freq. domains

► Interface to device models▼Transistors diodes nonlinear caps etc▼Transistors, diodes, nonlinear caps etc

► Sparse linear solver

► Nonlinear solver – Newton-Raphson method

► N merical integration► Numerical integration

► Convergence & time-step control

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.2525

■ Circuit equations are usually formulated iusing

►Nodal analysis y▼N equations in N nodal voltages

►Modified analysis►Modified analysis▼Circuit unknowns are nodal voltages & some branch

currents▼Branch current variables are added to handle▼Branch current variables are added to handle

– Voltages sources– Inductors– Current controlled voltage source etcCurrent controlled voltage source etc

■ Formulations can be done in both time d f

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.2626

and frequency

How do we set up a matrix problem given a list ofHow do we set up a matrix problem given a list oflinear(ized) circuit elements?

Similar to reading a netlist for a linear circuit:

* Element Name From To Value

I 0 1 1mA

2

1

1

RRI

110

201

5101mA

3

2

RR

21

02

1005

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.2727

R 52R

R

51 2

1I 1R 3RmA1 10010

0

The nodal analysis matrix equations areeasily constructed via KCL at each node:easily constructed via KCL at each node:

JvY

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.2828

■ Naïve approach) C f► a) Write down the KCL eqn for each node

► b) Combine all of them to a get N eqns in N node voltages

■ Intuitive for hand analysis

■ Computer programs use a more convenient “element”p p gcentric approach► Element stamps

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.2929

Instead of converting the netlist into a graph and g g pwriting KCL eqns, stamp in elements one at a time:

Stamps: add to existing matrix entries

RR11 From

row ii

Y

RR11 To

row j jRY

Fromcol.

Tocol. i j

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.3030

RHS of equations are stamped in a similar way:J

i

II

i

jI

From row

To

ij I j

row j

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.3131

Stamping our simple example one l t t tielement at a time:

1001110

1

1

RmAI

10002521

3

2

1

RR

IVGGG

01

2

1

322

221 IVV

GGGGGG

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.3232

We know that nonlinear elements are firstconverted to linear components, then stamped

EQI EQGQ Q

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.3333

For 3 & 4 terminal elements we know that the linearized models have linear controlled sources

D DG

Gdsvgsv

gsmvg dsr

S S

We can stamp in MOSFETs in terms of a completestamp or in terms of simpler element stamps

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.3434

stamp, or in terms of simpler element stamps

Voltage controlled current source

kv 0I

kkvgi

p

kv 0I

kmvgi

q

Voltmeter

gg prow

mm

mm

gggg p

qrow

row

k colcol

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.3535

Large value that does not fall on diagonal of Y!

All other types of controlled sources include All other types of controlled sources includevoltage sources

Voltage sources are inherently incompatiblewith nodal analysis

Grounded voltages sources are easily accommodated Grounded voltages sources are easily accommodated

21 v1

v2

21

2

1

vv

0

v2

2v

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.3636

0

But a voltage source in between nodes is gmore difficult

k k

Node voltages and are not independentk

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.3737

We no longer have N independent node voltageg p gvariables

So we can potentially eliminate one equation p y qand one variable

But the more popular solution is modified nodal ut the more popular solution is modified nodalanalysis (MNA)

Vk

iCreate one extra variable and one extra equation

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.3838

Extra variable: voltage source current

Allows us to write KCL at nodes andk

Extra equation

Vvvk

Advantage: now have an easy way of printing

Vvvk

Advantage: now have an easy way of printingcurrent results - - ammeter

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.3939

Voltage source stamp:

11

row

row k

Vi011

1row

row 1N

col colcolk 1N

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.4040

Current-controlled current source (e g BJT) has to Current-controlled current source (e.g. BJT) has to stamp in an ammeter and a controlled current source

ii i 12 ii 1i

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.4141

In general we would not blindly build the matrixIn general, we would not blindly build the matrixfrom an input netlist and then attempt to solve it

Various illegal ckts are possible:

Cutsets of current sources

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.4242

Loops of voltage sourcesLoops of voltage sources

Dangling nodes

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.4343

■ Once we efficiently formulate MNA equations, an efficient solution to is even more importantJY

solution to is even more importantJvY

■ For large ckts the matrix is really sparse► Number of entries in Y is a function of number of elements

connected to the corresponding node

■ Inverting a sparse matrix is never a good idea since the inverse is not sparse!

■ Instead direct solution methods employ Gaussian Elimination or LU factorization

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.4444

■ Reading assignment: ► Textbook sections 3 1-3 4 7 1-7 5► Textbook, sections 3.1-3.4, 7.1-7.5

■ We need to solve a linear matrix problem for the simple DC circuitsimple DC circuit

■ Linear system solutions are also basic routines for ■ Linear system solutions are also basic routines for many other analyses► Transient analysis, nonlinear iterations etc

■ Sounds quite easy but can become nontrivial for large analysis problems

O( 3) l d t i► O(n3) – general dense matrices► O(n1.1~ n1.5) -- sparse circuit problems► O(n1.5) – 2D mesh O(n2) – 3D mesh

Z. Feng MTU EE5900 Spring 2012Z. Feng MTU EE5900 Spring 20121.1.4545