In Vivado simulator, support for some of the commonly used test bench features have been added, as shown in the following table:
Primary Construct | Secondary Construct | LRM Section | Status |
---|---|---|---|
String data type | 6.16 | Supported | |
String operators (table 6-9 of IEEE 1800-2012) | 6.16 | Supported | |
Len() | 6.16.1 | Supported | |
Putc() | 6.16.2 | Supported | |
Getc() | 6.16.3 | Supported | |
Toupper() | 6.16.4 | Supported | |
Tolower() | 6.16.5 | Supported | |
Compare | 6.16.6 | Supported | |
Icompare() | 6.16.7 | Supported | |
Substr() | 6.16.8 | Supported | |
Atoi(), atohex(), atooct(), atobin() | 6.16.9 | Supported | |
Atoreal() | 6.16.10 | Supported | |
Itoa() | 6.16.11 | Supported | |
Hextoa() | 6.16.12 | Supported | |
Octtoa() | 6.16.13 | Supported | |
Bintoa() | 6.16.14 | Supported | |
Realtoa() | 6.16.15 | Supported | |
Dynamic Array | 7.5 | Supported | |
Dynamic array new | 7.5.1 | Supported | |
Size | 7.5.2 | Supported | |
Delete | 7.5.3 | Supported | |
Associative Array | 7.8 | Supported | |
Wildcard index | 7.8.1 | Supported | |
String index | 7.8.2 | Supported | |
Class index | 7.8.3 | Supported | |
Integral index | 7.8.4 | Supported | |
Other user-defined types | 7.8.5 | Supported | |
Accessing invalid index | 7.8.6 | Supported | |
Associative array methods | 7.9 | Supported | |
Num() and Size() | 7.9.1 | Supported | |
Delete() | 7.9.2 | Supported | |
Exists() | 7.9.3 | Supported | |
First() | 7.9.4 | Supported | |
Last() | 7.9.5 | Supported | |
Next() | 7.9.6 | Supported | |
Prev() | 7.9.7 | Supported | |
Arguments to traversal Method | 7.9.8 | Supported | |
Associative array assignment | 7.9.9 | Supported | |
Associative array arguments | 7.9.10 | Supported | |
Associative Array literals | 7.9.11 | Supported | |
Queue | 7.10 | Supported | |
Queue operators | 7.10.1 | Supported | |
Queue methods | 7.10.2 | Supported | |
Size() | 7.10.2.1 | Supported | |
Insert() | 7.10.2.2 | Supported | |
Delete() | 7.10.2.3 | Supported | |
Pop_front() | 7.10.2.4 | Supported | |
Pop_back() | 7.10.2.5 | Supported | |
Push_front() | 7.10.2.6 | Supported | |
Push_back() | 7.10.2.7 | Supported | |
Persistence of references to elements of a queue | 7.10.3 | Supported | |
Updating a queue using assignment and unpacked array concatenation | 7.10.4 | Supported | |
Bounded queues | 7.10.5 | Supported | |
Class | 8 | Supported | |
Class General | 8.1 | Supported | |
Overviews | 8.2 | Supported | |
Syntax | 8.3 | Supported | |
Objects(Class instance) | 8.4 | Supported | |
Object properties and object parameter data | 8.5 | Supported | |
Object methods | 8.6 | Supported | |
Constructors | 8.7 | Supported | |
Static class properties | 8.8 | Supported | |
Static methods | 8.9 | Supported | |
This | 8.10 | Supported | |
Assignment, renaming, and copying | 8.11 | Supported | |
Inheritance and subclasses | 8.12 | Supported | |
Overridden members | 8.13 | Supported | |
Super | 8.14 | Supported | |
Casting | 8.15 | Supported | |
Chaining constructors | 8.16 | Supported | |
Data hiding and encapsulation | 8.17 | Supported | |
Constant class properties | 8.18 | Supported | |
Virtual methods | 8.19 | Supported | |
Abstract classes and pure virtual methods | 8.20 | Supported | |
Polymorphism: dynamic method lookup | 8.21 | Supported | |
Class scope resolution operator :: | 8.22 | Supported | |
Out-of-block declarations | 8.23 | Supported | |
Parameterized classes | 8.24 | Supported | |
Class resolution operator for parameterized classes | 8.24.1 | Supported | |
Typedef class | 8.25 | Supported | |
Interface classes | 8.26 | Supported | |
Multiple inheritance of Interface classes | 8.26.6 | Supported | |
Memory management | 8.27 | Supported | |
Classes and structures | 8.28 | Supported | |
Processes | 9 | Supported | |
Parallel Process - Fork Join_Any and Fork Join_None | 9.3 | Supported | |
Wait fork | 9.6.1 | Supported | |
Disable Fork | 9.6.3 | Supported | |
Fine grain process control | 9.7 | Supported | |
Clocking Block | 14 | Supported | |
General | 14.1 | Supported | |
Overview | 14.2 | Supported | |
Clocking block declaration | 14.3 | Supported | |
Input and output Skew | 14.4 | Supported | |
Hierarchical Expressions | 14.5 | Not Supported | |
Signals in multiple clocking block | 14.6 | Supported | |
Clocking block scope and lifetime | 14.7 | Supported | |
Multiple clocking block example | 14.8 | Supported | |
Interface and clocking block | 14.9 | Supported | |
Clocking block event | 14.10 | Supported | |
Cycle Delay | 14.11 | Supported | |
Default clocking | 14.12 | Supported | |
Input Sampling | 14.13 | Supported | |
Global clocking | 14.14 | Not Supported | |
Synchronous events | 14.15 | Supported | |
Synchronous drives | 14.16 | Supported | |
Drives and nonblocking assignments | 14.16.1 | Supported | |
Driving clocking output signals | 14.16.2 | Supported | |
Semaphore | 15.3 | Supported | |
Semaphore method new() | 15.3.1 | Supported | |
Semaphore method put() | 15.3.2 | Supported | |
Semaphore method get() | 15.3.3 | Supported | |
Semaphore method try_get() | 15.3.4 | Supported | |
Mailbox | 15.4 | Supported | |
Mailbox method new() | 15.4.1 | Supported | |
Mailbox method num() | 15.4.2 | Supported | |
Mailbox method put() | 15.4.3 | Supported | |
Mailbox method try_put() | 15.4.4 | Supported | |
Mailbox method get() | 15.4.5 | Supported | |
Mailbox method try_get() | 15.4.6 | Supported | |
Mailbox method peek() | 15.4.7 | Supported | |
Mailbox method try_peek() | 15.4.8 | Supported | |
Parameterized mailbox | 15.4.9 | Supported | |
Named Event | 15.5 | Supported | |
Triggering an event | 15.5.1 | Supported | |
Waiting on event | 15.5.2 | Supported | |
Persistent trigger | 15.5.3 | Not Supported | |
Event Sequence | 15.5.4 | Not Supported | |
Operation on named event variable | 15.5.5 | Supported | |
Merging Events | 15.5.5.1 | Supported | |
Reclaiming event | 15.5.5.2 | Supported | |
Event comparison | 15.5.5.3 | Supported | |
Assertion | 16 | Supported | |
General | 16.1 | Supported | |
Overview | 16.2 | Supported | |
Assert | 16.2 | Supported | |
Assume | 16.2 | Supported | |
Cover | 16.2 | Not Supported | |
Restrict | 16.2 | Not Supported | |
Immediate assertion | 16.3 | Supported | |
Deferred assertion | 16.4 | Not Supported | |
Concurrent assertion overview | 16.5 | Supported | |
Sampling | 16.5.1 | Supported | |
Assertion clock | 16.5.2 | Supported | |
Boolean expression | 16.6 | Supported | |
Sequence | 16.7 | Supported | |
Declaring sequence | 16.8 | Supported | |
Typed formal argument in sequence declarations | 16.8.1 | Supported | |
Local variable formal arguments in sequence declarations | 16.8.2 | Supported | |
Sequence operations | 16.9 | Supported | |
Operator precedence | 16.9.1 | Supported | |
Repetition in sequences | 16.9.2 | Supported | |
Sampled value functions | 16.9.3 | Supported | |
Global clocking past and future sampled value functions | 16.9.4 | Not Supported | |
AND operation | 16.9.5 | Supported | |
Intersection (AND with length restriction) | 16.9.6 | Supported | |
OR operation | 16.9.7 | Supported | |
First_match operation | 16.9.8 | Supported | |
Conditions over sequences | 16.9.9 | Supported | |
Sequence contained within another sequence | 16.9.10 | Supported | |
Composing sequences from simpler subsequences | 16.9.11 | Supported | |
Local variables | 16.10 | Supported | |
Calling subroutines on match of a sequence | 16.11 | Supported | |
Declaring properties | 16.12 | Supported | |
Sequence property | 16.12.1 | Supported | |
Negation property | 16.12.2 | Supported | |
Disjunction property | 16.12.3 | Supported | |
Conjunction property | 16.12.4 | Supported | |
If-else property | 16.12.5 | Supported | |
Implication | 16.12.6 | Supported | |
Implies and iff properties | 16.12.7 | Supported | |
Property instantiation | 16.12.8 | Supported | |
Followed-by property | 16.12.9 | Not Supported | |
Next time property | 16.12.10 | Not Supported | |
Always property | 16.12.11 | Not Supported | |
Until property | 16.12.12 | Not Supported | |
Eventually property | 16.12.13 | Not Supported | |
Abort properties | 16.12.14 | Not Supported | |
Weak and strong operators | 16.12.15 | Not Supported | |
Case | 16.12.16 | Not Supported | |
Recursive properties | 16.12.17 | Not Supported | |
Typed formal arguments in property declarations | 16.12.18 | Supported | |
Local variable formal arguments in property declarations | 16.12.19 | Supported | |
Property examples | 16.12.20 | Supported | |
Finite-length versus infinite-length behavior | 16.12.21 | Supported | |
Nondegeneracy | 16.12.22 | Supported | |
Multiclock support | 16.13 | Not Supported | |
Concurrent assertions | 16.14 | Supported | |
Assert statement | 16.14.1 | Supported | |
Assume statement | 16.14.2 | Supported | |
Cover statement | 16.14.3 | Not Supported | |
Restrict statement | 16.14.4 | Not Supported | |
Using concurrent assertion statements outside procedural code | 16.14.5 | Supported | |
Embedding concurrent assertions in procedural code | 16.14.6 | Not Supported | |
Inferred value functions | 16.14.7 | Not Supported | |
Nonvacuous evaluations | 16.14.8 | Not Supported | |
Disable iff resolution | 16.15 | Supported | |
Clock resolution | 16.16 | Supported | |
Semantic leading clocks for multiclocked sequence and properties | 16.16.1 | Supported | |
Expect statement | 16.17 | Not Supported | |
Clocking blocks and concurrent assertions | 16.18 | Supported | |
Random Constraint | 18 | Supported | |
Concepts and Usage | 18.3 | Supported | |
Random Variable | 18.4 | Supported | |
Rand modifier | 18.4.1 | Supported | |
Randc modifier | 18.4.2 | Supported | |
Constraint block | 18.5 | Supported | |
External constraint block | 18.5.1 | Supported | |
Constraint inheritance | 18.5.2 | Supported | |
Set membership | 18.5.3 | Supported | |
Distribution | 18.5.4 | Supported | |
Implication | 18.5.6 | Supported | |
If-else constraint | 18.5.7 | Supported | |
Iterative constraint | 18.5.8 | Supported | |
foreach iterative constraint | 18.5.8.1 | Supported | |
Array reduction iterative constraint | 18.5.8.2 | Supported | |
Global constraint | 18.5.9 | Supported | |
Variable Ordering | 18.5.10 | Supported | |
Static constraint block | 18.5.11 | Supported | |
Function in constraint | 18.5.12 | Supported | |
Constraint Guards | 18.5.13 | Supported | |
Soft constraint | 18.5.14 | Supported | |
Method Randomize | 18.6.1 | Supported | |
Pre_randomize and post_randomize | 18.6.2 | Supported | |
Behavior of randomization method | 18.6.3 | Supported | |
In-line constraints | 18.7 | Supported | |
Local scope resolution | 18.7.1 | Supported | |
Disabling random variable with rand_mode | 18.8 | Supported | |
Controlling constraints with constraint_mode | 18.9 | Supported | |
Dynamic constraint modification | 18.10 | Supported | |
In-line random variable control | 18.11 | Supported | |
In-line constraint checker | 18.11.1 | Supported | |
Randomize of a scope variable std::randomize | 18.12 | Supported | |
Adding constraint to scope variables std::randomize with | 18.12.1 | Supported | |
Random number system functions and method | 18.13 | Supported | |
$urandom | 18.13.1 | Supported | |
$urandom_range | 18.13.2 | Supported | |
srandom | 18.13.3 | Supported | |
Get_randstate | 18.13.4 | Supported | |
Set_randstate | 18.13.5 | Supported | |
Random stability | 18.14 | Supported | |
Manually seeding randomization | 18.15 | Supported | |
Randcase | 18.16 | Supported | |
Randsequence | 18.17 | Not Supported | |
Programs | 24 | Supported | |
The Program construct | 24.3 | Supported | |
Scheduling semantic of code in program construct | 24.3.1 | Supported | |
Program port connection | 24.3.2 | Supported | |
Eliminating test bench race | 24.4 | Supported | |
Blocking task in cycle/event mode | 24.5 | Supported | |
Anonymous Programs | 24.6 | Not Supported | |
Program control task | 24.7 | Supported | |
Functional Coverage | 19 | Supported | |
General | 19.1 | Supported | |
Overview | 19.2 | Supported | |
Defining coverage model: covergroup | 19.3 | Supported | |
Using covergroup in classes | 19.4 | Supported | |
Defining coverage points | 19.5 | Supported | |
Specifying bins for values | 19.5.1 | Supported | |
Coverpoint bin with covergroup expressions | 19.5.1.1 | Supported | |
Coverpoint bin set covergroup expressions | 19.5.1.2 | Not supported | |
Specifying bins for transitions | 19.5.2 | Supported | |
Automatic bin creation for coverage points | 19.5.3 | Supported | |
Wildcard specification of coverage point bins | 19.5.4 | Supported | |
Excluding coverage point values or transitions | 19.5.5 | Supported | |
Specifying Illegal coverage point values or transitions | 19.5.6 | Supported | |
Value resolution | 19.5.7 | Supported | |
Defining cross coverage | 19.6 | Supported | |
Defining cross coverage bins | 19.6.1 | Supported | |
Example of user-defined cross coverage and select expressions | 19.6.1.1 | Supported | |
Cross bin with covergroup expressions | 19.6.1.2 | Supported | |
Cross bin automatically defined types | 19.6.1.3 | Supported | |
Cross bin set expression | 19.6.1.4 | Supported | |
Excluding cross products | 19.6.2 | Supported | |
Specifying illegal cross products | 19.6.3 | Supported | |
Specifying coverage options | 19.7 | Supported | |
Covergroup type options | 19.7.1 | Supported | |
Predefined coverage methods | 19.8 | Supported | |
Overriding the built-in sample method | 19.8.1 | Supported | |
Predefined coverage system tasks and system functions | 19.9 | Supported | |
Organization of option and type_option members | 19.10 | Supported |
Note: Sensitivity on dynamic
types such as Queue, Dynamic Array, Associative Array, and Class are not supported.
Therefore, block waiting on dynamic type update might not work correctly. For
example:
module top();
int c[$];
event e1;
initial
begin
c[0] = 10;
for(int i = 0; i <= 10; i++)
begin
c = {i, c};
-> e1;
#5;
end
end
always@(*) $display($time, " trying to read sensitivity on dynamic type : %d", c[0]);
// this won't work as sensitivity on dynamic type is not supported
always @(e1) $display($time, " coming from event sensitivity : %d", c[0]); // this we
can do as WA
always_comb if(c.size() > 0) $display($time, " Coming from size sensitivity : %d",
c[0]); // sensitivity on size works