Hi All,
I have a question about controlling sequence library distibution. I would like to give the test writer the ability to control sequences distribution. For that i am using the uvm_sequence_library class. I saw that the index of a sequence in the library is determined by the order of sequence registration to the library (using `uvm_add_to_seq_lib macro). but this raises problem when removing sequences for example:
Project1 :
Sequence lib code:
constratint select_sequence_c { select_rand dist { 0:=20, // sequence_A
1:=100, // sequence_B
2:=20 // sequence_C
};}
The test owner would like to override the default distribution so in the test there is the following constraint layering:
constratint select_diff_dist { select_rand dist { /*0:=20, // sequence_A*/
1:=30, // sequence_B
2:=30 // sequence_C
};}
Next project . Project2 does not include sequence A anymore so it was removed from the sequence library . Sequence index is now shifted.
constratint select_sequence_c { select_rand dist {
0:=100, // sequence_B
1:=20 // sequence_C
};}
Now the test should be changed since index 1 does not point to sequence B anymore ( and so on…):
constratint select_diff_dist { select_rand dist {
1:=30, // sequence_B
2:=30 // sequence_C
};}
In OVM we used string based hash which is now deprecated:
constraint select_seq seq_kind dist {seq_kind dist Get_seq_kind(“sequence_A”) :=20,
seq_kind dist Get_seq_kind(“sequence_B”) :=20,
seq_kind dist Get_seq_kind(“sequence_C”) :=20};
}
Any idea how to solve this?
Thanks,
Ilan