-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy pathscoreboard_base.sv
50 lines (48 loc) · 1.46 KB
/
scoreboard_base.sv
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
38
39
40
41
42
43
44
45
46
47
48
49
50
`ifndef SCOREBOARD_BASE_SVH
`define SCOREBOARD_BASE_SVH
class scoreboard_base #(
type CONFIGURATION = dma_axi_configuration,
type STATUS = dma_axi_status,
type ITEM = uvm_sequence_item,
type ITEM_HANDLE = ITEM
) extends component_base #(
uvm_scoreboard, CONFIGURATION, STATUS
);
// uvm_analysis_port #(ITEM_HANDLE) item_port;
function void build_phase(uvm_phase phase);
super.build_phase(phase);
// item_port = new("item_port", this);
endfunction : build_phase
/*
virtual function ITEM_HANDLE create_item(
string item_name = "item",
string stream_name = "main",
string label = "",
string desc = "",
time begin_time = 0,
int parent_handel = 0
);
ITEM item;
item = ITEM::type_id::create(item_name);
item.set_context(configuration, status);
void'(begin_tr(item, stream_name, label, desc, begin_time, parent_handel));
return item;
endfunction : create_item
virtual function void write_item(
ITEM_HANDLE item,
time end_time=0,
bit free_handle=1
);
uvm_event_pool event_pool = item.get_event_pool();
uvm_event end_event = event_pool.get("end");
if (!end_event.is_on()) begin
end_tr(item, end_time, free_handle);
end
item_port.write(item);
endfunction : write_item
*/
function new(string name="scoreboard_base", uvm_component par=null);
super.new(name, par);
endfunction : new
endclass : scoreboard_base
`endif