2065-17 Advanced Training Course on FPGA Design and VHDL...

44
2065-17 Advanced Training Course on FPGA Design and VHDL for Hardware Simulation and Synthesis Nizar Abdallah 26 October - 20 November, 2009 ACTEL Corp.2061 Stierlin Court Mountain View CA 94043-4655 U.S.A. VHDL & FPGA Architectures Programmable Logic and VHDL Architectures

Transcript of 2065-17 Advanced Training Course on FPGA Design and VHDL...

Page 1: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

2065-17

Advanced Training Course on FPGA Design and VHDL for HardwareSimulation and Synthesis

Nizar Abdallah

26 October - 20 November, 2009

ACTEL Corp.2061 Stierlin Court Mountain ViewCA 94043-4655

U.S.A.

VHDL & FPGA ArchitecturesProgrammable Logic and VHDL Architectures

Page 2: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

Lectures:VHDL & FPGA Architectures

Page 3: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

2© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

OutlineIntroduction to FPGA & FPGA design flow

Synthesis I – Introduction

Synthesis II - Introduction to VHDL

Synthesis III - Advanced VHDL

Design verification and timing concepts

Programmable logic & FPGA architectures

Actel ProASIC3 FPGA architecture

System-on-Chip concepts

Page 4: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

Programmable Logic and FPGA Architectures

Page 5: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

4© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

It’s All About the Original Idea

Page 6: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

5© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

PLD Market Growth

Page 7: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

6© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

New adopters are in high volume segments

Consumer grows from 8% to 15%Automotive grows from 1% to 6%

Traditional ASIC-crossover segments also growing well

Industrial is up 9%Mil/Aero is up 2%

While high-end FPGA markets decline in share

Comm down 15% in shareData proc down 8% in share

PLD Market Growth

Page 8: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

7© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

Cost: The exploding ASIC NREWafers today are worth from US $10 million to $100 million

Amortize the $5 billion investment in a fabover a 5 year schedule costs > $3 million/day

Equipment running all the time

Must produce a semiconductor product in volumes of at least 5000 to 10 000 wafers per month

Page 9: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

8© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

Cost: The exploding ASIC NRE

Page 10: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

9© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

Technology Advances vs. Crossover Volume

Page 11: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

10© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

Industry Dynamics & Time-to-Market

New products are taking less time to go into volume. At the same time, new products also stay in volume for shorter

Page 12: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

11© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

Time-to-Market Dimension…

Missing a market window, because of a long development/debugging cycle can have a profoundly negative effect on the profitability of a product over its life..

Late market entry has a larger effect on profits than development cost overruns or a product price that is high.

Page 13: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

12© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

Cost: System Re-configurability

Lack of re-configurability in ASICs is a huge opportunity

FPGAs offer flexible life cycle management

Page 14: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

13© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

Volume Requirement for ASICs

> 50% of the market available today for FPGAs

Page 15: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

14© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

FPGA can address a very large part of the market today

Gate Count Requirement for ASICs

Page 16: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

15© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

FPGA can address a very large part of the market today

Performance Requirement for ASICs

Page 17: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

16© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

FPGA can address a very large part of the market today

Performance Requirement for FPGAs

~75% ~25%

Page 18: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

17© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

7 years ago, FPGAs were only gates & routing ∼25000 gates

Today, there are several system-level features. ∼5,000,000 gates

The trend to add more IP in FPGAs continues

IP in FPGAs

Page 19: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

18© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

A Brief History…

Once upon the time, there were… ROMs:

ExpensiveNeed for creating an application specific mask set by the vendor

Long development cycleChanges = New mask set by the vendor

Page 20: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

19© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

A Brief History…

PROMs: Programmable Read Only MemoriesFirst field programmable devices

Slow access timeNot useful for applications where speed is an issue

Limited number of inputs

Require different technologyExtra masks

Extra processing stepsExtra development timeExtra cost

PROM

A0A1A2A3

S

Page 21: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

20© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

A Brief History…

PLAs: Programmable Logic ArraysClassified as a simple programmable logic device (SPLD)

The first programmable logic device introduced in the early 1970s by Philips.

Based on the idea that logic functions can be realized in sum-of-products form.

A programmable AND array followed by a programmable OR array.

HDLs to convert Boolean equations into connectionsABELPALASM

Page 22: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

21© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

A Brief History…

PLAs: Programmable Logic Arrays

PLA Architecture

InputsAND Plane

OutputsOR

Plane

Page 23: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

22© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

A Brief History…

PALs: Programmable Array LogicA device similar to PLA.

Introduced to overcome the weaknesses of PLAs at that time (programmable switches were hard to fabricate correctly and introduced significant propagation delays).

A programmable AND array followed by a fixed OR array.Inverters at the inputs and outputs.

HDLs to convert Boolean equations into connections

ABELPALASM

Page 24: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

23© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

A Brief History…

PALs: Programmable Array Logic

PAL Architecture

InputsAND Plane

OutputsLimited

ORPlane

Page 25: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

24© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

A Brief History…

First idea of an FPGA/CPLD different from a PLD:

1984: Ross Freeman / Zilog, Inc.Xilinx, Inc. with $4.25M in venture capital

1983: Altera Corp.

1985: Actel Corp. with FPGAs based on antifuseswitching elements

Page 26: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

25© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

I/O

FB

Interconnect Matrix

FB

FB

Complex Programmable Logic Devices (CPLDs)

I/O

FB

FB

FB

FB

FB

CPLD Architecture (Altera)

Large number of PALs in a single chip

Page 27: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

26© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

Complex Programmable Logic Devices (CPLDs)

Function BlockTypically similar to a PAL architecture

Same technology and programming tools than a PAL

Additional specialized logic in each FB:XOR (difficult in a PAL), Muxes, FFs…

Additional embedded devices in the CPLD:SRAM and Flash memoriesMicrocontrollers and microprocessorsDigital Signal Processors (DSPs)Phased Locked Loops (PLLs)Network processors

Page 28: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

27© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

Complex Programmable Logic Devices (CPLDs)

Selection criteriaThe programming technology

Equipment for device programming

The FB capability#FFs, #inputs, built-in XORs …

The number of FB in the device

The kind of FF control available

Embedded devices

The number and type of IO pins

The number of clock input pins

Page 29: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

28© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

What is an FPGA?Field

Programmable

Gate

ArrayA large number of logic gates in an IC array that can be

connected (configured) electrically

The Four Components of FPGAsThe Configuration ElementThe Logic ModuleThe MemoryControl Circuits/Special Features

Page 30: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

29© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

The Key Element of an FPGAThe Interconnect Switch

XXX

Page 31: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

30© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

Word Select / Bias

Output

InputBit Select 1 Bit Select 2

SWITCH

Floating Gate

Flash

MEMORY•Erase•Program•Sense

VCC

A B

Word line

BitLineSRAM

BitLine

VCC

M2M Antifuse

FPGA Industry Interconnect (Switch) Technologies

Page 32: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

31© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

FPGA Technologies Compared

SRAM

6T

Flash

1T

Anti-fuse

ReprogrammableBest of Both Worlds

Reprogrammable& Nonvolatile

Nonvolatile

Large Switchexpensive wires

Low Logic Utilizationtyp 60%

Small Switchcheap wires

High Logic Utilizationtyp >85%

Smallest Switchcheapest wires

Highest Logic Utilizationtyp >90%

Page 33: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

32© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

Flash Switch

ProASIC, ProASICPlus, ProASIC III Routing Switch

Page 34: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

33© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

Types of FPGAs (Switch)

Volatile (loses its configuration when power is turned off)Reprogrammable: SRAM process and device technology

Xilinx, Altera, Lattice

Non-Volatile (keeps its configuration)One Time Programmable (OTP): Anti-fuse

Actel, QuicklogicReprogrammable: Flash

Actel

Page 35: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

34© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

Field Programmable Gate Arrays (FPGAs)

Regular array of logic

Control Store 110101011101010010001

L

Page 36: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

35© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

Field Programmable Gate Arrays (FPGAs)

Configurable logic blocks

Y

D0

D3D2

D1

DB

A0 B0 A1 B1

Sa Sb

CLKA,CLKB

DC IN

HCLK

S0DIN S1 PSETB

D Q

CLRBCKPCKS

Y

Page 37: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

36© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

Field Programmable Gate Arrays (FPGAs)

Selection criteriaProgramming technology

Configurable logic block#FFs, #inputs, …

The number of logic blocks in the device

Embedded devices

The number and type of IO pins

The number of clock input pins

Page 38: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

37© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

CPLD or FPGA?

Low per gateHigh per gate

Power consumption

RoutingCrossbarInterconnect

Medium to high

Low to mediumDensity

Application dependent

Fast, predictableSpeed

Gate array likePAL-likeArchitecture

FPGACPLD

Page 39: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

38© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

ASIC Design Methodology

Logic Design

Logic Simulation

Place & Route

Timing Simulation

Test Pattern Generation

Fault Simulation

Wafer Fabrication

Testing

Prototype Debug

Production

Specifications

Page 40: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

39© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

CPLD/FPGA Design Methodology

Choose Chip & Tools

Place & Route

Timing AnalysisPower AnalysisTiming Simulation

Configure Prototype Debug

Production

Specifications

Design Entry

Synthesize

Logic SimulationFormal Proof

I D E A

Page 41: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

40© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

CPLD/FPGA Design Methodology

SpecificationsExternal block diagram (chip in the system)

Internal block diagram

Description of the IO pins

Timing & power constraintsClock frequency, external setup, external hold, …

Gate count estimate

Package type

Price target

Test procedure

Page 42: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

41© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

CPLD/FPGA Design Methodology

Choosing Device and ToolsSynthesis

Coding style for the HDL

Page 43: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

42© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

CPLD/FPGA Design Methodology

DesignPartitioning Implementation Assemblage

Top-down flow

Work with the device architecture

Do synchronous design

Protect against metastability

Avoid floating nodes

VERIFY AT EACH STEP

Page 44: 2065-17 Advanced Training Course on FPGA Design and VHDL ...indico.ictp.it/event/a08187/session/5/contribution/3/material/0/4.pdf · Advanced Training Course on FPGA Design and VHDL

43© 2005 Nizar AbdallahVHDL & FPGA Architectures November, 2005

CPLD/FPGA Design Methodology

VerificationSimulation

Design review

Timing analysis

Power analysis

Formal verification