-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathring_sequence_item.sv
More file actions
37 lines (29 loc) · 1.3 KB
/
ring_sequence_item.sv
File metadata and controls
37 lines (29 loc) · 1.3 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
class ring_sequence_item extends uvm_sequence_item;
//------------ i/p || o/p field declaration-----------------
logic rst; //o/p
logic [7:0] out;
//---------------- register ring_sequence_item class with factory --------
`uvm_object_utils_begin(ring_sequence_item)
`uvm_field_int( rst ,UVM_ALL_ON)
`uvm_field_int( out ,UVM_ALL_ON)
`uvm_object_utils_end
//----------------------------------------------------------------------------
//----------------------------------------------------------------------------
function new(string name="ring_sequence_item");
super.new(name);
endfunction
//----------------------------------------------------------------------------
//----------------------------------------------------------------------------
// write DUT inputs here for printing
function string input2string();
return($sformatf(" rst=%0b ", rst));
endfunction
// write DUT outputs here for printing
function string output2string();
return($sformatf(" out=%8b", out));
endfunction
function string convert2string();
return($sformatf({input2string(), " || ", output2string()}));
endfunction
//----------------------------------------------------------------------------
endclass:ring_sequence_item