Quantcast
Channel: Cadence Functional Verification Forum
Viewing all articles
Browse latest Browse all 1075

cannot pass uvm_sequence_item to send_to_dut

$
0
0

Hi all,

Problem: I cannot call within uvm_driver the method send_to_dut with uvm_sequence_item.send_to_dut without argument can access class items of uvm_sequence_item, though.

My example is based on the forum entries run_phase doesn't update SV interface signals and How to use uvm_agent for sequencing . In the original case following done, which is working;

class my_transaction extends uvm_sequence_item;
  rand logic [7:0] load_val;
...
endclass

...

class my_driver extends uvm_driver #(my_transaction);
...
virtual task run_phase(uvm_phase_phase);
  seq_item_port.get_next_item(req);
  send_to_dut();
  seq_item_port.item_done();
endtask

virtual task send_to_dut();
  dut_vi.i_load_val = req.load_val;
endtask

The code above works. Please note that send_to_dut does not take an argument. However if I use

send_to_dut ( req );

and

virtual task send_to_dut (uvm_sequence_item my_req);
dut_vi.i_load_val = my_req.load_val;

... then Incisive complains that load_val in the sent_to_dut task is not a class item.

Where is my mistake?


Viewing all articles
Browse latest Browse all 1075

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>