In reply to Hani John Poly:
Apparently, you slept through your Probabilities and Statistics class, and you don't gamble. Try flipping a coin 20 times and see how often it lands on the same side consecutively. A distribution is not like a hard constraint; it is only after a large number of iterations that your solution approaches the desired distribution.
If you have a hard constraint that a number from each of the three sets it picked in a cycle, then you cannot use the dist constraint. You can use the cyclic randc constraint to select between each set:
randc bit [2:0] delay_set;
rand bit[3:0] ack_delay;
constraint delay_set_limit { delay_set < 3 }
constraint ack_delay_constr {
delay_set==0 -> ack_delay ==1;
delay_set==1 -> ack_delay inside {[2:5]};
delay_set==2 -> ack_delay inside {[6:15]};
}
This gives you an exact even selection of each set in one cycle. If want multiple selection of sets in a cycle, or don't want the selections to be even increase the delay_set_limit:
randc bit [2:0] delay_set;
rand bit[3:0] ack_delay;
constraint delay_set_limit { delay_set < 8 }
constraint ack_delay_constr {
delay_set < 4 -> ack_delay==1;
(delay_set==4 || delay_set==5) -> ack_delay inside {[2:5]};
delay_set inside {[6:7]} -> ack_delay inside {[6:15]};
}
This gives you 4 selections of set 1, 2 selections of set 2:5, and 2 selections of set 6:15 in a cycle.