Académique Documents
Professionnel Documents
Culture Documents
User Guide
L-2016.06-SP1, September 2016
Copyright Notice and Proprietary Information
2016 Synopsys, Inc. All rights reserved. This Synopsys software and all associated documentation are proprietary to Synopsys,
Inc. and may only be used pursuant to the terms and conditions of a written license agreement with Synopsys, Inc. All other use,
reproduction, modification, or distribution of the Synopsys software or the associated documentation is strictly prohibited.
Synopsys, Inc.
690 E. Middlefield Road
Mountain View, CA 94043
www.synopsys.com
ii
Contents
Prologue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
New Integration Features in This Release . . . . . . . . . . . . . . . . . . 15
Other Integration Features in This Release . . . . . . . . . . . . . . . . . 15
SoC-IP Design . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
iii
The analyze_waiver_correctness Command . . . . . . . . . . . 69
Supported Violation Tags . . . . . . . . . . . . . . . . . . . . . . . . . . 72
Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 73
Unified Verdi Debug Platform for Formal Verification . . . . . . . . . . 74
Support for VHDL in VC Formal. . . . . . . . . . . . . . . . . . . . . . . . 75
Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75
Enabling Formal Verification Mode in GUI. . . . . . . . . . . . . . . . 76
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 80
Backward Compatibility . . . . . . . . . . . . . . . . . . . . . . . . . . . 82
Replay of Verdi-VC Static Commands. . . . . . . . . . . . . . . . . . . 83
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 83
Renaming and Reorganizing Reported Run-Status Fields . . . 84
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 85
Support for Explore Property . . . . . . . . . . . . . . . . . . . . . . . . . . 97
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98
Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 115
Verification Tasks Management in GUI . . . . . . . . . . . . . . . . . . 116
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 118
Limitations of Verification Tasks. . . . . . . . . . . . . . . . . . . . . 123
Enhancements to VC-Static Grid Functionality . . . . . . . . . . . . 124
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 125
Managing Progress Reports in GUI . . . . . . . . . . . . . . . . . . . . . 129
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 131
Bounded Coverage Analysis . . . . . . . . . . . . . . . . . . . . . . . . . . 140
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 140
SEQ Debug Flow in GUI . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 149
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 150
iv
SoC-IP Verification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 161
2. Verification Planning
Native LP Planner Support . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 164
Viewing LP Elements in the HVP Hierarchy Page . . . . . . . . . . 166
Limitation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 167
Cell and Image Selection for Specification Linking . . . . . . . . . . . . 168
Cell-Based Selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 169
Table Cell Selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 172
Image Selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 172
Examples for Image Selection . . . . . . . . . . . . . . . . . . . . . . 175
Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 177
Integrated Planning for VC VIP Coverage Analysis . . . . . . . . . . . 180
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 181
3. Testbench Creation
Unified UVM Library . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 186
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 187
Transaction/Message Recording in DVE/Verdi With VCS . 188
v
Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 207
Loading Design Automatically in Verdi with Native Certitude . . . . 209
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 209
Key Points to Note . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 210
Dumping and Comparing Waveforms in Verdi for SystemC Designs 211
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 211
Key Points to Note . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 213
5. Verification Execution
Compile Turnaround Time. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 215
Unified Compile Front End. . . . . . . . . . . . . . . . . . . . . . . . . . . . 216
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 216
Generating Verdi KDB With Unified Compile . . . . . . . . . . . 217
Support for VHDL LRM Features . . . . . . . . . . . . . . . . . . . . 221
Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 225
Native VIP Solutions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 226
Optimized VC VIP Compilation Performance With Partition
Compile and Precompiled IP . . . . . . . . . . . . . . . . . . . . 226
6. Verification Debug
VC Formal Coverage With Verdi Coverage . . . . . . . . . . . . . . . . . 235
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 235
Collecting VC Formal Results in the Coverage Database . 235
Measuring VC Formal Assert Status in HVP . . . . . . . . . . . 239
Generating VCS Coverage Database From Design and FSDB . . 244
Data Input and Output Requirements . . . . . . . . . . . . . . . . . . . 246
vi
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 247
Prepare an Initial VDB for covsim . . . . . . . . . . . . . . . . . . . 247
Prepare FSDB for covsim in the Extraction Phase. . . . . . . 248
Calculate the Coverage Data From FSDB by covsim in the
Simulation Phase . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 250
The covsim Commands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 252
Power Model L1/Utility/Applications . . . . . . . . . . . . . . . . . . . . . . . 253
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 253
Value Traverse-Based Netlist . . . . . . . . . . . . . . . . . . . . . . . . . . . . 257
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 258
Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 273
Enhancing NPI Applications in the Verification Compiler Platform
Application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 275
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 275
Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 282
Unified Verdi Debug Platform for Interactive and Post-Simulation Debug
283
Interactive Simulation Debug Mode . . . . . . . . . . . . . . . . . . . . . 284
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 285
Rebuilding and Restarting Interactive Simulation Debug in Verdi
286
Post-Simulation Debug Mode . . . . . . . . . . . . . . . . . . . . . . . . . 287
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 287
Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 288
Saving/Loading Verdi Elaboration DB Library to/from Disk . . . . . . 289
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 290
Interactive Simulation Debug Flow. . . . . . . . . . . . . . . . . . . 290
vii
Post-Simulation Debug Flow . . . . . . . . . . . . . . . . . . . . . . . 291
Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 295
Attaching a Running Simulation in Verdi . . . . . . . . . . . . . . . . . . . . 296
Prerequisites . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 297
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 298
Detaching Verdi From Simulation Process. . . . . . . . . . . . . 304
Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 305
Reverse Interactive Debug . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 306
Prerequisite . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 308
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 309
Before Invoking Verdi Interactive Simulation Debug Mode 309
Enable the Verdi Reverse Interactive Simulation Debug Mode
309
Using Reverse Simulation Control Commands . . . . . . . . . . . . 311
Run/Continue Reverse Simulation Control Command . . . . 313
Step and Next Reverse Simulation Control Commands . . 314
New UCLI Commands . . . . . . . . . . . . . . . . . . . . . . . . . . . . 315
Going to Previous/Next Value Assignment . . . . . . . . . . . . . . . 317
Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 319
Unified UCLI Command for FSDB Dumping . . . . . . . . . . . . . . . . . 321
Default Dump Type . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 322
Default Dump File . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 322
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 323
Enhanced UCLI Options for FSDB Dumping . . . . . . . . . . . . . . 324
dump -file . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 325
dump -add . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 325
dump -close . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 328
viii
dump -deltaCycle . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 328
dump -flush. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 329
dump -switch . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 329
dump -power . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 330
dump -powerstate. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 330
New UCLI Options for FSDB Dumping . . . . . . . . . . . . . . . . . . 331
dump -suppress_file . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 331
dump -suppress_instance . . . . . . . . . . . . . . . . . . . . . . . . . 332
dump -enable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 332
dump -disable. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 333
dump -glitch . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 334
dump -opened . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 334
Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 335
AMS-Debug Integrations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 336
Unified Dumping of Analog Signals in FSDB in VCS-CustomSim
Cosimulation Flow . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 337
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 337
Use Model for FSDB Dumping . . . . . . . . . . . . . . . . . . . . . . 337
Enabling Dumping of the Analog/Digital Signals in the FSDB File
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 338
Enabling Merge Dumping. . . . . . . . . . . . . . . . . . . . . . . . . . 340
Usage Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 340
Verdi Interactive Simulation Debugging With Analog Mixed-Signal
Designs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 341
Prerequisites . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 342
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 342
Compiling Mixed-Signal Design With VCS. . . . . . . . . . . . . 342
Compiling With Verdi . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 343
ix
Compiling and Importing SPICE Design . . . . . . . . . . . . . . 343
Compiling With SPICE Unified Front-End Flow . . . . . . . . . 345
Enabling Verdi Interactive Simulation Debug Mode . . . . . . 345
Interactive Simulation Debugging With Mixed-Signal Design . 347
Variable Observation in the Watch Tab . . . . . . . . . . . . . . . 347
Annotation Value . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 349
Dumping Analog Signals Into FSDB . . . . . . . . . . . . . . . . . 349
Force/Release Node Voltage . . . . . . . . . . . . . . . . . . . . . . 350
Save/Restore the Simulation Session/State. . . . . . . . . . . . 351
Interactive Console. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 351
Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 351
Unified Transaction Debug With Native Verdi Protocol Analyzer . 353
Prerequisite . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 354
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 354
Hierarchy Tree . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 355
Quick Filter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 356
Protocols . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 356
Global Pane . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 356
Object Pane . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 357
Details . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 357
Call Stack . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 357
Search Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 358
Limitation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 358
Memory Debug With Native Verdi Protocol Analyzer . . . . . . . . . . 358
Prerequisite . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 360
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 360
Memory Array View . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 361
Detail View . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 362
x
History View . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 362
Summary View . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 362
Search Results View . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 362
Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 363
VC APPs Protocol Analyzer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 363
Prerequisite . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 365
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 365
Capturing Protocol Data During Simulation . . . . . . . . . . . . 368
Creating or Importing Protocol Extension Definition. . . . . . 369
Protocol Analyzer: Native Performance Analyzer for Transactions 370
Performance Analyzer Use Model . . . . . . . . . . . . . . . . . . . . . . 372
Hierarchy Tree Pane . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 374
Performance Report Pane . . . . . . . . . . . . . . . . . . . . . . . . . 382
Details Pane . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 388
Summary of Usage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 390
Optimized Performance of Gate-Level Designs Using Native FSDB
Gates . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 391
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 392
Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 393
xi
APIs for C Interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 404
APIs for Tcl Interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 406
VC Formal Coverage Analyzer Features . . . . . . . . . . . . . . . . . . . 409
Saving Formal Covered/Uncoverable Coverage Goal Into a Coverage
Database . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 410
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 410
Saving Coverage Database and Exclusion File When Database is Not
Imported . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 414
Use Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 415
xii
Prologue
Prologue
13
Verification Compiler Platform is a next-generation verification
solution that provides a scalable environment, where sophisticated
tools work seamlessly with each other throughout the flow to
accomplish various verification tasks using integration of
technologies. It helps in optimizing design iterations and
recompilations, shortens debug cycles, and enables steady
integration and interoperability between individual verification tools.
Prologue
14
New Integration Features in This Release
Prologue
15
- Loading Design Automatically in Verdi with Native Certitude
- Dumping and Comparing Waveforms in Verdi for SystemC
Designs
Verification Execution
- Unified Compile Front End
- Optimized VC VIP Compilation Performance With Partition
Compile and Precompiled IP
Verification Debug
- Generating VCS Coverage Database From Design and FSDB
- Power Model L1/Utility/Applications
- Value Traverse-Based Netlist
- Enhancing NPI Applications in the Verification Compiler
Platform Application
- Unified Verdi Debug Platform for Interactive and Post-
Simulation Debug
- Saving/Loading Verdi Elaboration DB Library to/from Disk
- Attaching a Running Simulation in Verdi
- Reverse Interactive Debug
- Unified UCLI Command for FSDB Dumping
- AMS-Debug Integrations
- Unified Transaction Debug With Native Verdi Protocol
Analyzer
- Memory Debug With Native Verdi Protocol Analyzer
Prologue
16
- VC APPs Protocol Analyzer
- Protocol Analyzer: Native Performance Analyzer for
Transactions
- Optimized Performance of Gate-Level Designs Using Native
FSDB Gates
Closing Coverage Gaps
- NPI Coverage Model
- VC Formal Coverage Analyzer Features
Prologue
17
SoC Design and Verification
Cosimulation
Customize IP for Application Integrate Software for the
and Integrate into SoC Platform Application including OS
Simulate Simulate
Hardware Software
Emulation
Board Development
Manufacture
System Level
System Design
Verification Software IP Library
SoC Software
SoC Hardware RTL Software Verification
Development
Functional Verification
Netlist Verification
Functional Verification
Timing Verification
Physical Verification and Testing
Design Sign-off
SoC-IP Design
21
Figure 2-1 IP Design
RTL Development
Lint Checks
(Structural)
Connectivity Checks
Integration Checks,
CDC Checks M odel Checking
LP Lint Checks
Functionality, Protocol
and Compliance Checks
SoC-IP Design
22
1
Static and Formal Verification 1
Traditionally, simulation-based dynamic verification techniques have
been the mainstay of functional verification. As modern day SoC
designs become more complex, the adoption of static verification
techniques is important.
The following features are available with unified debug platform for
static verification:
Note:
When enable_verdi_kdb is set to true and
enable_verdi_debug is set to false, KDB files are not
generated as Verdi does not need to use these files for debugging.
---------------------------------------------------------------------------
top
TimeScale is 1 ns / 1 ns
---------------------------------------------------------------------------
You can make Verdi as the default source viewer for all VC Static
applications and use the useful debug features provided by Verdi to
debug formal and static issues.
Use Model
The following sections describe the capabilities of this feature:
In this mode, you can use the -verdi option in the VC static shell to
open Verdi from VC Static.
vc_static_shell -verdi
Figure 1-1, Figure 1-2, Figure 1-3, Figure 1-4, and Figure 1-5 show
Verdi - VC Static Integrated View, Verdi Schematic View, Verdi
Source View, Verdi UPF View, and Verdi UPF Schematic View when
you use the Verdi First mode.
setenv VERDI_VCSTATIC_BETA 1
vc_static_shell -f <tcl_file>
vc_static_shell> view_activity
Figure 1-6, Figure 1-7, Figure 1-8, Figure 1-9, and Figure 1-10 show
VC Static Activity View, Verdi Schematic View, Verdi Source View,
Verdi UPF View and Verdi UPF Schematic View when you use the
VC Static First mode.
VC LP Schematic Entries
VC CDC Schematic Entries
Click View Item in Schematic for a control path pin or data path
pin to open a new Verdi-nSchema window with the instance of
the pin that it belongs to.
If you click Add to Schematic for a control path pin or data path
pin, then current active flatten window opens with the instance of
the pin that it belongs to. If there is no flatten window or the active
one is not flatten window, a new Verdi-nSchema window opens.
You can set this application variable to true, when there are any
VERDI_COMPILE errors and the design cannot be loaded into Verdi
properly.
Backward Compatibility
For VC Static native GUI, set the enable_verdi_debug
application variable to false.
nSchema provides support for the locator function. You can add a
locator from the VC Static CDC-LP menu entry to the Verdi-
nSchema window. You can also add locator in the nSchema window
for any instance or pins.
Use Model
Hiding/Displaying Locators
You can use the View->Show Locator option to display or hide
locator in the nSchema window as shown in Figure 1-22.
Viewing Hierarchy
You can use the View->Hierarchy View option from the Window
menu to switch views between the hierarchy flatten and the flatten
mode as shown in Figure 1-23.
Property Window
nSchema supports the Properties window as shown in Figure 1-28
to display library and UPF relative power information for the selected
cell or pin. The Properties window can be opened from the
Property RMB menu. Information for all the properties is obtained
from VC Static.
You can apply do not disturb functionality on the design object and
power design object from this property window to Verdi's other
components for further debugging as shown in Figure 1-29.
When you turn on this option, all combo instances are abstracted as
a cloud instance, which keeps the input/output information for the
original instance.
When you turn off this option, all instances that belong to cloud
instances are displayed and the cloud instances are removed.
Use Model
There are other violations which do not describe any power state
combinations. For example, PG_PIN_UNCONN shows a structural
problem, where a PG pin in a netlist is left floating. You cannot use
the analyze_waiver_correctness command for identifying
incorrect waivers on such violations.
4. (Optional) You may want to review the comments in the file, and
decide to edit the file to remove certain assertions if they were
created for other reasons.
5. Run RTL simulations with the assertions.
6. If any assertion triggers, use the comments in the file to determine
which waiver(s) need to be carefully reviewed.
The command looks at all the waivers and violations in the current
run, which you should set up before executing the command. The
command take a filename as its input, where the output must be
written. The command has the -verbose option which causes a
Example
Suppose you have the following violations and waiver. (Only the
relevant fields of the violation are shown.)
ISO_STRATEGY_MISSING
ViolationID LP:72
StrategyNode b1/p1
SourceInfo
PowerNet
NetName vdda
SinkInfo
PowerNet
NetName vdda
SinkInfo
PowerNet
NetName vdd
Waiver w1
-filter {sourceinfo:powernet:netname==vdda}
module generated_assertions;
UPF::supply_net_type local_vdd;
UPF::supply_net_type local_vdda;
initial begin
end
// Assertions
(local_vdda.voltage == 0)));
endmodule
module bind_file;
endmodule
Limitations
The analyze_waiver_correctness command generates
assertions for power nets only and not for ground nets.
The analyze_waiver_correctness command is hidden.
The following features are available with unified debug platform for
formal verification:
$VC_HOME/static/doc/vcst/examples/FCA
$VC_HOME/static/doc/vcst/examples/AEP
$VC_HOME/static/doc/vcst/examples/SEQ
$VC_HOME/static/doc/vcst/examples/UNR
$VC_HOME/static/doc/vcst/examples/CC
$VC_HOME /auxx/ctg/tcl/library/proc
$VC_HOME /auxx/ctg/tcl/library/doc
Limitations
The following are the limitations for this feature:
%cat simonopt.f
...
initCmCondVarsForVhdl
The Verdi GUI start-up page (welcome page) has a work mode
selection icon (Briefcase) that lists the work modes available in
Verdi for different debugging purposes. A new Formal Verification
Mode option is added on this page. You can enable this mode using
the setenv VERDI_VCSTATIC_BETA 1 command.
When you select the Formal Verification Mode, select Tools -->
VCST Apps --> Run VCST to pen the window (see Figure 1-35).
vc_static_shell.
Use Model
Backward Compatibility
Use Model
VC Static Menu/Toolbar
There are new Verdi menu/toolbar items added for the Formal
Verification mode.
For VC Formal SEQ, a new menu and tool items are added as
shown in Figure 1-38.
Snip driver has new RMB menu items in the SignalList and
Source views as shown in Figure 1-39 and Figure 1-40
respectively.
Figure 1-38 New Menu/Toolbar for SEQ
Schematic
VC Static has its own Schematic that displays the schematic based
on Netlist Model (NLDM). Verdis nSchema displays the schematic
based on the design imported in Verdi that might be different from
NLDM.
Backward Compatibility
As Activity View is embedded into Verdi, all the VC Static features in
VC Static views work. Verdi depends on Verdi Knowledge Database
(KDB) and Fast Signal Database (FSDB) generated by VC Static in
this phase, hence, Verdi debug features work in the same way as
earlier.
In the VC Formal use flow, you can perform formal analysis on your
design after executing an existing run.tcl file in the GUI mode.
Using GUI capabilities, you can add functionality for formal analysis,
such as:
Use Model
VC Formal also lets you invoke Verdi to debug properties and
violations. However, the vc_static_shell only logs its own Tcl
commands in the vcst_command.log file, while Verdi logs the
Verdi commands in novas.cmd file. This makes it difficult for you to
reproduce the scenarios for replay or reproduce the issue.
Note:
Some Verdi actions, such as snip point that is also applied to VC
Formal are logged. However, Verdi-related debug operations that
do not affect VC Formal are not logged (for example, show source,
zoom in waveform).
For example,
Use Model
The enhancements are explained in more detail in the following list:
For Formal Property Verification, the first six columns are status,
depth, name, vacuity, witness, and engine. The default column order
is as shown in Figure 1-44.
For SEQ, the columns are status, depth, name, vacuity, witness,
engine, expression, usage, and type. The default column ordering
is as shown in Figure 1-46.
Besides the column order and ToolTip, you can double-click the
grouping including the predefined groups like *Cov-Types, *AEP,
*Scopes to create and view the groups in one shot.
Note:
The underlined buttons/links in Activity View indicate that they
are clickable for additional function.
Note:
VC Formal does not support vacuity checks on assume properties
and cover properties.
Depth Field
The Depth field taken together with the primary status provides
information about the current state and progression.
Vacuity Field
The vacuity field represents the primary status of a vacuity goal. A
vacuity (assertion antecedent) goal is sub-goal for an assertion (if
applicable) and comes into being, if the vacuity checks are enabled.
The vacuity status is independent of the primary status of the
assertion; however, its status impacts the primary status of the
assertion. An assertions terminal status is either PROVEN vs
VACUOUS depending upon the status of its vacuity.
Note:
Since there is no separate Usage field for Vacuity, the Vacuity field
can reflect both usage and run status.
Use Model
Limitations
on the toolbar.
- You can then use to add the selected signals in the primary
nWave to the expression. For example, if you insert $rose()
into the expression, you can use to add a signal arb.a that
is selected in the primary nWave. The final expression is
$rose(arb.a).
10. Select the Evaluate at time 0 only option, if you want the
property to be evaluated at time 0 once. This option is the same
as the from_zero option present in VC Static.
11. Click OK. After VC Static completes the command evaluation, the
form is closed and the results are reflected in the property list with
the selection. Alternatively, an error message is issued, if there
are issues with the mentioned details.
Some of the fields that are common to the Add/Edit Property form
are filled automatically. A freeze expression is formed up at start and
whenever the clock is changed.
Note:
The property name cannot be changed when you edit the freeze
property.
Replotting
The Replot button enables you to regenerate a new FSDB
according to the current primary property you set after several
operations.
Exporting Properties
Click to export all or the selected new properties to Tcl or
Report format. If the selected property has an extended property,
then the extended property is also exported.
The default file format is Report format (*.rpt). You can select Tcl
format (*.tcl) optionally (see Figure 1-56).
Verdi inserts the newly-created cover property into property lists and
the property belongs to the original property as
traffic.assert_no_both_green_extend (see Figure 1-52).
Limitations
Tcl commands input, from the VC Static shell that create or modify
properties, is not synced with the Explore Property dialog box.
If you open multiple FSDB files in primary nWave and add signals
from those files, then those signals may be unrecognized signals
after restore signals.
Modified trigger condition is not supported.
Runtime signal cannot be used in Expression.
Explore property feature is not supported from restored session.
Explore session must end before a session can be saved.
Once multiple verification tasks are created, you can switch between
multiple tasks to modify setups, run checks, view results, and debug
counter-examples. The design data and any properties compiled as
part of the design are common to all tasks. The initial state is global
to all tasks.
Each verification task has an unique set of results. When a new task
is created, results from the predecessor task (property or coverage
status for example) are not copied into the new task. The results are
created in a task only when a check_* command is run in that task.
A specific design property may be proven in one task and falsified in
another because of differences between the constraints enabled in
each task.
Use Model
Limitations of Verification Tasks
The new task becomes the current task and subsequent setup
commands apply to this task. It is an error to create a task with
the same name as another task. By default, a new task inherits
all of the configuration data from the previous task, but a variety
of switches are provided to control exactly which optional data are
copied. For example, the following command limits the assertions
enabled in the new task to those matching a specific name:
fvtask -create <taskName> -asserts top_check*
-------------------------
_default
mycov
myprops(active)
check_fv -block
report_fv -list
Grid Configuration
Grid Report
Grid Control
Grid Configuration
You can use the set_grid_usage commands to configure a VC
Formal and VC Formal Coverage Analyzer run to launch workers
(executing solver tasks) inside server farms, and then retrieve the
status of grid submissions.
or
The following features are provided to add more visibility into the
status of the grid job submission:
Grid Report
The VC Static [shell|GUI] provides the status of workers or tasks
allowing you a better understanding of the utilization of the grid.
With this feature, you can obtain the following additional information
that helps you to understand and debug convergence issues:
For a given goal what solvers are working on it and their status:
- You can know which engines are unproductive or what is the
best engine for a given problem. For hard goals, you can know
the bounded depth reached by different engines.
Goals that are being worked on by orchestration at any given time:
Use Model
You can use the following two commands to view the details of
orchestration:
Goal View
The goal view (using the report_fml_engines command)
reports the different SJs that goal is present in and the status of that
goal in each SJ that contains that goal. This is displayed in a tabular
format for each goal. An example of the output in shown in
Figure 1-61.
The table in Figure 1-61 shows information about goals 0 to 11. Goal
0 corresponds to vacuity component of the
traffic.chk.assert_green_no_waiting_first property
while goal 1 corresponds to the
traffic.chk.assert_green_no_waiting_first itself
property. Goal 0 was falsified using engine s1 in 3 clock cycles
(FDepth) using solver job number 2. You can filter the table based on
column values.
- The JobId field gives the number of the solver job that got a
proven/falsified result for the goal or the best bounded result.
In addition, the JobId field has an indicator to indicate the status
of the job: (s) for scheduled, (r) for running, (c) for completed.
- The Engine column gives the engine name that got proven/
falsified result for a goal or best bounded result.
- Status can be one of the following:
no_status, proven, falsified, bounded
- SDepth is the safe depth of the goal. This is the depth for which
the goal has a bounded proof. Depth is the depth at which a
goal is falsified.
In Figure 1-62, information is listed for solver jobs 0 to 15. Solver job
1 corresponds to cc engine. All jobs ran on godel machine and
completed normally. You can filter the table based on particular
column values.
Generally, you first run the formal assertions and determine the proof
bounds reported by the formal verification tool. Then, within the
same verification task, the smallest proof bound is supplied as an
input and the formal coverage tool reports the code coverage targets
reached within that bound.
Use Model
To enable bounded coverage analysis, the following setup is
required:
You can also compare two bounded coverage results for further
analysis. More details on different scenarios are described in the
following sections.
For terminated (with cycle depth less than K)/inconclusive goals, you
can plan to run them again by increasing the resource limit to see if
they fall into the first three categories as follows:
If you want to override this default behavior, then you must use
the view_coverage command. The -cov_input and -
elfile options of the view_coverage command enable you
to specify the path of the coverage database to be imported and
the elfile(s) that must be loaded along with the coverage database.
Use Model
The following sections provide a detailed description of this feature:
Results Reporting
Activity View
Activity View
Along with the various general changes to activity_view, one
important change for SEQ is that activity_view has SEQ tab in
it. All SEQ specific assertions generated using the map_by_name
command are a part of this tab. All assumptions (SEQ or otherwise)
are part of the environment tab.
Click the Property link displayed next to Debug in the Details pane.
This action invokes Verdi and the screen shown in Figure 1-71 is
displayed.
Tracing back, you can see that stage3 in the impl is different as
shown in Figure 1-74. Tracing back further, you can see that, stage2
is the same for both designs. Thus, it is determined that the
discrepancy begins at stage3. Now, you can easily determine the
root cause of the discrepancy.
There are several configuration options that are available for SEQ
debugging in Verdi as shown in Figure 1-76.
SoC-IP Verification
161
Figure 2-1 IP Verification
IP with Lint, CDC
Complete
Model Checking
Link to Specs
Verification Planning
Support for UVM, System C, SV,
V2k, Assertions , UPF Integration
Testbench Creation
Coverage Model
Simulation/ LP Protocol Creation Code Coverage, Cover groups, Cover
Compliance Constraint Random Directives, AMS Coverage, Formal
Tests Coverage
Merging
Reporting
- URG
Close Coverage Gaps - Verdi
Manage Exclusions
Verification Planning
Testbench Creation
Validating Testbench: Functional Qualification
Verification Execution
Verification Debug
Closing Coverage Gaps
SoC-IP Verification
162
2
Verification Planning 1
Typically, verification starts with creating a plan that covers what
needs to be tested within a defined time frame. It also defines the
coverage criteria to determine that the verification is complete. Some
basic verification, such as checking a design against various coding
standards and design rules is performed on design blocks. The basic
verification is performed before the design is handed off to
verification engineers for sub-system and chip-level verification.
Verification Planning
163
Native LP Planner Support
You can add the LP sub-plan snps_LP to any HVP plan without
including the definition plan file in your top-level HVP plan, as shown
in the following example:
plan top;
feature feat_line;
measure Line Measure_1;
source = "tree: tb.i_top.level_1_test_a_dut";
endmeasure
endfeature
feature feat_lp_plan;
subplan snps_LP;
endfeature
endplan
Verification Planner automatically finds the plan definition for the
snps_LP plan from the simulation coverage database (simv.vdb),
when it needs to be annotated. If simv.vdb does not contain the
plan definition, an empty plan node is used as shown in the following
example:
Verification Planning
164
urg -dir simv.vdb -plan plan_w_lp_subplan.hvp
plan top;
feature feat_line;
measure Line Measure_1;
source = "tree: tb.i_top.level_1_test_a_dut";
endmeasure
endfeature
feature feat_lp_plan;
subplan snps_LP;
endfeature
endplan
By default, the LP metric is not defined in the top-level HVP plan.
When an LP object is added to an existing HVP plan, the LP object
is treated as low-level cover group object and is given a group metric
score instead of an LP metric score.
Note:
If you provide only the -metric option and do not specify the
group, the annotated report does not capture LP objects.
Verification Planning
165
Viewing LP Elements in the HVP Hierarchy Page
You can view the features of the LP plan in the HVP Hierarchy page
of the URG report, as shown in the following figure:
You can see the LP sub-plan feature details in the UPF LP page, as
shown in the following figure:
Verification Planning
166
Figure 2-2 LP Subplan Feature Details
Limitation
Verification Planning
167
Cell and Image Selection for Specification Linking
Previously, when you selected a cell or a table cell with multiple lines,
the tool highlighted the contents of the selected cell as well as the
contents of the adjacent cells as shown in the following figure:
There was no option to select the contents of only one cell in a table
and link it to a plan.
Verification Planning
168
Cell-Based Selection
Verification Planning
169
Figure 2-4 Cell-Based Selection of Text
Note:t Verdi uses the following rules to consider what text is part of
the selection:
Verdi draws a rectangle box from the start point to the end
point.
- The selection is character based and not word based.
- Characters out of the box are excluded in the selection.
- Characters complete in the box are included in the selection.
- Characters partly included in the box (their boundary has
intersection with the outline of box) are excluded from the
selection.
Figure 2-5 illustrates when the character is included in the box.
After the text is linked in to the HVP planner, the text in the
specification is enclosed.
Verification Planning
170
Figure 2-6 Linked Section
You can now use the normal flow of linking the selected cell to a
feature by clicking New feature/ Link as an sibling feature to
create a new feature or link to an existing selected feature
respectively. The abstract of this link is displayed in the text box if it
is lesser than 1000 characters long. For text that is longer than 1000
characters, a part of it is displayed in the text box.
Verification Planning
171
Table Cell Selection
You can select a cell in a table and link to plan as shown in figure
Selecting a Cell in a Table .
Image Selection
After the environment variable is set, you can select an image in two
ways. The detailed steps are as follows:
Approach 1
Verification Planning
172
2. Drag the mouse over the image till the end point and the release.
The image is selected.
Approach 2
When you just select images without any text, then the feature name
and the abstract is the combined Identifier string of images. For
example, if you select two images with IDs are image1 and image2
respectively, the feature name generated is image1_image2 and so
will the abstract of the linked section as shown in Figure 2-12.
Verification Planning
173
Figure 2-10 Abstract for Text and Image Selection
Verification Planning
174
Figure 2-12 Abstract for Multiple Image Selection
Verification Planning
175
Case 1: Section contains both images and text
In this case spec-linking follows the following process:
Review and update the text to the new section in the new
document.
Find the images in the updated section in the new document.
Generate a new section based on the text section and images,
the decision table below lists all the possibilities and review
results.
Table 2-1 Review Results for Text and Image Selection
The review result for an image depends on the updated text section
in the new document. There can be three results for image
comparison: Matching, Missing, New. The result conflict is not
applicable for images.
Verification Planning
176
The image and text works as an entire link in the review process, so
whatever actions (accept, reject) that you choose to apply, the action
is applied to both the image and the text. You will not be able to treat
the text or the image as separate review-able objects.
Limitations
Verification Planning
177
Figure 2-13 Cell-Based Selection Limitation
Verification Planning
178
Selecting text from an MS Visio diagram is supported, however,
selecting the whole diagram is not supported.
Selecting an image as a whole is supported.
It is recommended that you do not use cell selection to select both
text and image. This might result in the review result being wrong
if the image in the updated document is moved to other location.
Figure 2-14 Text and Image Selection
Rotated text is not well supported, you may not able to select it.
This also impacts line coverage. For example, in the following
figure, the text selected covers two lines.
Verification Planning
179
When the text is rotated as shown in the following figure, the text
selection would have to cover many lines instead of two lines as
shown in the previous figure. This might impact line coverage.
Coverage results are annotated to the plan that helps to map the
verification completeness on a feature by feature basis at the
aggregate level.
Verification Planning
180
Use Model
Verdi Coverage flow requires the .hvp files that capture the
Verification Plan to be loaded on the Verdi Coverage Graphical User
Interface (GUI) and the coverage is annotated within the GUI.
Verification Planning
181
Figure 2-15 Open Plan
Verification Planning
182
Figure 2-16 Verdi GUI
Verification Planning
183
Figure 2-17 Recalculate
Verification Planning
184
3
Testbench Creation 1
Testbench creation includes the creation of a coverage model
(generally, using UVM methodologies), which is a method for
verification accountability.
Testbench Creation
185
The following solution is available as part of the L-2016.06-SP1
release of Verification Compiler Platform:
Testbench Creation
186
You can select the following paths either for Verdi or for DVE
transaction recording during simulation:
Use Model
The following sections describe how you can use the unified UVM
library with VCS:
Testbench Creation
187
Transaction/Message Recording in DVE/Verdi With VCS
The following sections describe how you can use the unified UVM
library with Verdi or DVE transaction recorder and message catcher
for VCS:
Compilation
Simulation
Compilation
The following sections describe the different compilation flows that
you can perform with the unified UVM library.
+incdir+$VC_HOME/etc/uvm \
$VC_HOME/etc/uvm/uvm.sv \
$VC_HOME/etc/uvm/dpi/uvm_dpi.cc +incdir+$VC_HOME/etc/uvm/
vcs \
$VC_HOME/etc/uvm/vcs/uvm_custom_install_vcs_recorder.sv \
+incdir+$VC_HOME/uvm/verdi \
$VC_HOME/etc/uvm/verdi/
uvm_custom_install_verdi_recorder.sv
For example,
Testbench Creation
188
<compile_options> <user source files using UVM>
For example,
%> vlogan -sverilog -ntb_opts uvm
Testbench Creation
189
3. Elaboration
Add the -ntb_opts uvm compile-time option with the
-debug_access option to enable transaction and message
recording for both Verdi and DVE. The
uvm_custom_install_recording and
uvm_custom_install_verdi_recording top modules as
well as the following files are included automatically in elaboration:
$VC_HOME/etc/uvm/dpi/uvm_dpi.cc \
uvm_custom_install_recording \
uvm_custom_install_verdi_recording
For example,
%> vcs -debug_access+all -ntb_opts uvm \
<elab_options> <top module name>
-P $NOVAS_HOME/share/PLI/VCS/LINUX/novas.tab \
$NOVAS_HOME/share/PLI/VCS/LINUX/pli.a \
<compile_options> <user source files using UVM>
Testbench Creation
190
- In UUM compile flow
%> vlogan -sverilog -ntb_opts uvm
Simulation
The following sections describe how you can perform simulation
using the unified UVM library.
+UVM_VERDI_TRACE=<Argument>
Enables Verdi flow when added during simulation.
+UVM_TR_RECORD
Enables Verdi transaction recorder.
Testbench Creation
191
+UVM_LOG_RECORD
Enables Verdi message catcher.
Note:
In the Verification Compiler environment, where Verdi is set as
default GUI (or value of the SNPS_SIM_DEFAULT_GUI
environment variable is set to verdi), Verdi recorder is enabled
to record messages and transactions into FSDB files. So, you do
not need to use the UVM_VERDI_TRACE variable to enable Verdi
UVM flow. However, you still need to add +UVM_TR_RECORD or
+UVM_LOG_RECORD options to enable transaction recording or
message recording accordingly.
For example,
//Use UVM_VERDI_TRACE and enable both transaction
recording and message catching
Testbench Creation
192
Enabling Transaction/Message Recording in DVE
+UVM_TR_RECORD
Enables DVE transaction recorder.
+UVM_LOG_RECORD
Enables DVE message catcher.
For example,
%> ./simv +UVM_TR_RECORD +UVM_LOG_RECORD
Testbench Creation
193
4
Validating Testbench: Functional
Qualification 1
Testbench quality is commonly measured using coverage metrics,
such as code coverage, toggle coverage, and functional coverage,
which are enabled during simulation. These metrics reflect how well
a design is activated by test vectors, but are insensitive to error
detection capabilities of the testbench. It becomes imperative to
perform functional qualification of the testbench to improve the
testbench quality.
Use Model
Limitations
Use Model
Limitations
Use Model
Limitations
Use Model
For example,
For example,
setconfig -Simulator=native
Examples
Note:
Any file that needs to be qualified must be analyzed by
specifying it in the certitude_compile file.
Note:
Certitude communicates with VCS internally through a
combination of environment variables and Certitude database.
This process is transparent.
Use Model
Key Points to Note
Use Model
Use Model
Key Points to Note
Use Model
5. Generate an RIDB file with the original source code and load the
design automatically in Verdi with the verdistart, or
verdisourcedebug command. Example as follows:
verdidumpridb -testcase=fir_rtl
Verification Execution
214
Compile Turnaround Time
Verification Execution
215
Unified Compile Front End
Note: When using the VCS simulator, it is recommended that you use
the Unified front-end flow to generate the KDB. Otherwise, you
may encounter few issues with unnamed blocks. Since the
naming of an unnamed block, an unnamed assertion, and a c-unit
is different in KDB and FSDB, you may encounter annotation, drag
and drop, and other debug functionality issues in Verdi.
The benefits offered by Unified Compile are as follows:
Use Model
Limitations
Use Model
The following sections describe how to use the unified compile front
end to generate Verdi KDB and read the compiled design:
Verification Execution
216
Generating Verdi KDB With Unified Compile
Reading Compiled Design With Verdi
When you specify the kdb option, Unified Compile creates the
Verdi KDB and dumps the design into the libraries specified in the
synopsys_sim.setup file.
For example,
To generate only the Verdi KDB and skip the simulation database
generation, specify the following argument with the -kdb option:
-kdb=only
Verification Execution
217
Generates only the Verdi KDB that is needed for both post-
process and interactive simulation debug with Verdi.
In VCS two-step flow, this option does not generate VCS compile
data/executable, and does not disturb the existing VCS compile
data/executables.
For example,
You can perform the same operations through the Verdi GUI as
follows:
Verification Execution
218
Figure 5-1 Import Design Form
You can also add the -simdir <path> option to the Verdi
command line to ensure that VCS and Verdi use the same data from
the synopsys_sim.setup file. The <path> argument points to the
library directory from where VCS is compiled. Use this option to
invoke Verdi from a working directory that is different from the VCS
working directory.
You can also use the -top option with the -simdir option to specify
the top module in the specified library directory. For example,
Verification Execution
219
%> verdi -simflow simdir [<path>] -top [<your top module>]
If the -top option is not specified, the design top is used by default.
Example
Filename: 01_vhtop.vhd
library IEEE,STD;
use IEEE.STD_LOGIC_1164.all;
use std.textio.all;
use IEEE.STD_LOGIC_TEXTIO.all;
entity vh_top IS
end vh_top;
architecture arch of vh_top is
signal s1: std_logic_vector(3 downto 0);
signal s2: std_logic_vector(3 downto 0);
component VH1
port (s1: out std_logic_vector(3 downto 0);
s2: out std_ulogic_vector(3 downto 0));
end component;
begin
vh_inst : VH1 port map(s1,s2);
process(s1,s2)
variable L:line;
begin
write(L,NOW);
write(L,string'(" s1= "));
write(L,s1);
writeline(output,L);
write(L,string'(" s2= "));
write(L,s2);
writeline(output,L);
end process;
end arch;
library IEEE;
use IEEE.STD_LOGIC_1164.all;
ENTITY VH1 IS
port (s1: out std_logic_vector(3 downto 0);
s2: out std_ulogic_vector(3 downto 0));
END VH1;
architecture arch of VH1 is
begin
P: process
begin
wait for 0 ns;
Verification Execution
220
s1 <= "1111";
s2 <= "0011";
wait for 2 ns;
s1 <= "1010";
s2 <= "1110";
wait for 3 ns;
s1 <= "Z1X1";
s2 <= "XX10";
wait for 4 ns;
s1 <= "XXZ1";
s2 <= "1010";
wait;
end process P;
end arch;
Filename: synopsys_sim.setup
Command Lines
Verification Execution
221
VHDL Languages, Syntax, and Semantics
Following is the list of supported VHDL languages, syntax, and
semantics:
Verification Execution
222
- Matching relational operators (for bit and std_ulogic)
- Non-static expressions in port map
- Various enhancements to packages std_logic_1164,
numeric_std, numeric_std_unsigned, fixed point and
floating point are supported
- VHDL 1076-2008 encryption (IEEE encryption)
gen_ip encryption
128 bit VCS-only encryption
IEEE encryption
Verification Execution
223
Key Points to Note
The vericom utility exists in Verdi. For VCS users, Unified
Compile flow is recommended to generate KDB for data
consistency and better performance. For third-party simulator
users, compilation does not change and continues to use the
vericom option. When loading the compiled design library
(KDB) from the GUI (loading from the command line stays the
same), ensure that the vericom option is selected in the From
field under the From Library tab of the Import Design form.
As VCS and vericom are different Verilog compilers, there are
some behavioral differences between them. In such cases,
Unified Compile follows the behavior of VCS for consistency
reasons. The supported language subset also follows the
supported subset of VCS.
All the compilation information including the compile log of Verdi
KDB is logged to the regular VCS compiler log file.
The library mapping information is obtained from the
synopsys_sim.setup file in VCS three-step flow. The library
mapping information in the novas.rc resource file is ignored in
the VCS three-step unified compile flow.
The Unified Compile does not apply to the import-from-file flow of
Verdi. Import-from-file continues to use the vericom parser to
read in the Verilog source code directly. It uses the library mapping
information from the novas.rc resource file, which is similar to
the Verdi behavior.
In the VCS two-step flow, the VCS generated KDB (work.lib++)
is saved in the work directory in the current working directory.
Verification Execution
224
In the VCS three-step flow, the vlogan -work <work>
generated KDB (work.lib++) is saved in the same working
directory as AN.DB and the physical directory path of the library
is picked as per the mapping present in the
synopsys_sim.setp file. You can use the verdi -simflow
-lib option to specify the working directory to load the KDB.
When the vhdlan command is executed in the VHDL Common
Analyzer mode to generate both intermediate files and KDB files,
the following impacts are expected:
- More CPU time is consumed to generate KDB.
- Higher peak memory is consumed to accommodate KDB
resident in memory and auxiliary data structures.
Limitations
The following are the limitations with Unified Compile:
Verification Execution
225
Native VIP Solutions
Verification Execution
226
PIP technology allows you to compile a self-contained functional
unit separately in a design and a testbench. A shared object file
and a debug database are generated for a self-contained
functional unit. All of the generated shared object files and debug
databases are integrated in the integration step to generate a
simv executable. Only required PIPs are recompiled with
incremental changes in the design or the testbench.
For more information on Partition compile and Precompiled IP
technologies, see the VCS/VCS MX LCA Features Guide.
Use Model
You can use three new simulation targets in the Makefiles of VIP
UVM examples to run the examples in Partition compile or
Precompiled IP technologies. In addition, Makefiles allow you to run
the examples in back-to-back VIP configurations. The VIP UVM
examples are located in the following directory:
$VC_HOME/examples/vl/vip/svt/vip_title/sverilog
For example,
/project/vc_install/examples/vl/vip/svt/
usb_svt/sverilog
/project/vc_install/examples/vl/vip/svt/
amba_svt/sverilog
Verification Execution
227
Separate partitions are created for packages that are common to
multiple VIPs.
VIP-level partitions are defined in a way that all the partitions are
compiled in the similar duration of time. This enables the optimal
use of parallel compile with the -fastpartcomp option.
You can modify the pc.optcfg configuration file to include
additional testbench or DUT-level partitions.
Verification Execution
228
In Partition compile technology, changes in testbench, VIP, or DUT
source code trigger recompilation in required partitions only. You
must ensure that the Verification Compiler compilation database is
not deleted between successive recompilations.
Verification Execution
229
command with the -genip option is created for each line specified
in the pc.optcfg configuration file. The -integ option is used in
the integration step to generate the simv executable.
Verification Execution
230
For more information on partition compile and precompiled IP
options, such as -sharedlib and -pcmakeprof, see the VCS/
VCS MX LCA Features Guide.
Example
The following are the steps to integrate VIPs into the partition
compile and PIP technologies:
Verification Execution
231
To run the ts.base_test.sv test in the VCS UUM flow with
Partition compile, use the following command:
gmake base_test USE_SIMULATOR=vcsmxpcvlog
To run the ts.base_test.sv test in the VCS UUM flow with
Precompiled IP, use the following command:
gmake base_test USE_SIMULATOR=vcsmxpipvlog
5. To modify or change partitions, you must change the pc.optcfg
file for the example.
Verification Execution
232
6
Verification Debug 1
Nearly 40% of the verification time is spent on debugging and this is
the longest in the verification cycle. The time spent on debugging is
an indication of the number of defects and points to inadequacies in
the current approach. Simple defects can add to the performance
degradation and can turn into crucial defects that take more time to
get detected at the subsystem or at the chip level. For the block-level
verification, the formal verification technology can be used to find
corner case defects and improve the design quality in the most
efficient method.
Verification Debug
233
Generating VCS Coverage Database From Design and FSDB
Power Model L1/Utility/Applications
Value Traverse-Based Netlist
Value Traverse-Based Netlist
Enhancing NPI Applications in the Verification Compiler Platform
Application
Unified Verdi Debug Platform for Interactive and Post-Simulation
Debug
Saving/Loading Verdi Elaboration DB Library to/from Disk
Attaching a Running Simulation in Verdi
Reverse Interactive Debug
Unified UCLI Command for FSDB Dumping
AMS-Debug Integrations
Unified Transaction Debug With Native Verdi Protocol Analyzer
Memory Debug With Native Verdi Protocol Analyzer
VC APPs Protocol Analyzer
Protocol Analyzer: Native Performance Analyzer for
Transactions
Verification Debug
234
VC Formal Coverage With Verdi Coverage
Use Model
This section describes how to use Verdi coverage to display and link
to VC Formal results. This section consists of the following
subsections:
where,
Verification Debug
235
vcf is a command to start the VC Formal tool with an interactive
shell. The vcf shell is a shell that calls vc_static_shell
internally. The vcf shell supports all the options supported by
vc_static_shell. The vcf shell automatically runs in the 64-bit
mode, unless you explicitly specify the -mode32 option. For details
on vc_static_shell, see the VC Formal Verification User Guide.
-f indicates your VC Formal execution script
You must provide your own tcl script to run VC Formal. To enable
collection and display of coverage data in Verdi, the following two
commands must be included in the tcl script:
1. The command to run VC Formal must include the all flag. If you
want to target assertions (not just cover properties), also include
the -cm assert as a flag to VCS:
read_file all -format verilog -sva -top $top -vcs "-cm assert -sver
ilog $testDir/test.v -sva"
Verification Debug
236
Verdi GUI for VC Formal
To display the Verdi GUI for VC Formal (see the figure below), use
the vcf command with the -verdi option.
Verification Debug
237
VC Formal Coverage in Verdi
To load the coverage database generated with VC Formal in Verdi,
use the following command:
where,
The FVtype column indicates the usage field. The value in this
column can be either Assert, Cover, or Assume.
Verification Debug
238
The FVstatus column indicates the run status of VC Formal. Its
possible values depend on FVtype:
Verification Debug
239
Figure 6-3 VC Formal Results in HVP
feature f_default;
// fvassert_expected_status = proven;
// fvassert_expected_mindepth = -1;
// fvcover_expected_status = covered;
// fvcover_expected_maxdepth = 0;
endmeasure
endfeature
feature f_expected_assigned;
fvassert_expected_status = inconclusive;
fvassert_expected_mindepth = 50;
Verification Debug
240
fvcover_expected_maxdepth = 50;
endmeasure
endfeature
endmeasure
Verification Debug
241
fvassert_expected_status = Proven, then the FVAssert metric
score becomes 1/1. If expectation is fvassert_expected_status
= inconclusive and fvassert_expected_depth = 60, then the
FVAssert metric score becomes 0/1.
Verification Debug
242
Case4: fsm.c_blk_cnt: FVtype is "cover", FVstatus is "covered",
and FVdepth is "1". In the top.f_default feature, with default
attribute values, fvcover_expected_status is "covered" and
fvcover_expected_maxdepth is "0". Compare FVstatus to
expected attributes values and if the expectation does not meet,
the FVAssert metric score becomes 0/1.
Case5: fsm.c_trans, no FV annotation. In the
top.f_default.m_no_fv_ann measure, matching fsm.c_trans
without FV annotation, the FVAssert metric becomes 0/1 because
the FVAssert metric is referred explicated in measure.
Case6: dummy source. In the top.f_default.m_dummy measure,
for all metrics for "no matching region", the score becomes all "0".
Verification Debug
243
Generating VCS Coverage Database From Design and
FSDB
If you use the VCS verification flow, you can obtain VDB and use it
as the main coverage repository. However, in the non-VCS
verification flows, such as FPGA prototyping and emulator, you can
obtain FSDB rather than VDB. If you still have to manage the
coverage, you need to obtain the coverage database from the flow
and merge it to VDB.
To calculate the VCS coverage data from FSDB and then generate
the VCS coverage database from FSDB, use the covsim utility. The
coverage data supported by covsim includes the following:
Verification Debug
244
Figure 6-4 The covsim Utility Generates VCS Coverage Database From
FSDB
Verification Debug
245
Data Input and Output Requirements
To prepare the initial empty coverage database with VCS, use the
following command:
where,
Verification Debug
246
-cm_tgl mda enables the toggle coverage for Verilog 2001 and
System Verilog unpacked multidimensional arrays.
Use Model
You can perform the following steps to generate the VCS coverage
database from a design and FSDB:
Verification Debug
247
Prepare FSDB for covsim in the Extraction Phase
The extraction phase extracts essential signals for covsim. Note that
this phase is optional. The option is useful, if you use FPGA
prototyping/emulation since dumping all signals to FSDB is time-
consuming. If the FSDB is already configured for the simulation
phase, the extraction phase can be skipped.
Verification Debug
248
If either the -simBin option or the dir option is not specified, the
default input coverage database is simv.vdb.
After the extraction phase, the signal list is generated in the working
directory covsim.work++.
For the FSM coverage, FSM state signals are generated in the
fsm.list file.
memsys_test_top.dut.Urrarb.state
memsys_test_top.dut.Umem.state
[Instance]
memsys_test_top.dut.u3
[Port]
memsys_test_top.dut.u3.ce_N
memsys_test_top.dut.u3.rdWr_N
memsys_test_top.dut.u3.ramAddr
memsys_test_top.dut.u3.ramData
[Signal]
memsys_test_top.dut.u3.chip (MDA)
[Instance]
[Port]
[Signal]
Verification Debug
249
Calculate the Coverage Data From FSDB by covsim in
the Simulation Phase
The simulation phase generates the calculated coverage database
from FSDB.
Verification Debug
250
Another required input of the simulation phase is the FSDB file.
Verification Debug
251
The covsim Commands
Verification Debug
252
Power Model L1/Utility/Applications
Use Model
Before using the VC Apps power model L1 APIs to access the power
model and traverse the status of power model, you need to import
the HDL design and the UPF file. After the desired VC Apps power
model L1 APIs are applied to access the power model, you can
check the results of the power domain crossing and the power
supply network.
The following figure shows the use flow of the VC Apps power model
L1 APIs:
Verification Debug
253
Figure 6-7 Use Flow - VC Apps Power Model L1 APIs
Verification Debug
254
Table 6-2 VC Apps Power Model L1 APIs for Power Domain Crossing
API Description
npi_pw_get_domain_cro Gets the domain crossing power domain based on the NPI
ssing_pd Power Model.
npi_pw_get_domain_cro Gets the domain crossing path based on the NPI Power
ssing_path Model.
npi_pw_get_domain_cro Gets the domain crossing path through two ports based on
ssing_path_through_port the NPI Power Model.
s
npi_pw_get_domain_cro Gets the domain crossing path for the specified power
ssing_path_by_pd domain based on the NPI Power Model.
npi_pw_get_domain_cro Gets the domain crossing path between the two specified
ssing_path_through_pds power domains based on the NPI Power Model.
npi_pw_get_domain_cro Gets the domain crossing path for the specified power
ssing_path_by_pd_hdl domain based on the NPI Power Model.
npi_pw_get_domain_cro Gets the domain crossing path between the two specified
ssing_path_through_pd_ power domains based on the NPI Power Model.
hdls
npi_pw_get_all_domain_ Gets all the domain crossing paths based on the NPI Power
crossing_path Model.
npi_pw_domain_crossing Dumps the domain crossing path for the specified power
_path_by_pd_dump domain based on the NPI Power Model.
npi_pw_domain_crossing Dumps the domain crossing path between the two
_path_through_pds_dum specified power domains based on the NPI Power Model.
p
npi_pw_domain_crossing Dumps the domain crossing path for the specified power
_path_by_pd_hdl_dump domain based on the NPI Power Model.
npi_pw_domain_crossing Dumps the domain crossing path between the two
_path_through_pd_hdls_ specified power domains based on the NPI Power Model.
dump
npi_pw_all_domain_cros Dumps all the domain crossing paths based on the NPI
sing_path_dump Power Model.
Verification Debug
255
Table 6-3 VC Apps Power Model L1 APIs for Power Supply Network
API Description
npi_pw_get_pd_from_inst Gets the power domain handle for the specified instance
name.
npi_pw_get_primary_powe Gets the primary power net handle for the specified
r_net_from_inst instance name.
npi_pw_get_primary_groun Gets the primary ground net handle for the specified
d_net_from_inst instance name.
npi_pw_get_boundary_inst Gets the instance handles of boundary instances for the
_from_pd specified power domain handle.
npi_pw_trace_supply_drive Finds the drivers of a given supply port or supply net based
r on the Power Model.
npi_pw_trace_supply_load Finds the loads of a given supply port or supply net based
on the Power Model.
npi_pw_get_supply_networ Finds the paths in power supply network by tracing drivers
k_path and loads of the given from/through/to supply net or supply
port handle vectors based on the Power Model.
npi_pw_get_primary_powe Finds the paths of the primary power supply network for
r_network_path the specified instance name.
npi_pw_get_primary_groun Finds the paths of the primary ground supply network for
d_network_path the specified instance name.
npi_pw_supply_network_p Dumps supply network path vector.
ath_dump
npi_pw_primary_power_gr Dumps the paths of the primary power and primary ground
ound_network_path_dump supply network for the specified instance name.
npi_pw_get_pd_from_prim Gets the power domain handles for the specified primary
ary_power_net power net.
npi_pw_get_pd_from_prim Gets the power domain handles for the specified primary
ary_ground_net ground net.
Verification Debug
256
Value Traverse-Based Netlist
To propagate values through signals, you can first specify the scope
as the top scope of propagation. Signals outside the top scope are
not considered. Under a specified top scope, you can set values on
ports, instports, or nets either by bus or by bits. Each bit of instports
and ports is taken as one node and values are set on each node by
bit. After propagating, the fan-out cone of those set signals is
generated. The graph structure (Figure 6-8) stores the driver/load
relation. You can start to propagate values according to the
topological sorted order. You can obtain values or trace driver/load
of signals under the top scope after propagating.
Verification Debug
257
Figure 6-8 Top Boundary Scope
Use Model
Limitations
Use Model
Before using the VC Apps value traverse netlist L1 APIs to set values
to signals and propagate the value, you need to import the design
and initialize the VC Apps value traverse netlist L1 APIs. After
propagating the value, you can obtain the values.
The following figure shows the use flow of VC Apps value traverse
netlist L1 APIs:
Verification Debug
258
Figure 6-9 Use Flow - VC Apps Value Traverse Netlist L1 API
The following example shows how this use flow works in C++
environment:
Verification Debug
259
Figure 6-10 VC Apps Value Traverse Netlist L1 APIs Use Flow in C++
Basic setting
Active trace
The VC Apps value traverse netlist L1 APIs are created based on the
NPI Netlist L1 and L0 model and are provided for both TCL and C++
interfaces. Table 6-4 lists the features of VC Apps value traverse
netlist L1 APIs for these settings:
Verification Debug
260
VC Apps Value Traverse Netlist L1 APIs for Basic Settings
The VC Apps value traverse netlist L1 APIs provide a series of
APIs to present the process to propagate the value from the driver
to the load and from the input port to the input instport of a register.
You should first pick some signals to set values and then perform
propagation to see the change of these values and the way they
affect their loads while passing through different cells. You can
obtain values from the target signals or figure out the exact bit of
the register, which is hit after a value that is propagated.
Note:A value traverse netlist model cannot function without calling
the APIs in the following order: begin, set_value, propagate,
get_value/trace/other, and then end.
Table 6-4 VC Apps Value Traverse Netlist L1 APIs for Basic Setting
API Description
npi_vanl_begin Initializes the VANL control center.
Sets the top boundary scope. If NULL, all
scopes are included. When a specific scope
is set, any signals outside the scope will not
be considered.
Finds all literal nets under the top boundary
scope and then call npi_vanl_set_value to
set values to corresponding nodes.
Sets default value that will be assigned to a
new created node if no value is set.
Value returns 1 if success.
npi_vanl_end Deletes all nodes, pins, and instances in the
control center.
Deletes the value traverse netlist L1 API
control center.
Value returns if success.
Verification Debug
261
API Description
npi_vanl_set_value Sets values to the specified signal.
npi_vanl_set_value_by_hdl The signal can be net, port, instport handle,
npi_vanl_set_value_from_file pseudo net, port, and instport.
Creates corresponding nodes of these
signals with the default value defined in
npi_vanl_begin.
Once set, those values are forced, will not
change after the next
npi_vanl_propagate_value is called.
Value returns the total number of nodes being
set.
npi_vanl_propagate_value Traces load and creates corresponding
nodes with the default value from user-set
nodes.
Topological sorts all user-set and generated
nodes.
Propagates and evaluates values according
to the topological sort order.
Value returns 1 if success.
npi_vanl_get_value Returns the value string of the specified
npi_vanl_get_value_by_hdl signal.
npi_vanl_dump_value_to_file The format can be npiNlBinFormat,
npiNlOctFormat, npiNlHexFormat, and
npiNlDecFormat.
If npi_vanl_dump_value_to_file is called, it
dumps all declaration net under the top
boundary scope with its name and value to a
specified file. This API returns the total
number of declaration nets being dumped.
npi_vanl_clear_all_value Clears the value of all nodes and sets all
nodes to the default value.
Nodes can be set or can obtain value again.
Value returns 1 if success.
Verification Debug
262
The following example shows the usage of VC Applications value
traverse netlist L1 APIs in C++ interface:
Verification Debug
263
The following example shows the usage of VC Applications value
traverse netlist L1 APIs in Tcl interface:
Verification Debug
264
VC Apps Value Traverse Netlist L1 APIs for Active Trace
The VC Apps value traverse netlist L1 APIs provide a way to trace
the driver/load with a value. The tracing action is called active trace.
You can trace the driver/load after the value is set and then
conveniently find the possible signals that cause the value change of
the target signal.
The following table shows the list of VC Apps value traverse netlist
L1 APIs for active trace.
Table 6-5 VC Apps Value Traverse Netlist L1 APIs for Active Trace
API Description
npi_vanl_driver Active traces drivers of a signal based on the
npi_vanl_driver_by_hdl NPI Netlist Model. Active trace only happens
npi_vanl_driver_dump when tracing from a cell output. It considers the
npi_vanl_driver_by_hdl_dump cell type and the value both on output and input.
The API does not traverse across the module
boundary and path through the assign cell
treated as a primitive cell.
Value returns the total number of driver found.
npi_vanl_load Active traces loads of a signal based on the NPI
npi_vanl_load_by_hdl Netlist Model. Active trace only happens when
npi_vanl_load_dump tracing from a cell input. It considers the cell type
npi_vanl_load_by_hdl_dump and the value both on the output and input.
The API does not traverse across the module
boundary and path through the assign cell
treated as a primitive cell.
Value returns the total number of load found.
npi_vanl_fan_in_reg Finds all fan-in register objects (instances) of a
npi_vanl_fan_in_reg_by_hdl signal using the NPI VANL graph under active
npi_vanl_fan_in_reg_dump trace.
npi_vanl_fan_in_reg_by_hdl_ Register types in the Netlist model are:
dump npiNlFlipFlopCell, npiNlLatchCell,
npiNlExternalRamCell, npiNlFSMCell,
and npiNlInfLatchCell.
Value returns the total number of fan-in register
instances found.
Verification Debug
265
API Description
npi_vanl_fan_out_reg Finds all fan-out register objects (instances) of a
npi_vanl_fan_out_reg_by_hdl signal using the NPI VANL graph under active
npi_vanl_fan_out_reg_dump trace.
npi_vanl_fan_out_reg_by_hdl Register types in Netlist model are:
_dump npiNlFlipFlopCell, npiNlLatchCell,
npiNlExternalRamCell, npiNlFSMCell,
and npiNlInfLatchCell.
Value returns the total number of fan-out register
instances found.
While tracing active driver of each instType, each of them has its own
rule. For npiNlSymbolLibInst, extract its npiNlFunc,
npiNlXFunc, and npiNlThreeStateFunc. The active drivers are
evaluated according to these function strings. For Example:
npiNlFunc: !((A1&A2)|(B1&B2))
When A1=1, A2=0, B1=0, and B2=1, the active drivers of ZN are A2
and B1 because the output value of ZN is caused by the inputs
(A1&A2)=0 and (B1&B2)=0, and each of these inputs is caused by
A2 and B1.
Verification Debug
266
? 0 : 0 ;
1 1 : 1 ;
endtable
endprimitive
Verification Debug
267
Example: A = & B
B[I] B[J] B[K] Driver
0 0 0 B
0 0 1, X B[I], B[J]
0 1 X B[J]
1 1 1 B
X X X B
CellType: npiNlOrReduCell, npiNlNorReduCell
Example: A = | B
B[I] B[J] B[K] Driver
0 0 0 B
0 0 1, X B[K]
0 1 X B[J]
1 1 1 B
X X X B
CellType: npiNlMuxCell, npiNlInfLatchCell
Example:
always @(sel or r1 or r2) begin
if (sel) r3 = r1;
else r3 = r2;
end
endmodule
r1 r2 sel Driver
? ? 0 r2, sel
? ? 1 r1, sel
? ? X r1, r2, sel
CellType: npiNlLogAndCell
Example: A = B && C
B[I] B[J] B[K] C[i] C[j] C[k] Driver
0 0 0 0 0 0 B, C
0 0 1, X 0 0 0 C
0 0 X 0 0 0 C
1 1 1 0 0 0 C
X X X 0 0 0 C
0 0 0 X X X B
0 0 X X X X B[K], C
0 1 X X X X C
1 1 1 X X X C
X X X X X X B, C
Verification Debug
268
B[I] B[J] B[K] C[i] C[j] C[k] Driver
0 0 0 1 1 1 B
0 0 X 1 1 1 B[K]
0 1 X 1 1 1 B[J], C
1 1 1 1 1 1 B, C
X X X 1 1 1 B
CellType: npiNlLogOrCell
Example: A = B || C
B[I] B[J] B[K] C[i] C[j] C[k] Driver
0 0 0 0 0 0 B, C
0 0 1, X 0 0 0 B[K]
0 0 X 0 0 0 B[J]
1 1 1 0 0 0 B
X X X 0 0 0 B
0 0 0 X X X C
0 0 X X X X B[K], C
0 1 X X X X B[J]
1 1 1 X X X B
X X X X X X B, C
0 0 0 1 1 1 C
0 0 X 1 1 1 C
0 1 X 1 1 1 B[J], C
1 1 1 1 1 1 B, C
X X X 1 1 1 C
CellType: npiNlTriBufCell
Example: bufif0 buf1 (out1, D, E)
D E Driver
? 0 D, E
? 1, X E
CellType: npiNlTriCell
Example: notif0 n1 (out3, D, E);
D E Driver
? 1 D, E
? 0, X E
CellType: npiNlEQCell, npiNlAOICell, npiNlOAICell
Analyze by its npiNlFunc, npiNlXfunc, and npiNlThreeStateFunc.
Verification Debug
269
CellType: npiNlUDP
Check it there any table term matching with value of drivers.
Active drivers: the corresponding term's value of input is not equal "?".
Example:
A B OUTPUT Driver
0 0 0 A, B
0 ? 0 A
? 0 0 B
1 1 1 A, B
The following example illustrates how to trace driver with value in the
C++ interface:
Verification Debug
270
Verification Debug
271
The following example illustrates how to trace driver with value in the
Tcl interface:
Verification Debug
272
The program recursively traces the driver with value and the value of
each node is shown in Schematic1. At the first stage, the active
driver of top.w1 should be top.w2. Note that top.w3 is dropped.
The reason is that the value of top.w1 is X and the possible driver
to cause this is only top.w2 with value X. With the similar reason,
the active driver of top.w2 should be top.w7 and top.w9, as the
value X of top.w2 is caused by the value of top.w7 and the control
pin top.w9 that are X and 1 respectively.
As for the active trace driver of top.w3 that has value as 1 and the
instance as npiNlOrCell, the possible driver that causes this 1 is
signals whose value is also 1. Thus, you obtain top.w5 and
top.w6.
Limitations
The following are the limitations with the VC Apps value traverse
netlist L1 APIs:
Verification Debug
273
- npiNlEncoderCell
- npiNlComboCell
- npiNlOpCell
- npiNlBusKeeperCell
- npiNlMacroCell
- npiNlInitCell
- npiNlBiDirectionCell
- npiNlFlipFlopComboCell
- npiNlTranCell
The value goes straight through npiNlModuleCell.
The value does not propagate through registers. The VC Apps
value traverse netlist L1 APIs is only applicable for propagating
values between combinational cells. Thus, the register output is
not evaluated during the propagation.
If a cell input or wire is driven by two or more drivers with different
values, the value is resolved according to the following rule:
Input 0 1 X Z
0 0 X X 0
1 X 1 X 1
X X X X X
Z 0 1 X Z
Verification Debug
274
Enhancing NPI Applications in the Verification Compiler
Platform Application
Use Model
Limitations
Use Model
The following NPI library APIs (based on NPI Language model) are
enhanced to support driver/load tracing on SV interface port:
npi_trace_driver2
npi_trace_driver_by_hdl2
npi_trace_driver_dump2
npi_trace_driver_by_hdl_dump2
npi_trace_load2
npi_trace_load_by_hdl2
npi_trace_load_dump2
npi_trace_load_by_hdl_dump2
Verification Debug
275
The following descriptions outline the enhancements of the object
diagram in NPI Language model:
Verification Debug
276
Figure 6-14 Property npiDefName Shows Definition Name of SV Interface
Port
For npiRefObj:
- Applying the method npiRefObj to another reference object
obtains the reference object whose actual is same as the
declaration of the reference handle. In the following example,
the npiRefObj for the var bit top.i1.a[0] returns the reference
object top.u1.intf.a.
interface ii ;
reg [5:0] a;
endmodule
module m(interface intf);
initial
intf.a[3] = intf.a[1];
module top;
ii i1();
m u1 (i1);
endmodule
Verification Debug
277
- For the npiUse method, the resultant objects do not check the
overlapping with the reference handle.
Figure 6-15 Apply Method npiRefObj to Another Reference Object
[CASE1]
1 interface I;
2 logic [7:0] r;
3 int x=1;
4 bit R;
5 modport A (output .P({r[3:1],r[0]}), input x, .S(R));
6 modport B (input .P(r[3:0]), output x);
7 endinterface
Verification Debug
278
8
9 module M2 ( interface i, output reg clk, input [31:0]
varInt);
10
11 always@(*) begin
12 clk = i.P[2];
13 i.x = varInt ;
14 end
15 endmodule
16
17 module M1 ( interface i);
18 always@(*) begin
19 i.P = i.x;
20 end
21 endmodule
22
23 module top;
24 reg CLK2;
25 wire [31:0] input2;
26 I i1 ();
27 M1 u1 (i1.A);
28 M2 u2 (i1.B, CLK2, input2);
29 assign input2[2] = CLK2;
30 endmodule
Verification Debug
279
The source signal top.u2.i.P[2] is the equivalent object of the input
signal top.i1.B.P[2]. This API uses top.u2.i.P[2] as another
input signal and then trace the loads. Therefore, the result
top.u2.clk is returned.
[traceDriver.tcl]
viaSetupL1Apps
Verification Debug
280
array set hdlSet {}
set fileHdl stdout
set hdl [npi_handle_by_name -name top.CLK2 -scope ""]
trace_driver $hdl $fileHdl
debExit
On the Verdi Tcl command entry, source the script and then the
following log are obtained on CASE1:
Verification Debug
281
npiRefObj, top.u2.i.P[2], {itf_port.v : 9}
------------------------------------------------------
As shown in the log, when the input signal is top.CLK2, the script
recursively traces through the SV interface, crossing the modport
port top.i1.B.P[2], and then obtains its driver top.i1.A.P[2].
Afterwards, the script follows the tracing loop to trace back to module
top.u1, crossing the signal top.u1.i.P[2]. It runs the same
behavior repeatedly until the duplicated signals are found.
Limitations
This enhancement only focuses on the SV interface port. The
npiRefObj of the reference port is not supported.
Verification Debug
282
Unified Verdi Debug Platform for Interactive and Post-
Simulation Debug
Verification Debug
283
Generate the Verdi KDB using VC Unified Compiler. For more
information, see Unified Compile Front End
Specify the -debug_access+<option> compile-time option on
the VCS command line. This option automatically picks up Novas
tab file and Novas PLI file and there is no need to pass these files
explicitly during compilation. For more information on this option,
see the VCS documentation.
Note:You can specify the -debug_access+all option to enable
the complete set of debug capabilities.
Enable the FSDB file dumping using the dumping tasks present
in the source file or at runtime using one of the following
commands from the UCLI command line:
dump -file <filename>.fsdb
fsdbDumpvars
Use Model
Rebuilding and Restarting Interactive Simulation Debug in Verdi
Verification Debug
284
Use Model
When executing the simv simulator executable, perform one of the
following steps to invoke Verdi or DVE within the interactive
simulation debug mode:
// invoke Verdi
%> simv <simv_options> -verdi [-verdi_opts
<verdi_options>]
%> simv <simv_options> gui=verdi [-verdi_opts
<verdi_options>]
// invoke DVE
%> simv <simv_options> gui=dve [-dve_opt
<dve_options>]
// invoke DVE
%> setenv SNPS_SIM_DEFAULT_GUI dve
%> simv <simv_options> gui [-dve_opt <dve_options>]
Verification Debug
285
You can perform interactive simulation from a directory that is
different from the compilation directory using the following
command:
<path of compilation directory>/<simv executable> -verdi
-i -simflow -simBin <simv_path/simv>
Verification Debug
286
Post-Simulation Debug Mode
Use Model
Limitations
Use Model
To automatically load the KDB compiled by Unified Compile, use the
following Verdi command-line options:
-simflow
Enables Verdi and its utilities to use the library mapping from the
synopsys_sim.setup file and also to import a design from KDB
library paths.
-simBin <simv_path/simv>
Specifies the path of the simv executable. This ensures that VCS
and Verdi have the same data from the synopsys_sim.setup
file.
For example,
Verification Debug
287
%> verdi simflow simBin <simv_path/simv> ssf
novas.fsdb
After specifying the path of simv, you can directly start the Verdi
Interactive Simulation Debug mode using the Tools Run
Simulation menu command in Verdi nTrace.
If a design contains SystemC and the default.ridb file exists
in the simv.daidir/ directory, the default.ridb file is also
loaded into the KDB for SystemC debugging.
When simflow and simBin options are used together, all
other options related to importing KDB are ignored.
If you are trying to perform post-simulation debug from a directory
different than the compilation directory, you must specify the
absolute physical path mapping in the synopsys_sim.setup
file.
-simdir <path of compilation directory> -top <top
module name>
Specifies the top-level module name to load a design in Verdi. You
can use these options if you do not want to load the design from
the real design top. For more information, see Unified Compile
Front End .
Limitations
Following are the limitations when performing power debug with
UPF:
Verification Debug
288
For example,
Verdi used to import unelaborated KDB from the disk and perform
design elaboration during loading when the GUI is invoked. Now,
Verdi offers an elaboration process that loads the design using the
Unified Compiler Front-End flow. Verdi elaborates the design and
saves the Elaboration database to the disk at batch time. You can
now reimport the elabDB file from the disk that speeds up invoking
of the GUI.
Use Model
Limitations
Verification Debug
289
Use Model
Verification Debug
290
The generated KDB and elabDB files are saved in the work.lib++
and kdb.elab++ directories. The work.lib++ directory is saved
in the current working directory and the kdb.elab++ directory is
saved in the simv.daidir directory.
For example,
// Example1:
%> simv <simv_options> -verdi [-verdi_opts
<verdi_options>]
// Example2:
%> simv <simv_options> gui=verdi [-verdi_opts
<verdi_options>]
Verification Debug
291
Generating elabDB Using the elabcom Utility
Loading Verdi Elaboration Database Into Verdi
For example,
Verification Debug
292
The generated KDB and elabDB are saved as work.lib++ and
kdb.elab++ directories. The work.lib++ directory is saved in
the current working directory and the kdb.elab++ directory is
saved under the simv.daidir directory.
You can also specify the path name of elabDB using the -elab
option. For example,
./myelab/mydesign.elab++.
Verification Debug
293
when creating elabDB using elabcom
%> elabcom lib work
Verification Debug
294
Limitations
Both Verdi Verilog and VHDL KDB library format are changed with
this release. Backward compatibility for this database version is
not available. You need to recompile your designs to create a new
Verdi KDB library.
The following runtime options are not supported:
- -dynaconfig
- -impConf
The netlistcom Verdi utility is not supported.
VHDL +vtop usage is not supported.
Loading Verdi elabDB in the Import GUI form is not supported.
Verification Debug
295
Attaching a Running Simulation in Verdi
Verification Debug
296
This section consists of the following subsections:
Prerequisites
Use Model
Limitations
Prerequisites
Verification Debug
297
Use Model
Verification Debug
298
Figure 6-16 Attach to Simulation Command
Verification Debug
299
- Shows all processes in the dialog box when you enable the
Show all simulation processes option.
- Filters all the columns texts when you specify a string in the text
filter field.
- Refreshes up-to-date processes in the current working machine
when you click the Refresh button.
3. When the selected simulation cannot be attached due to one of
the following situations, a warning message is displayed:
- When the selected process is not a valid simulation process
(not correct version or a suspended process)
- When the simulation is running in the GUI mode (either Verdi
or DVE)
- When the simulation is running in specman
Figure 6-18 Warning Message for Unable to Attach Selected Process
Verification Debug
300
Figure 6-19 Enabled Verdi Interactive Simulation Debug Mode
After the connection between simulation and Verdi is built, all frames
in Verdi Interactive Simulation Debug mode shows the
corresponding information for the current simulation state
accordingly.
Verification Debug
301
If the -l option is used to specify the log file in UCLI mode after
Verdi attaches to simv, the same log file is used to debug in Verdi.
If no log file is specified, the verdiLog/sim.log file is not
generated.
The following features are supported in Verdi:
- Restore State
- Checkpoint and Rewind
- Breakpoints
Verdi can only attach to one simulation process at a time.
Perform the following steps to launch Verdi using the UCLI command
line:
Verification Debug
302
Figure 6-20 Run Verdi in UCLI Command Mode
You can detach the simulation in Verdi and return back to the UCLI
command line mode (see the Detaching Verdi From Simulation
Process section for the usage).
Verification Debug
303
Set configurations in UCLI when the specified simulation stage/
error meets. Invoking Verdi on some simulation events is
supported.
Verification Debug
304
1. Use the Simulation Attach to Simulation command to invoke
the Attach to Simulation form (see Figure 6-21).
2. In the Attach to Simulation form, the attached process is marked
with the attached icon. Select the connected process and click
Detach button (see Figure 6-22).
Figure 6-22 Detach to Simulation Form
Limitations
If the simulation is not compiled with the -kdb option, Verdi cannot
load the design hierarchy automatically.
While attaching a simulation process in Verdi after you select a
simv process to attach from the dialog box, you need to press
enter when in UCLI terminal to accept the attaching.
The following features are not supported in Verdi after a simulation
is attached:
Verification Debug
305
- Restart
- Restore Session
The interactive simulation debug mode does not allow you to debug
backwards in time. When a simulation fails and issues an error, you
need to rerun the simulation to debug the problem by setting
checkpoints at different time intervals. While debugging a failure, you
cannot save the debug scenario and restore later at the same time.
If you need to perform what-if analysis or explore the past state, you
cannot go back in time as the future is destroyed. Also, there is no
provision to pass the debug session to another user (in a persistent
state form).
The following are the new VCS simulation control commands for
reverse executing the simulation in Verdi:
Verification Debug
306
- Run/Continue Reverse Next Reverse
- Step Reverse
- Step Out Reverse
- Step in Thread Reverse
- Step in Testbench Reverse
- Next in Thread Reverse
You can also easily reverse/advance the simulation to the previous/
next value assignment of a signal or a variable by invoking a
command for the selected one. For a DUT design, you can achieve
this by dumping all signals and using the traced information to figure
out where to go. For a testbench, this approach does not work. Also,
it should work without all signals traced. You can use this new feature
to go to the desired assignment of the object.
Furthermore, you can keep the future (for example, while reversing
a simulation, the time and the information generated from an active
point, Point A, to a previous point, Point B is termed as future). when
going back in simulation time during reverse debugging. The
following are the benefits to keep the future:
Verification Debug
307
During the debugging, you can bookmark interesting points using
checkpoints and later quickly return to them even after reverse
executing to time before these checkpoints. The checkpoints (in
the future) are preserved and you can easily go to the recorded
future checkpoint from the past. For example, consider that there
are four checkpoints, A,B,C, and D. If you remove the checkpoint
C, then the values at the checkpoint C are preserved. This allows
you to go back to the checkpoint C at a later point during the
debugging process.
The following sections provide a detailed description of these
features:
Prerequisite
Use Model
Using Reverse Simulation Control Commands
Going to Previous/Next Value Assignment
Prerequisite
Verification Debug
308
Use Model
% simv verdi2
Verification Debug
309
1. Use the Tools Preferences command to invoke the
Preferences form and select the Interactive Debug Reverse
Debug page.
2. Enable the Reverse Debug option.
Figure 6-23 Enable Reverse Debug
Verification Debug
310
Using Reverse Simulation Control Commands
As shown in Figure 6-25 and Figure 6-26, you can use the
commands by clicking the command icons or selecting them from
the Simulation command menu to direct the simulator how to
reverse execute the program.
Verification Debug
311
Figure 6-26 Simulation Control Commands in Simulation Command Menu
Verification Debug
312
Run/Continue Reverse Simulation Control Command
You can specify the amount of time and use the Run/Continue
Reverse command (by clicking the icon or selecting the
Simulation Run/Continue Reverse command) to go back in
time for the specified amount of time, as the same time entry field
used by the Run/Continue command (see Figure 6-27). All the
current breakpoints are respected and the simulation stops at the
most recent (considered back from the current execution state)
breakpoint hit.
When the time entry field is empty and no breakpoints are hit, the
simulation is rewound back to the start. If the reverse debug feature
is enabled some time after the simulation starts, using the Run/
Continue Reverse command (as well as other reverse commands)
stops at this point. In this case, a confirmation dialog box is displayed
with the Rewind to first checkpoint at time <time>?
message.
Verification Debug
313
Step and Next Reverse Simulation Control Commands
The following reverse commands are available to reverse the
simulation by clicking the command icons or selecting them from the
Simulation command menu:
Next Reverse: Goes back one SystemVerilog line that steps over
task/function calls. Eventually, it might stop on a breakpoint inside
the task/function called at the previous line.
Step Reverse: Goes back one SystemVerilog source code line.
Step Out Reverse: Goes back to the source code line where the
current function has been called.
Next in Thread Reverse: Goes back one source code line in the
current thread that steps over task/function calls.
Step in Thread Reverse: Goes back one source code line in the
current thread.
Step in Testbench Reverse: Goes back one source code line in
the testbench code.
In the source code frame, you can use the Reverse Run to Source
Line right-click command to reverse the simulation to the selected
source line.
Verification Debug
314
Figure 6-28 Reverse Run to Source Line Command
Verification Debug
315
next reverse Next Reverse
next reverse thread Next in Thread Reverse
next reverse end Step Out Reverse
run reverse Run/Continue Reverse
run reverse [time [unit]] Run/Continue Reverse with the specified
time
run reverse -absolute | relative Run/Continue Reverse with the specified
<time> absolute or related time
run reverse -line <line#> [-file Run/Continue Reverse to the specified
<file>] line in the specified source code file
[-instance <nid>]
[-thread <tid>]
For example, execute the following command in the Verdi
Interactive_Console frame:
Verification Debug
316
Going to Previous/Next Value Assignment
When you want to find out the previous assignment for a signal or
variable, you can select the object in the Watch, Local, or source
code frames and invoke the Go to Previous Value Assignment
right-click option or click the icon to reverse the simulation to the
assignment point.
Verification Debug
317
Figure 6-31 Invoke Go to Previous Value Assignment
In Figure 6-32, you can see the simulation time is reversed to 170 ns
where the previous assignment of the read_write variable
happened. The value of the read_write variable is changed to
Write. You can also see the debug cursor pointing to line 186 of the
ubus_slave_monitor.sv file in the source code frame, which is
the current debug position.
Verification Debug
318
Figure 6-32 After Go to Previous Value Assignment
Limitations
Verification Debug
319
- Performing the file seeking operations, and then writing at a
new position (that is, it is assumed that simulation only
appends data to the output files)
Simulation with Specman is not supported
Analog-digital co-simulation (using NanoSim) is not supported.
The Reverse debug commands are not supported for VHDL
source code. For example, using the Step Reverse command
moves to the previous Verilog source code line, ignoring all VHDL
code in between
When the design is compiled with the -simprofile switch for
simulation profiling, reverse debug is not possible.
The following are the limitations with the GO to Previous/Next
Assignment feature:
Verification Debug
320
Unified UCLI Command for FSDB Dumping
You can also use the dump command to open multiple FSDB dump
files simultaneously and manage them individually.
Verification Debug
321
Default Dump Type
In the VC mode, the default GUI is Verdi and the default dump type
is FSDB. In the VCS mode, the default GUI is DVE and the default
dump type is VPD.
You can use the following environment variable to control both the
default dump type (FSDB, VPD) and GUI (Verdi, DVE) in the VCS
mode and the VC mode using the following command:
In the VCS mode, use the following environment variable to set the
default GUI as Verdi and the default dump type as FSDB:
Verification Debug
322
Use Model
The following steps describe the use model for FSDB dumping:
or
Note:
If you use -debug, -debug_pp, and -debug_all options,
you must specify novas.tab and pli.a files on the VCS
command line. The -debug_access option automatically sets
the novas.tab and pli.a files.
Verification Debug
323
ucli% dump add/-depth 0
If multiple dump files are open, you must specify the -fid
argument with the dump commands that follow the second dump
-file command.
ucli% dump -file test1.fsdb (This command returns
FSDB1)
dump -file
dump -add
dump -close
dump -deltaCycle
dump -flush
dump -switch
dump -power
dump -powerstate
Verification Debug
324
dump -file
Opens a specific type of file for dumping.
Syntax:
This command returns file ID, <fid>, which is a unique string that
identifies the opened file.
For example,
dump -add
Adds design objects to the dump file.
Syntax:
Note:
You must specify the -fid argument, if multiple dump files are
open, else an error message is issued.
Verification Debug
325
For a dump file of the FSDB type,
For example,
The dump -add command dumps the signals in the default dump
file.
For example,
Dumps signals in the default dump file. The default dump file for
FSDB is inter.fsdb.
Verification Debug
326
The -fid argument must specify a valid FSDB ID, else an error
message is issued.
For example,
Table 6-7 lists the options supported for the -fsdb_opt argument.
For more information on these options, see the Linking Novas Files
with Simulators and Enabling FSDB Dumping User Guide.
Verification Debug
327
Option Description
+sva Dumps assertions
+Reg_Only Dumps only reg type signals
+IO_Only Dumps only IO port signals
+by_file=<filename> File to specify objects to add
+all Dumps memories, MDA signals, structs, unions, pow-
er, and packed structs
dump -close
Closes the opened dump files.
Syntax:
dump -close
You can use the dump -close command to close all opened dump
files. The FSDB API does not support the closing of specific open
FSDB files.
dump -deltaCycle
Enables or disables the delta cycle dumping.
Syntax:
For FSDB dump files, you must execute this command before
dumping starts.
Verification Debug
328
Note:
You must specify file ID, if multiple dump files are open, else an
error message is issued.
dump -flush
Forces the contents of the value change buffer to be written to the
disk file.
Syntax:
dump -switch
Closes the current file and opens a new file with the given name. The
new file retains the hierarchy of the closed file.
Syntax:
Note:
- You must specify the file ID if multiple dump files are open, else
an error message is issued.
- The new file inherits the file ID of the closed file.
Verification Debug
329
dump -power
Globally enables or disables the dumping of the low power scopes
and nodes.
Syntax:
Note:
You must specify file ID if multiple dump files are open, else an
error message is issued.
dump -powerstate
Globally enables or disables the dumping of the low power domain
state signals, PST signals, and PST supply signals.
Syntax:
Verification Debug
330
Note:
You must specify file ID, if multiple dump files are open, else an
error message is issued.
The following are the new UCLI dump options that support FSDB
dumping:
dump -suppress_file
dump -suppress_instance
dump -enable
dump -disable
dump -glitch
dump -opened
dump -suppress_file
Specifies scopes in a file that are not dumped into the FSDB file.
Syntax:
Note:
- You must use this command before dumping a file. An error
message is issued, if this command is specified after the dump
-add command.
Verification Debug
331
- This command is supported only for the FSDB dump file and is
global to all FSDB files.
dump -suppress_instance
Specifies the list of instances that is not dumped into the FSDB file.
Syntax:
Note:
- You must use this command before dumping a file. An error
message is issued, if this command is specified after the dump
-add command.
- This command is supported only for the FSDB dump file and is
global to all FSDB files.
dump -enable
Enables the dumping again, if it is disabled.
Syntax:
Verification Debug
332
Note:
- You must specify file ID, if multiple dump files are open, else
an error message is issued.
- This command has more precedence over the
$fsdbDumpvars system task.
dump -disable
Disables the dumping of all dumped signals.
Syntax:
Note:
- You must specify the -fid argument if multiple dump files are
open, else an error message is issued.
- This command has more precedence over the
$fsdbDumpvars system task.
Verification Debug
333
dump -glitch
Enables or disables the dumping of glitches.
Syntax:
Note:
You must set the NOVAS_FSDB_ENV_MAX_GLITCH_NUM
environment variable to 0 to enable the dumping of glitches in the
FSDB file.
dump -opened
Displays all opened dump files and their file type.
Syntax:
dump -opened
VPD0 inter.vpd
Verification Debug
334
FSDB1 novas.fsdb
EVCD2 verilog.dump
Limitations
Verification Debug
335
AMS-Debug Integrations
Verification Debug
336
Unified Dumping of Analog Signals in FSDB in VCS-
CustomSim Cosimulation Flow
You can now use the msv, UCLI dump option to enable dumping of
the analog signals in the FSDB file.
Use Model
Usage Example
Use Model
Verification Debug
337
Enabling Dumping of the Analog/Digital Signals in the FSDB File
Enabling Merge Dumping
1. You can use one of the following ways to invoke Verdi dumper on
analog signals:
ucli% dump -msv[=on|off]
OR
Note:
-You can use the -msv option to enable (on) or disable (off)
dumping of analog signals throughout the simulation. By
default, this option is enabled if on or off is not specified.
-The analog targets are ignored if the -msv option is not
specified.
-Once an analog scope is enabled with the dump -msv on
command, it cannot be disabled for dumping throughout the
simulation using the dump -msv off command.
Verification Debug
338
-If -type is not specified, you can use the following command
to set the default dump type as FSDB:
% setenv SNPS_SIM_DEFAULT_GUI verdi
This example dumps all the analog and digital signals of the
top.a scope.
Note:
You must specify the -fid argument if multiple dump files are
open, else VCS issues an error message.
This example dumps all the digital signals of the top.U0 scope
and all the hierarchies under it, excluding all analog signals in the
hierarchy.
Verification Debug
339
For more information on the dump -add and dump -file UCLI
commands, see Integrating VCS MX with Verdi chapter in the VCS
User Guide.
This command dumps all the digital and analog signals in the target
FSDB file. If the target FSDB file is not specified, then both analog
and digital signals are dumped in the default FSDB file
novas.fsdb.
Note:
If any CustomSim probe command is invoked on a SPICE signal,
its wave is dumped in the target FSDB file. For more information
on the CustomSim configuration commands, refer to the
CustomSim Command Reference User Guide.
Usage Example
If the -msv option is set to on, the dump -add a.b.c -type
command exhibits the following behavior:
Verification Debug
340
If a.b.c is an analog sub-circuit, dumps all the ports and internal
nets of the sub-circuit
If a.b.c is a digital net, dumps its digital value
If a.b.c is a digital instance, dumps the signal inside this scope
If a.b.c is a digital or analog instance where c contains mixed-
signal hierarchies, then both digital and analog signals of c and
its hierarchies are dumped.
Prerequisites
Use Model
Interactive Simulation Debugging With Mixed-Signal Design
Limitations
Verification Debug
341
Prerequisites
Use Model
1. Refer to the CustomSim User Guide for details on the configuration commands.
2. Refer to the Mixed-Signal Simulation User Guide for details on the compilation and simulation options.
Verification Debug
342
Compiling With Verdi
Only the Import Design from Library feature is supported to load
you mixed-signal design into the Verdi platform. Therefore, you need
to compile your design using the Verdi KDB with both digital and
analog hierarchy/signals first. The spicom compiler allows you to
compile the analog modules.
Perform the following steps to compile and load your design into
Verdi.
Verification Debug
343
- -runfile: Loads the simulation runfile that is used during
simulation. spicom automatically compiles the SPICE and AD
files recorded in the runfile.
4. Add the -msv option into the Verdi command line to enable the
mixed-signal debug features. For example,
%> verdi top <your_design_top> -msv
Verification Debug
344
Compiling With SPICE Unified Front-End Flow
Earlier while using VCS, you need to parse the analog mixed-signal
designs with Spicom to debug it with Verdi.
VCS internally invokes spicom with this command line to analyze the
vcsAD.init file, and the KDB model of SPICE is generated.
Verification Debug
345
3. Use the Tools Run Simulation command to enable interactive
simulation debug mode.
You are now able to perform interactive simulation debugging with
your mixed-signal design. However, the simulation is controlled by
VCS and there are some limitations in VCS/CUSTOMSIM.
Verification Debug
346
Interactive Simulation Debugging With Mixed-Signal
Design
You can also drag and drop a SPICE instance into the Watch tab. All
analog ports and nodes which are defined in this SPICE instance are
added to the Watch tab. For example, jj.inst1 is a SPICE
instance, you can drag and drop all its ports and nodes into the
Watch tab.
Verification Debug
347
The following information is provided for analog variables:
Set Breakpoint
Set Radix
Add Object to Watch Tab
Show Declaration, Show in Class Browser, View Object
References
Dump Object to FSDB file, Dump, Add Object to Waveform
Verification Debug
348
Annotation Value
Current voltage values can be annotated to the analog signals on the
source code and nSchema frames by enabling the Source Active
Annotation option.
Drag and drop an analog signal from the source code frame to
the nWave frame.
Use the Add Signal(s) to Waveform right-click option for a
selected analog signal in Verdi main window.
Use the Dump to FSDB File right-click option for selected analog
signals and instances in Verdi main window.
When analog signals are selected, voltage values of the selected
analog signals are dumped. When analog instances are selected,
voltage values of all analog signals under the selected analog
instances are dumped.
Verification Debug
349
You can use the nWave File Restore Signals command and
select the stored *.rc file to dump batch signals stored in the
specified *.rc file.
The following fields are provided in the invoked Force Value dialog
box for SPICE signals:
Signal Name
The signal name is specified automatically when this dialog box
is invoked using the right-click option. You can also drag and drop
a signal to the Signal Name field to specify the signal name.
Value
Specifies the forced voltage value in Volt.
Slope
Specifies the slope value in Seconds/Volt. The slope value is 1ps/
Volt, by default. You can also specify time unit, such as 1ms, 1us,
1s and so on.
Note:
If the unit is not specified in this field, seconds is used as the unit.
Verification Debug
350
Save/Restore the Simulation Session/State
You can use save or restore the simulation session/state for your
mixed-signal design.
Note:
Only the voltage values of analog signals in form of v() are
supported to be restored.
Interactive Console
You can specify CustomSim interactive command in the Interactive
Console frame by specifying ace before the command. However,
some CustomSim interactive commands that affects the simulation
progress are disabled.
Limitations
Verification Debug
351
- Some of the menu commands and the right-click commands
are disabled
Watch tab
Annotation value
Forcing value
The force/release icons are not shown for analog signals in the
nWave frame.
CustomSim/PLI does not dump force events for analog signals
into the FSDB file.
Verification Debug
352
Unified Transaction Debug With Native Verdi Protocol
Analyzer
Verification Debug
353
OCP VIP
PCIe VIP
MIPI VIPs
- DigRF, M-PHY, UFS, UniPro, and SoundWire
Memory VIPs
- DDR and LPDDR
SWD VIP
UART VIP
USB PD and USB VIP
Prerequisite
Capture the VIP transaction data during simulation and store the
data in an FSDB file for interactive debug feature validation.
Use Model
Verification Debug
354
The Protocol Analyzer window appears as shown in Figure 6-33.
Hierarchy Tree
Hierarchy Tree enables you to view different protocol layers and the
exact number of transactions in each layer which are grouped using
the protocol definition file.
Verification Debug
355
Quick Filter
Using Quick Filter, you can filter the added Hierarchy Tree contents
by setting the filter condition and view only the required streams by
applying the right filter.
Protocols
The Protocols tab displays all available VIPs installed within
DESIGNWARE_HOME or VC_HOME. The Protocols tab displays the list
of protocols from the custom location where Protocol Definition files
are present for the proprietary protocol. To set the proprietary
protocol location, use the PA_CUSTOM_VIP_PATH environment
variable.
Note:
You can view protocol- specific Class Reference Guide and User
Guide from the Protocols tab Hierarchy Tree.
Global Pane
The Global pane enables you to select a particular viewable area
from the Global pane and view the selected area in the Object pane.
In the Global pane, the default visible range is the full length of the
simulation. You can select the visible range and view the range
accordingly in the Object pane.
Verification Debug
356
Object Pane
The Object pane displays the objects that belong to different layers
within the simulation. Similar to the Protocol Analyzer object, the
Object pane reads the object color, object name, and column name
from the protocol definition file and displays these properties for each
object. Also, you can change the color and override the color
selection for each object with Preference settings.
Details
The Details tab displays the attribute and value for the selected
object. The Details tab updates the attribute and value details when
the simulation stops during interactive debug. You can use the filter
to search the desired attributes and values.
Call Stack
The Call Stack tab includes the File Name and Line columns to
display the complete call stack of the selected object. You can check
the call hierarchy. If the class design is loaded into nTrace, you can
double-click the particular call stack and view the corresponding call
stack code in nTrace.
Verification Debug
357
Search Results
The Search Results tab displays all the matching search criteria
objects. You can traverse through the objects to find out details of
any selected object. Search results get updated with the matching
search criteria if the simulator stops during interactive debug.
Limitation
Verification Debug
358
In a Memory VIP, the protocol-level transactions and memory actions
are stored in an FSDB file and the .mempa file respectively. The
Memory Server can be configured to record all memory actions to
view the memory-related data in the Verdi Protocol Analyzer. With
the information recorded by the Memory Server, you can determine
the value of any memory address at any time during simulation.
Prerequisite
Use Model
Limitations
Verification Debug
359
Prerequisite
Use Model
Verification Debug
360
Figure 6-34 Memory Aware Debug Interface
Verification Debug
361
Detail View
The Detail view displays attributes and values associated with the
most recent memory action for a selected memory address.
History View
The History view enables you to display all memory actions that have
been applied to a selected address for the specified time.
Summary View
The Summary view displays memory actions and memory errors for
the selected address.
Verification Debug
362
Limitations
Verification Debug
363
Analyzer SystemVerilog API supports the components that can
generate complex (hierarchical) protocol-style transactions as well
as components that incorporate memory operations (including
complex memory operations, such as front-door and back-door
access methods).
Prerequisite
Use Model
Verification Debug
364
Prerequisite
Use Model
Verification Debug
365
Figure 6-35 VC APPs Protocol Analyzer Integration process
You must capture the protocol-related data along with other design
information, such as waveforms, source code, stack traces, into an
FSDB file as shown in Figure 6-35.
Verification Debug
366
Figure 6-36 System Topology With Integration of Custom VIPs
Verification Debug
367
Capturing Protocol Data During Simulation
Perform the following steps to capture protocol-related data:
Verification Debug
368
Figure 6-37 SystemVerilog Code Annotation Flow
Verification Debug
369
Note:
To validate the structure of protocol extension definition, set the
PA_CUSTOM_VIP_PATH environment variable and examine the
protocol definition in the Protocols tab of Verdi Protocol Analyzer.
Verification Debug
370
The following are the key features of the Performance Analyzer:
Verification Debug
371
The section consists of the following subsections:
Verification Debug
372
The left region contains the Hierarchy Tree pane that displays
the instance hierarchy, protocol metrics, and performance results.
The middle region contains the Performance Report pane that
displays the performance report.
The right region contains the Details pane that shows the details
associated with the selected metric result.
Figure 6-39 Performance Analyzer Default Layout
Verification Debug
373
Hierarchy Tree Pane
The Hierarchy Tree pane contains the Hierarchy Tree, Metrics, and
Results tabs.
Verification Debug
374
Show in Result View: Shows the selected instance in the result
view.
Show Report: Evaluates the enabled performance metrics for
the selected instances and displays the performance report.
Show Report in New Window: Evaluates the enabled
performance metrics for the selected instances and displays the
performance report in a new Performance Analyzer frame.
Only one performance report is displayed in the new performance
analyzer frame. You can open the Performance Report in a new
window using the Show Report in New Window command.
Metrics Tab
The Metrics tab displays the metrics and associated constraints for
all protocols in the design. Even if there are multiple instances of the
same protocol in the design, there is still only one root node for that
protocol. This tab allows you to enable/disable metrics, define/edit
custom metrics and constraints, or add/ change/remove metric
constraints.
Verification Debug
375
Figure 6-41 Metrics Tab
For each protocol, the tree of performance metrics has two sub-
nodes one node for the instance performance metrics and the
other node for the multi-instance performance metrics. The
corresponding metrics appear as leaf-level tree nodes within each of
these sub-nodes.
Verification Debug
376
Figure 6-42 Enable Performance Metrics by Clicking Check Box
Verification Debug
377
Set Chart: Displays a dialog to set the chart option for the selected
metric.
Save Configuration: Saves the current metric/constraint
configuration into a Tcl file.
Load Configuration: Loads a metric/constraint configuration
from a Tcl file.
Reset Constraint: Resets the constraints for the protocol of the
selected metric. You are prompted to confirm the operation.
Reset Configuration: Resets both metrics and constraints for
the protocol of the selected metric. You are prompted to confirm
the operation.
If the metric definition contains any syntax errors, a warning
message is displayed when you attempt to create or modify the
metric.
Verification Debug
378
Figure 6-43 Add/Edit Metric Form
In the Metrics tab, double-click the Min and Max columns of the
metric to set the minimal and maximal constraint for that metric.
The Set Chart command can be used to set the metric display chart
option.
Verification Debug
379
Figure 6-45 Set Chart Type Form
Results Tab
The Results tab is a tree view that displays the performance
analysis results. The root folder for the tree is the protocol name.
This folder contains a sub-item that contains the results of evaluating
all multi-instance metrics and separate sub-items for each instance
that was evaluated.
The next level in the tree hierarchy displays the individual metrics
(instance or multi-instance) that have been evaluated. Constraint
violations are indicated with an alternate background color for the
violating metrics.
Verification Debug
380
Figure 6-46 Results Tab
The Count column shows the number of results generated for the
metric. If the runtime error occurs when evaluating the metric, NA is
shown and the tip provides details of the error.
Verification Debug
381
The following right-click commands are available in the Results tab:
The first section of the report contains general information about the
performance evaluation, such as a FSDB file, selected instances,
metrics that have been evaluated, and any constraint violations.
Verification Debug
382
A performance metric can generate a result that has only one record
or contains multiple records. The result can also have only one
column or can include multiple columns. Note that if a performance
result has multiple columns, the first column is taken as the value of
the metric.
For a metric result with only one record, the result is shown as a
label.
For the metric result with multiple records, the result is shown either
as a bar chart or as a line chart. If there are constraints associated
with the metric, the constraint values are also displayed.
Verification Debug
383
Use the middle button of mouse to scroll up/down or to zoom in/out
the chart. To move the chart left and right, drag the mouse left and
right. The scroll bar can also be used to move the chart left/right and
to zoom in and out the chart.
For line/bar chart, some of the details may be lost, if there are too
many items in the visible range. As some of the date items may
overlap, zooming in the chart for several times makes all items in the
visible range visible.
For pie chart, only the top ten items are shown in separate slices.
Other items are grouped as one item with the name others.
Verification Debug
384
Figure 6-52 Pie Chart of Performance Report
Verification Debug
385
Figure 6-53 Performance Report - Instance Section
Verification Debug
386
Figure 6-54 Performance Report - Summary Section
Verification Debug
387
Figure 6-55 Performance in CSV Format
Details Pane
For any metric result selected in the Performance Report pane, the
result data and any other data specified in the SQL metric expression
are shown in the Details pane. Metric constraint violations are also
annotated in this pane.
Details Tab
The Details tab displays the result data for any metric result selected
in the performance report pane and includes all data selected in the
SQL metric expression.
Verification Debug
388
Figure 6-56 Details Tab
The first column of the table displays the metric result. Any vector
result (a result that has multiple records) can be shown as a bar chart
in the HTML report using the values from the first column as the data
for the y-axis and the values from the second column as the data for
the x-axis.
Verification Debug
389
Summary of Usage
Verification Debug
390
Optimized Performance of Gate-Level Designs Using
Native FSDB Gates
Note:
This feature is supported with FSDB Reader 5.2 (for users of
FSDB reader API). If the API libraries of FSDB Reader are used
to read the FSDB file with a new format, a Verdi license is required.
Verification Debug
391
Use Model
Limitations
Use Model
If your design includes force events, you need to enable VCS force
capability using -debug, -debug_all, or -debug_access+f
options during compilation.
For example,
Verification Debug
392
Limitations
Verification Debug
393
7
Closing Coverage Gaps 1
For a typical SoC design, achieving coverage closure is a crucial
requirement. Coverage metrics provide a measurement of
correctness and completeness of a simulation test environment.
However, identifying which uncovered targets are actually
achievable is extremely painful and time consuming. Verification
engineers might need to reiterate debug cycle to close some targets
that are unreachable in a design.
VC Apps provides NPI Coverage APIs. The APIs are used to read
coverage database. The NPI coverage objects include: assert,
testbench, and power coverage.
This format describes how to merge the coverage data among two
or more instances that are defined in the same module. The merged
coverage data are saved to the destination instance. The instance
list is a comma-separated list of full names. It can also be a wildcard
character *. This means that all instances are merged with the same
defined module name.
Use Model
Object Diagram
APIs for C Interface
APIs for Tcl Interface
Use Model
Two types of use models are available for NPI Coverage APIs. The
first one is the database-based use model with the metric handle
from the database. The line, branch, toggle, fsm, condition, and
assert coverage database belong to the database-based use model.
The second one is the test-based use model with the metric handle
from the test. The testbench and power coverage belong to the test-
based use model.
Object Diagram
The following are the object diagrams of the NPI Coverage Model:
Assert Metric
Testbench Metric
Power Metric
The following are the details of the object diagram of the assert
metric:
Testbench Metric
The testbench metric includes the coverage information to monitor
user-specified expressions during simulation.
The following are the details of the object diagram of the testbench
metric:
The following are the details of the object diagram of the power
metric:
The following are the APIs of NPI Coverage Model for the C
interface:
npi_cov_handle_by_name
Syntax:
npiCovHandle npi_cov_handle_by_name( char *name,
npiCovHandle scope );
Description:
Obtains instance by full hierarchical name and database.
Parameters:
- name: Specifies the full hierarchical name of the instance.
- scope: Specifies the database handle.
Return:
On success, the target handle is returned.
On failure, a null pointer is returned.
Example:
npiCovHandle db1 = npi_cov_open("simv1.vdb");
npiCovHandle db2 = npi_cov_open("simv2.vdb");
npi_cov_merge_test
Syntax:
npiCovHandle npi_cov_merge_test ( npiCovHandle dstTest,
npiCovHandle srcTest, const NPI_BYTE8 *mapfile = NULL );
Description:
Merges the code coverage from the source test to the destination
test by mapping file.
Parameters:
- dstTest: Specifies the destination test handle.
- srcTest: Specifies the source test handle.
- mapfile: Specifies the hierarchy mapping file name. If
dstTest and srcTest belong to different databases, this
argument is required; otherwise, it can be NULL.
Return:
The merged test handle that is equal to destination test handle.
Mapfile Format:
{MODULE: [module name]
INSTANCE:
{SRC: [instance list]
DST: [instance list]
}
}
The following are the APIs of NPI Coverage Model for the Tcl
interface:
npi_cov_handle_by_name
Syntax:
npi_cov_handle_by_name -name Name -scope Scope
Description:
Obtains instance by full hierarchical name and database.
Parameters:
- Name: Specifies the full hierarchical name of the instance.
- Scope: Specifies the database handle.
Return:
On success, the target handle is returned.
npi_cov_merge_test
Syntax:
npi_cov_merge_test -dest DestTest -src SrcTest -mapfile
Mapfile
Description:
Merges the code coverage from the source test to the destination
test by mapping file.
Parameters:
- DestTest: Specifies the destination test handle.
- SrcTest: Specifies the source test handle.
- Mapfile: Specifies the hierarchy mapping file name. If Dest
and Src belong to different databases, this argument is
required; otherwise, it can be "".
Use Model
The use model for this feature is explained in the following sections:
save_covdb
[-new <covDbName>]
[-update_existing]
[status <list-of-status-attributes>]
where,
GUI Updates
The coverage flow can be enabled in VC Formal Coverage Analyzer
using the following commands from vc_static_shell (in the
interactive mode) or using the f <command>.tcl option from
vc_static_shell:
Build Command:
read_file cov <metric_type> -single_step top
<top_module_name> -vcs { <vcs_command_line> }
Clock/Reset Settings:
create_clock <clockName> -period <timePeriod>
sim_run <no_of_clock_cycles_to_run>
Reporting Command:
report_cov
GUI-Based Debugging:
view_activity
Use Model
The use model for this feature is explained in the following sections:
int save_cov_exclusion
[-file<elfileName>]
[-append]
where,
int save_covdb
[-new <covDbName>]
[-update_existing]
[-status <list-of-status-attributes>]
[-line_intent]
[-no_line_intent]
where,
Note:
The argument is optional. If you do not specify, it dumps out all
coverage metrics.
Symbols C
+fsdb+gate 392 cancel task 129
+UVM_LOG_RECORD 192 Canceling Queued/Running Tasks 129
+UVM_TR_RECORD 191 Clock 105
+UVM_VERDI_TRACE 191 cov 412, 417
Coverage Goal 410
Covered 410
A create_clock 413
Activity View 82, 151 create_reset 413
Adding/Edit 103
Alive Workers Status 127
Analog Mixed-Signal (AMS) Interactive D
Simulation Debugging 341 depthCounts 135
-ad 342 depthVsTime 135, 139
CUSTOMSIM 346
dump 321
CustomSim 351
Dumping Analog Signals into FSDB 349
set_waveform_option -format fsdb 342
append 415
Assume 102 E
Automated Coverage Closure Flow 411 elabDB 289
-elab 294
-gui/-verdi/-gui=verdi 291, 292
B kdb=elab 290
Bounded Coverage Analysis 140 engine 135, 138
explore_end 114
Extending Traces 112
419
F J
Fast Signal Database 82 jobId 135, 138
-fastpartcomp 228 jobStatus 136
-fastpartcomp=j4 229
file 415
Finding RTL Name 66
K
FPV Enhancements 66, 87 -kdb 217
FSM 140
fsm_state 412 L
fsm_transition 412
line_intent 412, 416, 417
Functions 106
list 134, 136, 138
check_ 124
M
G map_by_name 151
Goal View 132
map_out_product 155
goalId 135
Menu 86
Grid Configuration 125
Message ID 84
Grid Control 129
Grid Functionality 124
Grid Report 126 N
Grid submission 124 new 412, 417
Grid Submission Error Report 126 no_line_intent 412, 416, 417
no_summary 133, 137
non-record-type 85
H -ntb_opts uvm 188
host 138
P
I pc.optcfg 227
Importing SPICE Design 343
primary property 102
-runfile 344
PrimaryNWave 110
spicom 343
Progress Reporting 129
Importing SPICE Design-lib 344
Property Form 103
Importing SPICE Design-mvsim 344
property ID 84
Importing SPICE Design-topname 344
-integ 230
420
Q -simflow 218
Solver Job View 136
qualify 203
solver_task_id 129
Quit 114
Source Viewer 29
spec 154
R status 135, 138, 412, 417
read_file 413 subtype 136
reason 138
Replot 102
report_fml_engines 131
T
targets 416
report_fml_jobs 131
Toggle 85
report_fv 132
Trigger Condition 105
report_seq 132
type 125
repot_orc_engines 139
Results Reporting 151
reverse debugging 306 U
-debug_access+all+reverse 308
Uncoverable 410
reverse next 306
update_existing 412, 417
simulation control commands for reverse
executing simulation 306
RMB 66, 86 V
VC Static Menu 80
S VC_STATIC_HOME 80
save_cov_exclusion 414, 415 vcsmxpcvlog 229
save_covdb 411, 414, 416 vcsmxpipvlog 229
Schematic 82 vcspcvlog 228
SEQ 87 VCst Instance 154
SEQ Debug Flow 149 vcst_command.log 83
seq_top 154 verbose 135
set_app_var 413 Verdi 82
set_grid_usage 125 Verdi Knowledge Database 82
sim_run 413 view_activity 151, 414
421
422