Uvm_tlm_analysis_fifo print

Have used uvm_tlm_analysis_fifo in scoreboard.

  1. Need a way to print the un-processed contents in uvm_tlm_analysis_fifo after the run_phase.
    [ No way of detecting completion of run, can’t do fifo.get(tr) in report_phase ]

  2. Should we always use and export along with uvm_tlm_analysis_fifo to connect to monitor port ?
    can we not do it without export ?

In reply to Venkatateja B:

Have used uvm_tlm_analysis_fifo in scoreboard.

  1. Need a way to print the un-processed contents in uvm_tlm_analysis_fifo after the run_phase.
    [ No way of detecting completion of run, can’t do fifo.get(tr) in report_phase ]

We can use try_get method to get the transaction out of fifo. This can be used in conjunction with a loop iterating entire fifo size.

while(fifo.num) begin
if(fifo.try_get(trans))
// print trans
end

  1. Should we always use and export along with uvm_tlm_analysis_fifo to connect to monitor port ?
    can we not do it without export ?

The uvm_*_fifo works in reactive mode, so the fifos just have exports in them. We can connect monitor port to fifo export and then get the data from fifo using get export. More information on fifo exports can be taken from here.