Writing Testbenches
Using SystemVerilog
Home  |  Contents  |  Reviews  |  Ask  |  Errata  |  Resources  |  Guild  |  Order
 
 
 

 

Table of Contents

 

About the Cover

Preface

CHAPTER 1: What is Verification?

    What is a Testbench?
    The Importance of Verification
    Reconvergence Model
    The Human Factor
      Automation
      Poka-Yoke
      Redundancy
    What Is Being Verified?
      Equivalence Checking
      Model Checking
      Functional Verification
    Functional Verification Approaches
      Black-Box Verification
      White-Box Verification
      Grey-Box Verification
    Testing Versus Verification
      Scan-Based Testing
      Design for Verification
    Design and Verification Reuse
      Reuse Is About Trust
      Verification for Reuse
      Verification Reuse
    The Cost of Verification
    Summary

CHAPTER 2: Verification Technologies

    Linting
      The Limitations of Linting Technology
      Linting SystemVerilog Source Code
      Code Reviews
    Simulation
      Stimulus and Response
      Event-Driven Simulation
      Cycle-Based Simulation
      Co-Simulators
    Verification Intellectual Property
    Waveform Viewers
    Code Coverage
      Statement Coverage
      Path Coverage
      Expression Coverage
      FSM Coverage
      What Does 100% Code Coverage Mean?
    Functional Coverage
      Coverage Points
      Cross Coverage
      Transition Coverage
      What Does 100% Functional Coverage Mean?
    Verification Languages Technologies
    Assertions
      Simulated Assertions
      Formal Assertion Proving
    Revision Control
      The Software Engineering Experience
      Configuration Management
      Working with Releases
    Issue Tracking
      What Is an Issue?
      The Grapevine System
      The Post-It System
      The Procedural System
      Computerized System
    Metrics
      Code-Related Metrics
      Quality-Related Metrics
      Interpreting Metrics
    Summary

CHAPTER 3: The Verification Plan

    The Role of the Verification Plan
      Specifying the Verification
      Defining First-Time Success
    Levels of Verification
      Unit-Level Verification
      Block and Core Verification
      ASIC and FPGA Verification
      System-Level Verification
      Board-Level Verification
    Verification Strategies
      Verifying the Response
    From Specification to Features
      Block-Level Features
      System-Level Features
      Error Types to Look For
      Prioritize
      Design for Verification
    Directed Testbenches Approach
      Group into Testcases
      From Testcases to Testbenches
      Verifying Testbenches
      Measuring Progress
    Coverage-Driven Random-Based Approach
      Measuring Progress
      From Features to Functional Coverage
      From Features to Testbench
      From Features to Generators
      Directed Testcases
    Summary

CHAPTER 4: High-Level Modeling

    Behavioral versus RTL Thinking
      Contrasting the Approaches
    You Gotta Have Style!
      A Question of Discipline
      Optimize the Right Thing
      Good Comments Improve Maintainability
    Structure of Behavioral Code
      Encapsulation Hides Implementation Details
      Encapsulating Useful Subprograms
      Encapsulating Bus-Functional Models
    Data Abstraction
      2-state data Types
      Struct, Class
      Union
      Arrays
      Queues
      Associative Arrays
      Files
      From High-Level to Physical-Level
    Object-Oriented Programming
      Classes
      Inheritance
      Polymorphism
    The Parallel Simulation Engine
      Connectivity, Time and Concurrency
      The Problems with Concurrency
      Emulating Parallelism on a Sequential Processor
      The Simulation Cycle
      The Co-Simulation Cycle
      Parallel vs. Sequential
      Fork/Join Statement
      The Difference Between Driving and Assigning
    Race Conditions
      Read/Write Race Conditions
      Write/Write Race Conditions
      Initialization Races
      Guidelines for Avoiding Race Conditions
      Semaphores
    Portability Issues
      Events from Overwritten Scheduled Values
      Disabled Scheduled Values
      Output Arguments on Disabled Tasks
      Non-Re-Entrant Tasks
      Static vs. Automatic variables
    Summary

CHAPTER 5: Stimulus and Response

    Reference Signals
      Time Resolution Issues
      Aligning Signals in Delta-Time
      Clock Multipliers
      Asynchronous Reference Signals
      Random Generation of Reference Signal Parameters
      Applying Reset
    Simple Stimulus
      Applying Synchronous Data Values
      Abstracting Waveform Generation
    Simple Output
      Visual Inspection of Response
      Producing Simulation Results
      Minimizing Sampling
      Visual Inspection of Waveforms
      Self-Checking Testbenches
      Input and Output Vectors
      Golden Vectors
      Self-Checking Operations
    Complex Stimulus
      Feedback Between Stimulus and Design
      Recovering from Deadlocks
      Asynchronous Interfaces
    Bus-Functional Models
      CPU Transactions
      From Bus-Functional Tasks to Bus-Functional Model
      Physical Interfaces
      Configurable Bus-Functional Models
    Response Monitors
      Autonomous Monitors
      Slave Generators
      Multiple Possible Transactions
    Transaction-Level Interface
      Procedural Interface vs. Dataflow Interface
      What is a Transaction?
      Blocking Transactions
      Nonblocking Transactions
      Split Transactions
      Exceptions
    Summary

CHAPTER 6: Architecting Testbenches

    Verification Harness
    Design Configuration
      Abstracting Design Configuration
      Configuring the Design
      Random Design Configuration
    Self-Checking Testbenches
      Hard Coded Response
      Data Tagging
      Reference Models
      Transfer Function
      Scoreboarding
      Integration with the Transaction Layer
    Directed Stimulus
    Random Stimulus
      Atomic Generation
      Adding Constraints
      Constraining Sequences
      Defining Random Scenarios
      Defining Procedural Scenarios
    System-Level Verification Harnesses
      Layered Bus-Functional Models
    Summary

CHAPTER 7: Simulation Management

    Transaction-Level Models
      Transaction-Level versus Synthesizable Models
      Example of Transaction-Level Modeling
      Characteristics of a Transaction-Level Model
      Modeling Reset
      Writing Good Transaction-Level Models
      Transaction-Level Models Are Faster
      The Cost of Transaction-Level Models
      The Benefits of Transaction-Level Models
      Demonstrating Equivalence
    Pass or Fail?
    Managing Simulations
      Configuration Management
      Avoiding Recompilation or SDF Re-Annotation
      Output File Management
      Seed Management
    Regression
      Running Regressions
      Regression Management
    Summary

APPENDIX A: Coding Guidelines

    File Structure
      Filenames
    Style Guidelines
      Comments
      Layout
      Structure
      Debugging
    Naming Guidelines
      Capitalization
      Identifiers
      Constants
    Portability Guidelines

APPENDIX B: Glossary

Index