User guide
24-97
SystemVerilog Testbench Constructs
3. The loop is expanded and all the members of the x array are
solved for.
The semantics of array constraints in the presence of $void calls
are as follows:
1. Implicit ordering relations are introduced between array sizes and
members of the array, *only* those with variable expressions in
the index.
• Array sizes are solved before the constraints inside loops are
solved or constraints involving array aggregate methods calls are
solved.
Semantics of Default Constraints
With the introduction of partitions, it is possible that some random
variables over which constraints are defined are solved before the
default constraint itself. In such a case, the solver will consider
previously solved random variables like state variables. When the
default constraint is solved, it is disabled only if any of the currently
being solved random variables incident on it are overridden. This is
consistent with current semantics of default constraints, when
considered in the context of the partition being solved.
Consider this example:
Example 24-6
default constraint b1 {
x <= y;
}
constraint b1 {
z == $void(y);
z => x == 0;
y inside {0, 1};
}
The sequence in which the constraints are solved is: