hello,
I have a monitor at the output of the DUT and a predictor . outputs of the predictor and the monitor should be connected to the scoreboard.
i have done it as given in one of the threads :
//Declaration inside processor monitor
ovm_analysis_port #(OUT_item) proc_mon_port;
:)proc_mon_port.write(OUT_item); -----error in this line
//Declaration inside predictor
ovm_analysis_port #(OUT_item) predictor_port;
:)predictor_port.write(OUT_item); -----error in this line
//Declarations inside ovm_scoreboard
//Declare two ovm_analysis_export to receive transactions from
monitors and predictor
ovm_analysis_export #(OUT_item) proc_mon_export;
ovm_analysis_export #(OUT_item) predictor_export;
//Declare two tlm_analysis_fifo to connect to ovm_analysis_export
//to get the transactions
tlm_analysis_fifo #(OUT_item) proc_mon_fifo;
tlm_analysis_fifo #(OUT_item) predictor_fifo;
//Connect ovm_analysis_export and tlm_analysis_fifo using
//connect function inside ovm_scoreboard
function void connect;
proc_mon_export.connect(proc_mon_fifo.analysis_export);
predictor_export.connect(predictor_fifo.analysis_export);
endfunction: connect
//Define the task run to get the transaction using get method
task run;
begin
chk_data();
end
endtask: run
task chk_data();
OUT_item proc_mon, predictor;
forever begin
proc_mon_fifo.get(proc_mon);
predictor_fifo.get(predictor);
if(proc_mon.OUT_item == predictor.OUT_item )
$display("match");
end
endtask: chk_data
// Connections inside the environment
// Now connecting the two differenct ovm_monitor with the
// ovm_scoreboard using the connect function
function void connect();
ctl_proc_mon_1.proc_mon_port.connect(ctl_scoreboard.proc_mon_export);
ctl_predictor_2.predictor_port.connect(ctl_scoreboard.predictor_export);
endfunction: connect
pls help......