Hello, I am stuck in this error and unable to debug this. Can you please help me with this.
Fatal error in Task ram_test_pkg/ram_wr_monitor::collect_data at …/wr_agt_top/ram_wr_monitor.sv line 94
HDL call sequence:
Stopped at …/wr_agt_top/ram_wr_monitor.sv 94 Task ram_test_pkg/ram_wr_monitor::collect_data
Here is the ram_wr_monitor code.
class ram_wr_monitor extends uvm_monitor;
// Factory Registration
`uvm_component_utils(ram_wr_monitor)
virtual ram_if.WMON_MP vif;
ram_wr_agent_config m_cfg;
extern function new(string name = "ram_wr_monitor", uvm_component parent);
extern function void build_phase(uvm_phase phase);
extern function void connect_phase(uvm_phase phase);
extern task run_phase(uvm_phase phase);
extern task collect_data();
extern function void report_phase(uvm_phase phase);
endclass
//----------------- constructor new method -------------------//
function ram_wr_monitor::new(string name = “ram_wr_monitor”, uvm_component parent);
super.new(name,parent);
endfunction
//----------------- build() phase method -------------------//
function void ram_wr_monitor::build_phase(uvm_phase phase);
super.build_phase(phase);
if(!uvm_config_db #(ram_wr_agent_config)::get(this,“”,“ram_wr_agent_config”,m_cfg))
`uvm_fatal(“CONFIG”,“Config has not been set(), have you set() it”)
endfunction
//----------------- connect() phase method -------------------//
function void ram_wr_monitor::connect_phase(uvm_phase phase);
// super.connect_phase(phase);
vif = m_cfg.vif;
endfunction
//----------------- run() phase method -------------------//
task ram_wr_monitor::run_phase(uvm_phase phase);
forever
begin
collect_data();
end
endtask
// In forever loop
// Call task collect_data provided
// Collect Reference Data from DUV IF
task ram_wr_monitor::collect_data();
write_xtn data_sent;
// Create an instance data_sent
data_sent= write_xtn::type_id::create(“data_sent”);
@(posedge vif.wmon_cb.write);
data_sent.write = vif.wmon_cb.write;
data_sent.data = vif.wmon_cb.data_in;
data_sent.address = vif.wmon_cb.wr_address;
data_sent.xtn_type = (data_sent.address == 'd1904) ? BAD_XTN : GOOD_XTN ;
`uvm_info(“RAM_WR_MONITOR”,$sformatf(“printing from monitor \n %s”, data_sent.sprint()),UVM_LOW)
m_cfg.mon_rcvd_xtn_cnt++;
endtask
// UVM report_phase
function void ram_wr_monitor::report_phase(uvm_phase phase);
`uvm_info(get_type_name(), $sformatf(“Report: RAM Monitor received %0d transactions”,m_cfg.mon_rcvd_xtn_cnt),UVM_LOW)
endfunction