1 |
4 |
vladimirar |
<!-- This comment will put IE 6, 7 and 8 in quirks mode -->
|
2 |
|
|
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
3 |
|
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
4 |
|
|
<head>
|
5 |
|
|
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
6 |
|
|
<title>SyoSil ApS UVM Scoreboard: cl_syoscb.svh Source File</title>
|
7 |
|
|
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
8 |
|
|
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
9 |
|
|
<script type="text/javaScript" src="search/search.js"></script>
|
10 |
|
|
<link href="doxygen.css" rel="stylesheet" type="text/css"/>
|
11 |
|
|
</head>
|
12 |
|
|
<body onload='searchBox.OnSelectItem(0);'>
|
13 |
|
|
<!-- Generated by Doxygen 1.6.1 -->
|
14 |
|
|
<script type="text/javascript"><!--
|
15 |
|
|
var searchBox = new SearchBox("searchBox", "search",false,'Search');
|
16 |
|
|
--></script>
|
17 |
|
|
<script type="text/javascript">
|
18 |
|
|
<!--
|
19 |
|
|
function changeDisplayState (e){
|
20 |
|
|
var num=this.id.replace(/[^[0-9]/g,'');
|
21 |
|
|
var button=this.firstChild;
|
22 |
|
|
var sectionDiv=document.getElementById('dynsection'+num);
|
23 |
|
|
if (sectionDiv.style.display=='none'||sectionDiv.style.display==''){
|
24 |
|
|
sectionDiv.style.display='block';
|
25 |
|
|
button.src='open.gif';
|
26 |
|
|
}else{
|
27 |
|
|
sectionDiv.style.display='none';
|
28 |
|
|
button.src='closed.gif';
|
29 |
|
|
}
|
30 |
|
|
}
|
31 |
|
|
function initDynSections(){
|
32 |
|
|
var divs=document.getElementsByTagName('div');
|
33 |
|
|
var sectionCounter=1;
|
34 |
|
|
for(var i=0;i<divs.length-1;i++){
|
35 |
|
|
if(divs[i].className=='dynheader'&&divs[i+1].className=='dynsection'){
|
36 |
|
|
var header=divs[i];
|
37 |
|
|
var section=divs[i+1];
|
38 |
|
|
var button=header.firstChild;
|
39 |
|
|
if (button!='IMG'){
|
40 |
|
|
divs[i].insertBefore(document.createTextNode(' '),divs[i].firstChild);
|
41 |
|
|
button=document.createElement('img');
|
42 |
|
|
divs[i].insertBefore(button,divs[i].firstChild);
|
43 |
|
|
}
|
44 |
|
|
header.style.cursor='pointer';
|
45 |
|
|
header.onclick=changeDisplayState;
|
46 |
|
|
header.id='dynheader'+sectionCounter;
|
47 |
|
|
button.src='closed.gif';
|
48 |
|
|
section.id='dynsection'+sectionCounter;
|
49 |
|
|
section.style.display='none';
|
50 |
|
|
section.style.marginLeft='14px';
|
51 |
|
|
sectionCounter++;
|
52 |
|
|
}
|
53 |
|
|
}
|
54 |
|
|
}
|
55 |
|
|
window.onload = initDynSections;
|
56 |
|
|
-->
|
57 |
|
|
</script>
|
58 |
|
|
<div class="navigation" id="top">
|
59 |
|
|
<div class="tabs">
|
60 |
|
|
<ul>
|
61 |
|
|
<li><a href="index.html"><span>Main Page</span></a></li>
|
62 |
|
|
<li><a href="pages.html"><span>Related Pages</span></a></li>
|
63 |
|
|
<li><a href="annotated.html"><span>Classes</span></a></li>
|
64 |
|
|
<li class="current"><a href="files.html"><span>Files</span></a></li>
|
65 |
|
|
<li><a href="dirs.html"><span>Directories</span></a></li>
|
66 |
|
|
<li>
|
67 |
|
|
<div id="MSearchBox" class="MSearchBoxInactive">
|
68 |
|
|
<img id="MSearchSelect" src="search/search.png"
|
69 |
|
|
onmouseover="return searchBox.OnSearchSelectShow()"
|
70 |
|
|
onmouseout="return searchBox.OnSearchSelectHide()"
|
71 |
|
|
alt=""/>
|
72 |
|
|
<input type="text" id="MSearchField" value="Search" accesskey="S"
|
73 |
|
|
onfocus="searchBox.OnSearchFieldFocus(true)"
|
74 |
|
|
onblur="searchBox.OnSearchFieldFocus(false)"
|
75 |
|
|
onkeyup="searchBox.OnSearchFieldChange(event)"/>
|
76 |
|
|
<a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
|
77 |
|
|
</div>
|
78 |
|
|
</li>
|
79 |
|
|
</ul>
|
80 |
|
|
</div>
|
81 |
|
|
<div class="tabs">
|
82 |
|
|
<ul>
|
83 |
|
|
<li><a href="files.html"><span>File List</span></a></li>
|
84 |
|
|
</ul>
|
85 |
|
|
</div>
|
86 |
|
|
<div class="navpath"><a class="el" href="dir_562324e130495ce1321e3e3f14c8d761.html">src</a>
|
87 |
|
|
</div>
|
88 |
|
|
</div>
|
89 |
|
|
<div class="contents">
|
90 |
|
|
<h1>cl_syoscb.svh</h1><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/// Top level class implementing the root of the SyoSil UVM scoreboard</span>
|
91 |
|
|
<a name="l00002"></a><a class="code" href="classcl__syoscb.html">00002</a> <span class="comment"></span><span class="keyword">class </span><a class="code" href="classcl__syoscb.html" title="Top level class implementing the root of the SyoSil UVM scoreboard.">cl_syoscb</a> <span class="keyword">extends</span> uvm_scoreboard;
|
92 |
|
|
<a name="l00003"></a>00003 <span class="comment">//-------------------------------------</span>
|
93 |
|
|
<a name="l00004"></a>00004 <span class="comment">// Non randomizable variables</span>
|
94 |
|
|
<a name="l00005"></a>00005 <span class="comment">//-------------------------------------</span><span class="comment"></span>
|
95 |
|
|
<a name="l00006"></a>00006 <span class="comment"> /// Handle to the global UVM scoreboard configuration</span>
|
96 |
|
|
<a name="l00007"></a>00007 <span class="comment"></span> local <a class="code" href="classcl__syoscb__cfg.html" title="Configuration class for the SyoSil UVM scoreboard.">cl_syoscb_cfg</a> cfg;
|
97 |
|
|
<a name="l00008"></a>00008 <span class="comment"></span>
|
98 |
|
|
<a name="l00009"></a>00009 <span class="comment"> /// Array holding handles to all queues</span>
|
99 |
|
|
<a name="l00010"></a>00010 <span class="comment"></span> local <a class="code" href="classcl__syoscb__queue.html" title="Class which base concet of a queue.">cl_syoscb_queue</a> queues[];
|
100 |
|
|
<a name="l00011"></a>00011
|
101 |
|
|
<a name="l00012"></a>00012 <span class="comment">// Handle to the compare strategy</span>
|
102 |
|
|
<a name="l00013"></a>00013 local <a class="code" href="classcl__syoscb__compare.html" title="Class which act as the root of the compare algorithm.">cl_syoscb_compare</a> compare_strategy;
|
103 |
|
|
<a name="l00014"></a>00014
|
104 |
|
|
<a name="l00015"></a>00015 <span class="comment">// Assoc array holding each uvm_subscriber</span>
|
105 |
|
|
<a name="l00016"></a>00016 local <a class="code" href="classcl__syoscb__subscriber.html" title="Generic subscriber for the scoreboard.">cl_syoscb_subscriber</a> subscribers[string];
|
106 |
|
|
<a name="l00017"></a>00017
|
107 |
|
|
<a name="l00018"></a>00018 <span class="comment">//-------------------------------------</span>
|
108 |
|
|
<a name="l00019"></a>00019 <span class="comment">// UVM Macros</span>
|
109 |
|
|
<a name="l00020"></a>00020 <span class="comment">//-------------------------------------</span>
|
110 |
|
|
<a name="l00021"></a>00021 `uvm_component_utils_begin(cl_syoscb)
|
111 |
|
|
<a name="l00022"></a>00022 `uvm_field_object(cfg, UVM_DEFAULT)
|
112 |
|
|
<a name="l00023"></a>00023 `uvm_field_array_object(queues, UVM_DEFAULT)
|
113 |
|
|
<a name="l00024"></a>00024 `uvm_field_object(compare_strategy, UVM_DEFAULT)
|
114 |
|
|
<a name="l00025"></a>00025 `uvm_field_aa_object_string(subscribers, UVM_DEFAULT)
|
115 |
|
|
<a name="l00026"></a>00026 `uvm_component_utils_end
|
116 |
|
|
<a name="l00027"></a>00027
|
117 |
|
|
<a name="l00028"></a>00028 <span class="comment">//-------------------------------------</span>
|
118 |
|
|
<a name="l00029"></a>00029 <span class="comment">// Constructor</span>
|
119 |
|
|
<a name="l00030"></a>00030 <span class="comment">//-------------------------------------</span>
|
120 |
|
|
<a name="l00031"></a>00031 extern function new(string name = "cl_syoscb", uvm_component parent = null);
|
121 |
|
|
<a name="l00032"></a>00032
|
122 |
|
|
<a name="l00033"></a>00033 <span class="comment">//-------------------------------------</span>
|
123 |
|
|
<a name="l00034"></a>00034 <span class="comment">// UVM Phase methods</span>
|
124 |
|
|
<a name="l00035"></a>00035 <span class="comment">//-------------------------------------</span>
|
125 |
|
|
<a name="l00036"></a>00036 extern function void <a class="code" href="classcl__syoscb.html#aff5b55683b8bb74b5b75f607ac043602" title="The build_phase gets the scoreboard configuration and forwards it to the child components...">build_phase</a>(uvm_phase phase);
|
126 |
|
|
<a name="l00037"></a>00037
|
127 |
|
|
<a name="l00038"></a>00038 <span class="comment">//-------------------------------------</span>
|
128 |
|
|
<a name="l00039"></a>00039 <span class="comment">// Function based API</span>
|
129 |
|
|
<a name="l00040"></a>00040 <span class="comment">//-------------------------------------</span>
|
130 |
|
|
<a name="l00041"></a>00041 extern function void <a class="code" href="classcl__syoscb.html#a26c59c91c6fdd22f29a411cba2d5ed8f" title="Method for adding a uvm_sequence_item to a given queue for a given producer.">add_item</a>(string queue_name, string producer, uvm_sequence_item item);
|
131 |
|
|
<a name="l00042"></a>00042 extern function void <a class="code" href="classcl__syoscb.html#aca64b749ca30f964068a817ad4c152b7" title="Invokes the compare strategy.">compare</a>();
|
132 |
|
|
<a name="l00043"></a>00043
|
133 |
|
|
<a name="l00044"></a>00044 <span class="comment">//-------------------------------------</span>
|
134 |
|
|
<a name="l00045"></a>00045 <span class="comment">// Transaction based API</span>
|
135 |
|
|
<a name="l00046"></a>00046 <span class="comment">//-------------------------------------</span>
|
136 |
|
|
<a name="l00047"></a>00047 extern function <a class="code" href="classcl__syoscb__subscriber.html" title="Generic subscriber for the scoreboard.">cl_syoscb_subscriber</a> <a class="code" href="classcl__syoscb.html#a1d3983a0946cc4e38f74b249b5bb0e16" title="Returns a UVM subscriber for a given combination of queue and producer The returned...">get_subscriber</a>(string queue_name, string producer);
|
137 |
|
|
<a name="l00048"></a>00048 endclass: <a class="code" href="classcl__syoscb.html" title="Top level class implementing the root of the SyoSil UVM scoreboard.">cl_syoscb</a>
|
138 |
|
|
<a name="l00049"></a>00049
|
139 |
|
|
<a name="l00050"></a>00050 function <a class="code" href="classcl__syoscb.html" title="Top level class implementing the root of the SyoSil UVM scoreboard.">cl_syoscb</a>::new(string name = "cl_syoscb", uvm_component parent = null);
|
140 |
|
|
<a name="l00051"></a>00051 super.new(name, parent);
|
141 |
|
|
<a name="l00052"></a>00052 endfunction : new
|
142 |
|
|
<a name="l00053"></a>00053 <span class="comment"></span>
|
143 |
|
|
<a name="l00054"></a>00054 <span class="comment">/// The build_phase gets the scoreboard configuration and forwards it to the child components (cl_syoscb_queue</span>
|
144 |
|
|
<a name="l00055"></a>00055 <span class="comment">/// and cl_syoscb_compare). Additionally, it creates all of the queues defined in the configuration object. Finally,</span>
|
145 |
|
|
<a name="l00056"></a>00056 <span class="comment">/// it also creates the compare strategy via a factory create call.</span>
|
146 |
|
|
<a name="l00057"></a><a class="code" href="classcl__syoscb.html#aff5b55683b8bb74b5b75f607ac043602">00057</a> <span class="comment"></span>function void <a class="code" href="classcl__syoscb.html" title="Top level class implementing the root of the SyoSil UVM scoreboard.">cl_syoscb</a>::<a class="code" href="classcl__syoscb.html#aff5b55683b8bb74b5b75f607ac043602" title="The build_phase gets the scoreboard configuration and forwards it to the child components...">build_phase</a>(uvm_phase phase);
|
147 |
|
|
<a name="l00058"></a>00058 if (!uvm_config_db #(cl_syoscb_cfg)::get(this, "", "cfg", this.cfg)) begin
|
148 |
|
|
<a name="l00059"></a>00059 <span class="comment">// *NOTE*: If no cfg object is given then no scb name is available</span>
|
149 |
|
|
<a name="l00060"></a>00060 <span class="comment">// Thus, no scb name is printed here</span>
|
150 |
|
|
<a name="l00061"></a>00061 `uvm_fatal("CFG_ERROR", "Configuration object not passed.")
|
151 |
|
|
<a name="l00062"></a>00062 end
|
152 |
|
|
<a name="l00063"></a>00063
|
153 |
|
|
<a name="l00064"></a>00064 <span class="comment">// Set the default SCB name if not specified explicitly</span>
|
154 |
|
|
<a name="l00065"></a>00065 if(this.cfg.get_scb_name() == "") begin
|
155 |
|
|
<a name="l00066"></a>00066 this.cfg.set_scb_name(this.get_name());
|
156 |
|
|
<a name="l00067"></a>00067 end
|
157 |
|
|
<a name="l00068"></a>00068
|
158 |
|
|
<a name="l00069"></a>00069 <span class="comment">// Create list of queues</span>
|
159 |
|
|
<a name="l00070"></a>00070 this.queues = new[this.cfg.size_queues()];
|
160 |
|
|
<a name="l00071"></a>00071
|
161 |
|
|
<a name="l00072"></a>00072 <span class="comment">// Create the queues as defined in the configuration</span>
|
162 |
|
|
<a name="l00073"></a>00073 begin
|
163 |
|
|
<a name="l00074"></a>00074 string queue_names[];
|
164 |
|
|
<a name="l00075"></a>00075
|
165 |
|
|
<a name="l00076"></a>00076 <span class="comment">// Get teh list of queue names</span>
|
166 |
|
|
<a name="l00077"></a>00077 this.cfg.get_queues(queue_names);
|
167 |
|
|
<a name="l00078"></a>00078
|
168 |
|
|
<a name="l00079"></a>00079 foreach(queue_names[i]) begin
|
169 |
|
|
<a name="l00080"></a>00080 this.queues[i] = <a class="code" href="classcl__syoscb__queue.html" title="Class which base concet of a queue.">cl_syoscb_queue</a>::type_id::create(queue_names[i], this);
|
170 |
|
|
<a name="l00081"></a>00081 this.cfg.set_queue(queue_names[i], this.queues[i]);
|
171 |
|
|
<a name="l00082"></a>00082
|
172 |
|
|
<a name="l00083"></a>00083 <span class="comment">// Forward the configuration to the queue</span>
|
173 |
|
|
<a name="l00084"></a>00084 uvm_config_db #(cl_syoscb_cfg)::set(this, queue_names[i], "cfg", this.cfg);
|
174 |
|
|
<a name="l00085"></a>00085 end
|
175 |
|
|
<a name="l00086"></a>00086 end
|
176 |
|
|
<a name="l00087"></a>00087
|
177 |
|
|
<a name="l00088"></a>00088 <span class="comment">// Forward the configuration to the compare_strategy</span>
|
178 |
|
|
<a name="l00089"></a>00089 uvm_config_db #(cl_syoscb_cfg)::set(this, "compare_strategy", "cfg", this.cfg);
|
179 |
|
|
<a name="l00090"></a>00090
|
180 |
|
|
<a name="l00091"></a>00091 <span class="comment">// Create the compare strategy</span>
|
181 |
|
|
<a name="l00092"></a>00092 this.compare_strategy = <a class="code" href="classcl__syoscb__compare.html" title="Class which act as the root of the compare algorithm.">cl_syoscb_compare</a>::type_id::create(.name("compare_strategy"), .parent(this));
|
182 |
|
|
<a name="l00093"></a>00093
|
183 |
|
|
<a name="l00094"></a>00094 begin
|
184 |
|
|
<a name="l00095"></a>00095 cl_syoscb_report_catcher catcher = new();
|
185 |
|
|
<a name="l00096"></a>00096 uvm_report_cb::add(null, catcher);
|
186 |
|
|
<a name="l00097"></a>00097 end
|
187 |
|
|
<a name="l00098"></a>00098
|
188 |
|
|
<a name="l00099"></a>00099 begin
|
189 |
|
|
<a name="l00100"></a>00100 string producers[];
|
190 |
|
|
<a name="l00101"></a>00101
|
191 |
|
|
<a name="l00102"></a>00102 this.cfg.get_producers(producers);
|
192 |
|
|
<a name="l00103"></a>00103
|
193 |
|
|
<a name="l00104"></a>00104 foreach(producers[i]) begin
|
194 |
|
|
<a name="l00105"></a>00105 cl_syoscb_cfg_pl pl = this.cfg.get_producer(producers[i]);
|
195 |
|
|
<a name="l00106"></a>00106
|
196 |
|
|
<a name="l00107"></a>00107 foreach(pl.list[j]) begin
|
197 |
|
|
<a name="l00108"></a>00108 <a class="code" href="classcl__syoscb__subscriber.html" title="Generic subscriber for the scoreboard.">cl_syoscb_subscriber</a> subscriber;
|
198 |
|
|
<a name="l00109"></a>00109
|
199 |
|
|
<a name="l00110"></a>00110 subscriber = <a class="code" href="classcl__syoscb__subscriber.html" title="Generic subscriber for the scoreboard.">cl_syoscb_subscriber</a>::type_id::create({producers[i], "_", pl.list[j], "_subscr"}, this);
|
200 |
|
|
<a name="l00111"></a>00111 subscriber.set_queue_name(pl.list[j]);
|
201 |
|
|
<a name="l00112"></a>00112 subscriber.set_producer(producers[i]);
|
202 |
|
|
<a name="l00113"></a>00113 this.subscribers[{pl.list[j], producers[i]}] = subscriber;
|
203 |
|
|
<a name="l00114"></a>00114 end
|
204 |
|
|
<a name="l00115"></a>00115 end
|
205 |
|
|
<a name="l00116"></a>00116 end
|
206 |
|
|
<a name="l00117"></a>00117 endfunction: build_phase
|
207 |
|
|
<a name="l00118"></a>00118 <span class="comment"></span>
|
208 |
|
|
<a name="l00119"></a>00119 <span class="comment">/// Method for adding a uvm_sequence_item to a given queue for a given producer.</span>
|
209 |
|
|
<a name="l00120"></a>00120 <span class="comment">/// The method will check if the queue and producer exists before adding it to the queue.</span>
|
210 |
|
|
<a name="l00121"></a>00121 <span class="comment">/// </span>
|
211 |
|
|
<a name="l00122"></a>00122 <span class="comment">/// The uvm_sequence_item will be wrapped by a cl_syoscb_item along with some META data</span>
|
212 |
|
|
<a name="l00123"></a>00123 <span class="comment">/// Thus, it is the cl_syoscb_item which will be added to the queue and not the uvm_sequence_item</span>
|
213 |
|
|
<a name="l00124"></a>00124 <span class="comment">/// directly.</span>
|
214 |
|
|
<a name="l00125"></a>00125 <span class="comment">///</span>
|
215 |
|
|
<a name="l00126"></a>00126 <span class="comment">/// This ensures that the scoreboard can easily be added to an existing testbench with already defined</span>
|
216 |
|
|
<a name="l00127"></a>00127 <span class="comment">/// sequence items etc.</span>
|
217 |
|
|
<a name="l00128"></a><a class="code" href="classcl__syoscb.html#a26c59c91c6fdd22f29a411cba2d5ed8f">00128</a> <span class="comment"></span>function <span class="keywordtype">void</span> <a class="code" href="classcl__syoscb.html#a26c59c91c6fdd22f29a411cba2d5ed8f" title="Method for adding a uvm_sequence_item to a given queue for a given producer.">cl_syoscb::add_item</a>(<span class="keywordtype">string</span> queue_name, <span class="keywordtype">string</span> producer, uvm_sequence_item item);
|
218 |
|
|
<a name="l00129"></a>00129 uvm_sequence_item item_clone;
|
219 |
|
|
<a name="l00130"></a>00130
|
220 |
|
|
<a name="l00131"></a>00131 <span class="comment">// Check queue</span>
|
221 |
|
|
<a name="l00132"></a>00132 <span class="keywordflow">if</span>(!this.cfg.exist_queue(queue_name)) begin
|
222 |
|
|
<a name="l00133"></a>00133 `uvm_fatal(<span class="stringliteral">"CFG_ERROR"</span>, $sformatf(<span class="stringliteral">"[%s]: Queue: %0s is not found"</span>, this.cfg.get_scb_name(), queue_name));
|
223 |
|
|
<a name="l00134"></a>00134 end
|
224 |
|
|
<a name="l00135"></a>00135
|
225 |
|
|
<a name="l00136"></a>00136 <span class="comment">// Check producer</span>
|
226 |
|
|
<a name="l00137"></a>00137 <span class="keywordflow">if</span>(!this.cfg.exist_producer(producer)) begin
|
227 |
|
|
<a name="l00138"></a>00138 `uvm_fatal(<span class="stringliteral">"CFG_ERROR"</span>, $sformatf(<span class="stringliteral">"[%s]: Producer: %0s is not found"</span>, this.cfg.get_scb_name(), producer));
|
228 |
|
|
<a name="l00139"></a>00139 end
|
229 |
|
|
<a name="l00140"></a>00140
|
230 |
|
|
<a name="l00141"></a>00141 <span class="comment">// Clone the item if not disabled</span>
|
231 |
|
|
<a name="l00142"></a>00142 <span class="comment">// Clone the item in order to isolate the UVM scb from the rest of the TB</span>
|
232 |
|
|
<a name="l00143"></a>00143 <span class="keywordflow">if</span>(this.cfg.get_disable_clone() == 1<span class="stringliteral">'b0) begin</span>
|
233 |
|
|
<a name="l00144"></a>00144 <span class="stringliteral"> if(!$cast(item_clone, item.clone())) begin</span>
|
234 |
|
|
<a name="l00145"></a>00145 <span class="stringliteral"> `uvm_fatal("QUEUE_ERROR", $sformatf("[%s]: Unable to cast cloned item to uvm_sequence_item", this.cfg.get_scb_name()));</span>
|
235 |
|
|
<a name="l00146"></a>00146 <span class="stringliteral"> end</span>
|
236 |
|
|
<a name="l00147"></a>00147 <span class="stringliteral"> end else begin</span>
|
237 |
|
|
<a name="l00148"></a>00148 <span class="stringliteral"> item_clone = item;</span>
|
238 |
|
|
<a name="l00149"></a>00149 <span class="stringliteral"> end</span>
|
239 |
|
|
<a name="l00150"></a>00150 <span class="stringliteral"></span>
|
240 |
|
|
<a name="l00151"></a>00151 <span class="stringliteral"> // Add the uvm_sequence_item to the queue for the given producer</span>
|
241 |
|
|
<a name="l00152"></a>00152 <span class="stringliteral"> begin</span>
|
242 |
|
|
<a name="l00153"></a>00153 <span class="stringliteral"> cl_syoscb_queue queue;</span>
|
243 |
|
|
<a name="l00154"></a>00154 <span class="stringliteral"></span>
|
244 |
|
|
<a name="l00155"></a>00155 <span class="stringliteral"> queue = this.cfg.get_queue(queue_name);</span>
|
245 |
|
|
<a name="l00156"></a>00156 <span class="stringliteral"> </span>
|
246 |
|
|
<a name="l00157"></a>00157 <span class="stringliteral"> if(queue == null) begin</span>
|
247 |
|
|
<a name="l00158"></a>00158 <span class="stringliteral"> `uvm_fatal("QUEUE_ERROR", $sformatf("[%s]: Queue: %s not found by add_item method", this.cfg.get_scb_name(), queue_name));</span>
|
248 |
|
|
<a name="l00159"></a>00159 <span class="stringliteral"> end</span>
|
249 |
|
|
<a name="l00160"></a>00160 <span class="stringliteral"></span>
|
250 |
|
|
<a name="l00161"></a>00161 <span class="stringliteral"> if(!queue.add_item(producer, item_clone)) begin</span>
|
251 |
|
|
<a name="l00162"></a>00162 <span class="stringliteral"> `uvm_fatal("QUEUE_ERROR", $sformatf("[%s]: Unable to add item to queue: %s", this.cfg.get_scb_name(), queue_name));</span>
|
252 |
|
|
<a name="l00163"></a>00163 <span class="stringliteral"> end</span>
|
253 |
|
|
<a name="l00164"></a>00164 <span class="stringliteral"> end</span>
|
254 |
|
|
<a name="l00165"></a>00165 <span class="stringliteral"></span>
|
255 |
|
|
<a name="l00166"></a>00166 <span class="stringliteral"> `uvm_info("DEBUG", $sformatf("[%s]: Trigger compare by queue: %s, producer: %s", this.cfg.get_scb_name(), queue_name, producer), UVM_FULL);</span>
|
256 |
|
|
<a name="l00167"></a>00167 <span class="stringliteral"></span>
|
257 |
|
|
<a name="l00168"></a>00168 <span class="stringliteral"> // Invoke the compare algorithm</span>
|
258 |
|
|
<a name="l00169"></a>00169 <span class="stringliteral"> void'</span>(this.compare());
|
259 |
|
|
<a name="l00170"></a>00170 endfunction: add_item
|
260 |
|
|
<a name="l00171"></a>00171 <span class="comment"></span>
|
261 |
|
|
<a name="l00172"></a>00172 <span class="comment">/// Invokes the compare strategy</span>
|
262 |
|
|
<a name="l00173"></a><a class="code" href="classcl__syoscb.html#aca64b749ca30f964068a817ad4c152b7">00173</a> <span class="comment"></span>function <span class="keywordtype">void</span> <a class="code" href="classcl__syoscb.html#aca64b749ca30f964068a817ad4c152b7" title="Invokes the compare strategy.">cl_syoscb::compare</a>();
|
263 |
|
|
<a name="l00174"></a>00174 this.compare_strategy.compare();
|
264 |
|
|
<a name="l00175"></a>00175 endfunction: compare
|
265 |
|
|
<a name="l00176"></a>00176 <span class="comment"></span>
|
266 |
|
|
<a name="l00177"></a>00177 <span class="comment">/// Returns a UVM subscriber for a given combination of queue and producer</span>
|
267 |
|
|
<a name="l00178"></a>00178 <span class="comment">/// The returned UVM subscriber can then be connected to a UVM monitor or similar</span>
|
268 |
|
|
<a name="l00179"></a>00179 <span class="comment">/// which produces transactions which should be scoreboarded.</span>
|
269 |
|
|
<a name="l00180"></a><a class="code" href="classcl__syoscb.html#a1d3983a0946cc4e38f74b249b5bb0e16">00180</a> <span class="comment"></span>function <a class="code" href="classcl__syoscb__subscriber.html" title="Generic subscriber for the scoreboard.">cl_syoscb_subscriber</a> <a class="code" href="classcl__syoscb.html#a1d3983a0946cc4e38f74b249b5bb0e16" title="Returns a UVM subscriber for a given combination of queue and producer The returned...">cl_syoscb::get_subscriber</a>(<span class="keywordtype">string</span> queue_name, <span class="keywordtype">string</span> producer);
|
270 |
|
|
<a name="l00181"></a>00181 <span class="keywordflow">if</span>(this.subscribers.exists({queue_name, producer})) begin
|
271 |
|
|
<a name="l00182"></a>00182 <span class="keywordflow">return</span>(this.subscribers[{queue_name, producer}]);
|
272 |
|
|
<a name="l00183"></a>00183 end <span class="keywordflow">else</span> begin
|
273 |
|
|
<a name="l00184"></a>00184 `uvm_fatal(<span class="stringliteral">"SUBSCRIBER_ERROR"</span>, $sformatf(<span class="stringliteral">"[%s]: Unable to get subscriber for queue: %s and producer: %s"</span>, this.cfg.get_scb_name(), queue_name, producer));
|
274 |
|
|
<a name="l00185"></a>00185 <span class="keywordflow">return</span>(null);
|
275 |
|
|
<a name="l00186"></a>00186 end
|
276 |
|
|
<a name="l00187"></a>00187 endfunction: get_subscriber
|
277 |
|
|
</pre></div></div>
|
278 |
|
|
<!--- window showing the filter options -->
|
279 |
|
|
<div id="MSearchSelectWindow"
|
280 |
|
|
onmouseover="return searchBox.OnSearchSelectShow()"
|
281 |
|
|
onmouseout="return searchBox.OnSearchSelectHide()"
|
282 |
|
|
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
283 |
|
|
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark"> </span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark"> </span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark"> </span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark"> </span>Variables</a></div>
|
284 |
|
|
|
285 |
|
|
<!-- iframe showing the search results (closed by default) -->
|
286 |
|
|
<div id="MSearchResultsWindow">
|
287 |
|
|
<iframe src="" frameborder="0"
|
288 |
|
|
name="MSearchResults" id="MSearchResults">
|
289 |
|
|
</iframe>
|
290 |
|
|
</div>
|
291 |
|
|
|
292 |
|
|
<!--*************************************************************************-->
|
293 |
|
|
<!-- $Id: idv_dox_footer.html 136 2010-05-31 19:13:27Z seanoboyle $ -->
|
294 |
|
|
<!--*************************************************************************-->
|
295 |
|
|
<!-- This program is free software: you can redistribute it and/or modify -->
|
296 |
|
|
<!-- it under the terms of the GNU General Public License as published by -->
|
297 |
|
|
<!-- the Free Software Foundation, either version 3 of the License, or -->
|
298 |
|
|
<!-- (at your option) any later version. -->
|
299 |
|
|
<!-- -->
|
300 |
|
|
<!-- This program is distributed in the hope that it will be useful, -->
|
301 |
|
|
<!-- but WITHOUT ANY WARRANTY; without even the implied warranty of -->
|
302 |
|
|
<!-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -->
|
303 |
|
|
<!-- GNU General Public License for more details. -->
|
304 |
|
|
<!-- -->
|
305 |
|
|
<!-- You should have received a copy of the GNU General Public License -->
|
306 |
|
|
<!-- along with this program. If not, see http://www.gnu.org/licenses/. -->
|
307 |
|
|
<!-- -->
|
308 |
|
|
<!--*************************************************************************-->
|
309 |
|
|
<!-- Title: IDV Doxygen Footer File -->
|
310 |
|
|
<!-- Description: This file is a doxygen footer with the IDV logo and a -->
|
311 |
|
|
<!-- and a reference to the GNU FDL License. -->
|
312 |
|
|
<!-- -->
|
313 |
|
|
<!-- Original Author: Sean O'Boyle -->
|
314 |
|
|
<!-- Contact: seanoboyle@intelligentdv.com -->
|
315 |
|
|
<!-- Company: Intelligent Design Verification -->
|
316 |
|
|
<!-- Company URL: http://intelligentdv.com -->
|
317 |
|
|
<!-- -->
|
318 |
|
|
<!-- Download the most recent version here: -->
|
319 |
|
|
<!-- http://intelligentdv.com/downloads -->
|
320 |
|
|
<!-- -->
|
321 |
|
|
<!-- File Bugs Here: http://bugs.intelligentdv.com -->
|
322 |
|
|
<!-- Project: DoxygenFilterSV -->
|
323 |
|
|
<!-- -->
|
324 |
|
|
<!-- File: idv_dox_header.xml -->
|
325 |
|
|
<!-- $LastChangedBy: seanoboyle $ -->
|
326 |
|
|
<!-- $LastChangedDate: 2010-05-31 12:13:27 -0700 (Mon, 31 May 2010) $ -->
|
327 |
|
|
<!-- $LastChangedRevision: 136 $ -->
|
328 |
|
|
<!-- -->
|
329 |
|
|
<!--*************************************************************************-->
|
330 |
|
|
|
331 |
|
|
<br>
|
332 |
|
|
<table border="1" width = "100%">
|
333 |
|
|
<tr>
|
334 |
|
|
<td width = "20%">
|
335 |
|
|
<img src="syosil.jpg">
|
336 |
|
|
</td>
|
337 |
|
|
<td width = "60%">
|
338 |
|
|
<address style="text-align: center;">
|
339 |
|
|
Project: SyoSil ApS UVM Scoreboard, Revision: 1.0.2.5<br>
|
340 |
|
|
<br>
|
341 |
|
|
Copyright 2014-2015 SyoSil ApS<br>
|
342 |
|
|
All Rights Reserved Worldwide<br>
|
343 |
|
|
<br>
|
344 |
|
|
Licensed under the Apache License, Version 2.0 (the "License"); you may not
|
345 |
|
|
use this file except in compliance with the License. You may obtain a copy of
|
346 |
|
|
the License at<br>
|
347 |
|
|
<br>
|
348 |
|
|
<a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a><br>
|
349 |
|
|
<br>
|
350 |
|
|
Unless required by applicable law or agreed to in writing, software distributed under the License is
|
351 |
|
|
distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
352 |
|
|
implied. See the License for the specific language governing permissions and limitations under
|
353 |
|
|
the License.
|
354 |
|
|
</address>
|
355 |
|
|
</td>
|
356 |
|
|
<td width = "20%">
|
357 |
|
|
<address style="text-align: right;"><small>
|
358 |
|
|
<a href="http://www.doxygen.org/index.html"><img src="doxygen.png" alt="doxygen" align="middle" border="0"></a><br>
|
359 |
|
|
<a href="http://www.doxygen.org/index.html">Doxygen</a> Version: 1.6.1<br>
|
360 |
|
|
<a href="http://www.intelligentdv.com/index.html">IDV SV Filter</a> Version: 2.6.2<br>
|
361 |
|
|
Sat Nov 28 05:41:54 2015</small></address>
|
362 |
|
|
</td>
|
363 |
|
|
</tr>
|
364 |
|
|
</table>
|
365 |
|
|
<address style="text-align: left;"><small>
|
366 |
|
|
Find a documentation bug? Report bugs to: <a href="http://bugs.intelligentdv.com/">bugs.intelligentdv.com</a> Project: DoxygenFilterSV
|
367 |
|
|
</small></address>
|
368 |
|
|
</body>
|
369 |
|
|
</html>
|