Jump to content

Leaderboard


Popular Content

Showing content with the highest reputation on 05/21/2016 in all areas

  1. 1 point
    karandeep963

    saving previous transaction values

    Though its late to answer I guess, here is one solution: Create two packets in your monitor as follow; class any_monitor extends uvm_monitor; // rest things task run_phase (uvm_phase phase); my_packet previous_packet = my_packet::type_id::create("previous_packet"); my_packet current_packet = my_packet::type_id::create("current_packet "); // Processing the transaction // Do the needful and before sending the packet through monitor analysis port make a local copy for it as // since we send the packet through analysis port in the end where we are all done with our processing , so upto here you have previous packet available $cast(previous_packet,current_packet ); analysis_port.write(current_packet ); // In this way you can make for more copies , even put these copies in fifo , do whatever flavor your want to implement endtask In the above way you can make for more copies , even put these copies in fifo , do whatever flavor your want to implement. Hope it will meet your requirements. Regards, Karandeep
×