SyoSil ApS UVM Scoreboard  1.0.3.0
cl_scb_test_io_md5_dump_orphans.svh
1 /// Uses io-compare and MD5 queues showing orphan dumps & shadow queues / scb dump.
2 // Note: Generally, io-md5 comparisons are overkill and md5-queues should only be used for ooo comparisons
3 class cl_scb_test_io_md5_dump_orphans extends cl_scb_test_single_scb;
4  //-------------------------------------
5  // Non randomizable variables
6  //-------------------------------------
7 
8 
9  //-------------------------------------
10  // UVM Macros
11  //-------------------------------------
12  `uvm_component_utils_begin(cl_scb_test_io_md5_dump_orphans)
13 
14  `uvm_component_utils_end
15 
16  //-------------------------------------
17  // Constructor
18  //-------------------------------------
19  function new(string name = "cl_scb_test_io_md5_dump_orphans", uvm_component parent = null);
20  super.new(name, parent);
21  endfunction: new
22 
23  //-------------------------------------
24  // Functions
25  //-------------------------------------
26  extern function void pre_build();
27  extern task run_phase(uvm_phase phase);
28 
29 
31 
32 function void cl_scb_test_io_md5_dump_orphans::pre_build();
33  super.pre_build();
34 
35  this.syoscb_cfgs.syoscb_cfg[0].set_queue_type(pk_syoscb::SYOSCB_QUEUE_MD5);
36 endfunction: pre_build
37 
38 task cl_scb_test_io_md5_dump_orphans::run_phase(uvm_phase phase);
39  phase.raise_objection(this);
40 
41  super.run_phase(phase);
42 
43  this.scb_env.syoscb_cfgs.syoscb_cfg[0].set_dump_orphans_to_files(1'b1); //Print to file
44  this.scb_env.syoscb[0].set_report_severity_id_override(UVM_ERROR, "QUEUE_ERROR", UVM_INFO); //Demote the error that is triggered due to orphans
45  this.scb_env.syoscb_cfgs.syoscb_cfg[0].set_max_print_orphans(0); //Print all orphans (5 in Q1, 2 in Q2)
46  this.scb_env.syoscb_cfgs.syoscb_cfg[0].set_orphan_dump_type(pk_syoscb::XML); //Dump as XML output
47  this.scb_env.syoscb_cfgs.syoscb_cfg[0].set_orphan_dump_file_name("md5_dump_orphans");
48 
49  this.scb_env.syoscb_cfgs.syoscb_cfg[0].set_full_scb_dump(1'b1); //Enable dump
50  this.scb_env.syoscb_cfgs.syoscb_cfg[0].set_full_scb_dump_type(pk_syoscb::TXT); //Text output
51  void'(this.scb_env.syoscb_cfgs.syoscb_cfg[0].set_full_scb_dump_split(1'b0)); //All tx in same file
52  this.scb_env.syoscb_cfgs.syoscb_cfg[0].set_full_scb_dump_file_name("md5_dump_orphans");
53 
54  fork
55  for(int unsigned i=0; i<10; i++) begin
56  cl_tb_seq_item item1;
57  item1 = cl_tb_seq_item::type_id::create("item1");
58  item1.int_a = i;
59  this.scb_env.syoscb[0].add_item("Q1", "P1", item1);
60  end
61 
62  for(int unsigned i=0; i<5; i++) begin //Only match the first 5 items in Q1, leaving 5 orphans
63  cl_tb_seq_item item1;
64  item1 = cl_tb_seq_item::type_id::create("item1");
65  item1.int_a = i;
66  this.scb_env.syoscb[0].add_item("Q2", "P1", item1);
67  end
68  join
69 
70  phase.drop_objection(this);
71 endtask: run_phase
Uses io-compare and MD5 queues showing orphan dumps & shadow queues / scb dump.

Project: SyoSil ApS UVM Scoreboard, Revision: 1.0.3.0

Copyright 2014-2022 SyoSil ApS
All Rights Reserved Worldwide

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
doxygen
Doxygen Version: 1.8.14
Generated with IDV SV Filter Version: 2.6.3
Fri Sep 2 2022 14:36:56
Find a documentation bug? Report bugs to: scoreboard@syosil.com