04 Verify
04 Verify
1
Outline
l Verification Overview
l Verification Strategies
l Tools for Verification
l SoC Verification Flow
2
What is Verification ?
Specification Netlist
Verification
Source : “Writing Test Benches – Functional Verification of HDL Models” by Janick Bergeron, KAP, 2000. 3
Verification Problems
HW Design Manufacturing
Source : “Writing Test Benches – Functional Verification of HDL Models” by Janick Bergeron, KAP, 2000. 5
SoC Design Verification
6
An Industrial Example
Emulation Software
Verification Bottleneck !!
Design
BEH Model High Level Design
Timing
Analysis RTL and Block Test
DFT Synthesis
Source : “Functional Verification on Large ASICs” by Adrian Evans, etc., 35th DAC, June 1998. 7
Verification Complexity
9
Typical Verification Experience
Functional
B
u testing Purgatory Tapeout
g
s
p
e
r
w
e
e
k
Weeks
10
Error-Free Design ?
11
Reference Book
l System-on-a-Chip Verification
Methodology and Techniques
l by
Prakash Rashinkar
Peter Paterson
Leena Singh
Cadence Design Systems Inc., USA
l published by
Kluwer Academic Publishers, 2001
12
Outline
l Verification Overview
l Verification Strategies
l Tools for Verification
l SoC Verification Flow
13
Verification Approaches
14
Advs. of Bottom-up Approach
l Locality
l Catching bugs is easier and faster with
foundational IPs (sub-blocks)
l Design the SoC chip with these highly
confidence “bug-free” IPs
15
Verification Environment
Testbench
Design
Input Pattern Output
(Stimulus)
under (Response)
Verification
DUV
16
Terminology
l Verification environment
– Commonly referred as testbench (environment)
l Definition of a testbench
– A verification environment containing a set of
components [such as bus functional models (BFMs),
bus monitors, memory modules] and the
interconnect of such components with the design-
under-verification (DUV)
l Verification (test) suites (stimuli, patterns,
vectors)
– Test signals and the expected response under given
testbenches
17
Testbench Design
18
Types of Verification Tests (1/2)
l Random testing
– Try to create scenarios that engineers do
not anticipate
l Functional testing
– User-provided functional patterns
l Compliances testing
l Corner case testing
l Real code testing (application SW)
– Avoid misunderstanding the spec.
19
Types of Verification Tests (2/2)
l Regression testing
– Ensure that fixing a bug will not introduce
another bug(s)
– Regression test system should be automated
• Add new tests
• Check results and generate report
• Distribute simulation over multiple computer
– Time-consuming process when verification
suites become large
20
Bug Tracking
21
Bug Rate Tracking
22
Bug Rate Tracking Example
100
90
# of bugs reported
80
70
60
50
40
30
20
10
0
0 2 4 6 8 10 12
Time
23
Adversarial Testing
24
Verification Plan
25
Benefits of Verification Plan
26
Outline
l Verification Overview
l Verification Strategies
l Tools for Verification
l SoC Verification Flow
27
Tools for Verification (1/4)
l Simulation
– Event-driven:
• Timing accurate
– Cycle-based:
• Faster simulation time (5x – 100x)
– Transaction-based:
• Require bus functional model (BFM) of each
design
• Only check the transactions between components
• Have faster speed by raising the level of
abstraction
28
Event-Driven Simulation
l Timing accurate
l Good debugging environment
l Simulation speed is slower
Schedule
New
Events
N Time wheel Y
Finish
empty
29
Cycle-Based Simulation
l Code coverage
– Qualify a particular test suite when applied to a
specific design
– Verification Navigator, CoverMeter, …
l Testbench (TB) automation
– A platform (language) providing powerful constructs
for generating stimulus and checking response
– VERA, Specman Elite, …
l Analog/mixed-signal (AMS) simulation
– Build behavior model of analog circuits for system
simulation
– Verilog-A, VHDL-A, …
32
Coverage-Driven Verification
33
The Rate of Bug Detection
Functional
purgatory release
Testing
Rateof
dugsfound
withcoverage
withoutcoverage
Time
source : “Verification Methodology Manual For Code Coverage In HDL Designs” by Dempster and Stuart
34
Coverage Analysis
35
Analysis Results
38
Mixed Signal Simulation
l Available simulators:
Cadence
Antrim
Mentor
Synopsys
……
39
Tools for Verification (3/4)
l Static technologies
– Lint checking:
• A static check of the design code
• Identify simple errors in the early design cycle
– Static timing analysis:
• Check timing-related problems without input patterns
• Faster and more complete if applicable
– Formal verification:
• Check functionality only
• Theoretically promise 100% coverage but design
size is often limited due to high resource requirement
40
HDL Linter
41
Inspection
42
What is STA ?
A D Q D Q Z
FF1 FF2
CLK
Reference :Synopsys 43
Formal Verification
44
Equivalence Checking
Synthesis
RTL or Netlist
RTL or Netlist
Equivalence
Checking
l Gate-level to gate-level
– Ensure that some netlist post-processing did not change the
functionality of the circuit
l RTL to gate-level
– Verify that the netlist correctly implements the original RTL code
l RTL to RTL
– Verify that two RTL descriptions are logically identical
45
Equivalence Checking
46
Model Checking
RTL Coding
Specification RTL
Interpretation Model
Assertions Checking
48
New Approaches
49
Tools for Verification (4/4)
l Hardware modeling
– Pre-developed simulation models for other
hardware in a system
– Smart Model (Synopsys)
l Emulation
– Test the system in a hardware-liked fashion
l Rapid prototyping
– FPGA
– ASIC test chip
50
Assistant Hardware
l Rule of thumb
– 10 cycles/s for software simulator
– 1K cycles/s for hardware accelerator
– 100K cycles/s for ASIC emulator
l Hardware accelerator
– To speed up logic simulation by mapping
gate level netlist into specific hardware
– Examples: IKOS, Axis, ….
51
Emulation
l Emulation
– Verify designs using real hardware (like FPGA?)
– Better throughput in handling complex designs
– Inputs should be the gate-level netlist
– Synthesizable testbenches required
– Require expensive emulators
– Software-driven verification
• Verify HW using SW
• Verify SW using HW
– Interfaced with real HW components
– Examples: Aptix, Quicktum, Mentor’s AVS ….
52
Prototyping
l FPGA
– Performance degradation
– Limited design capacity (utilization)
– Partitioning and routing problems
l Emulation system
– FPGA + Logic modeler
– Automatic partitioning and routing under
EDA SW control
– More expensive
53
Limited Production
54
Comparing Verification Options
Source : “System-on-a-chip Verification – Methodology and Techniques” by P. Rashinkar, etc., KAP, 2001.
55
Outline
l Verification Overview
l Verification Strategies
l Tools for Verification
l SoC Verification Flow
56
SOC Verification Methodology
Source : “System-on-a-chip Verification – Methodology and Techniques” by P. Rashinkar, etc., KAP, 2001. 57
System Verification Steps
58
Interesting Observations
l Inter-block interfaces
– Point-to-point
– On-chip bus (OCB)
– Simplified models are used
• BFM, bus monitors, bus checkers
60
Check System Functionality (1/2)
61
Check System Functionality (2/2)
l Solutions
– Move to a higher level of abstraction for
system functional verification
– Formal verification
– Use assistant hardware:
• Hardware accelerator
• ASIC emulator
• Rapid-prototyping(FPGA)
• Logic modeler
• …
62
HW/SW Co-Simulation
l Couple a software execution environment with
a hardware simulator
l Simulate the system at higher levels
– Software normally executed on an Instruction Set
Simulator (ISS)
– A Bus Interface Model (BIM) converts software
operations into detailed pin operations
l Allows two engineering groups to talk together
l Allows earlier integration
l Provide a significant performance improvement
for system verification
– Have gained more and more popularity
63
System-Level Testbench
Source : “System-on-a-chip Verification – Methodology and Techniques” by P. Rashinkar, etc., KAP, 2001. 64
Timing Verification
65
Design Sign-off
Source : “System-on-a-chip Verification – Methodology and Techniques” by P. Rashinkar, etc., KAP, 2001. 66
Traditional Sign-off
l Traditional sign-off simulation
– Gate level simulation with precise timing under a
given parallel verification vectors
– Verify functionality and timing at the same time
(dynamic timing analysis, DTA)
– Parallel verification vectors also serve as the
manufacturing test patterns
l Problems
– Infeasible for million gates design (take too much
simulation time)
– Fault coverage is low (60% typically)
– Critical timing paths may not be exercised
67
SoC Sign-off Scheme
68