source: trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/Register_unit_Glue/src/Register_unit_Glue.cpp @ 132

Last change on this file since 132 was 132, checked in by rosiere, 15 years ago

1) add constant method - compatibility with SystemC
2) add Script to test sensitive list
3) fix bug in sensitive list

  • Property svn:keywords set to Id
File size: 21.7 KB
Line 
1/*
2 * $Id: Register_unit_Glue.cpp 132 2009-07-11 16:39:35Z rosiere $
3 *
4 * [ Description ]
5 *
6 */
7
8#include "Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/Register_unit_Glue/include/Register_unit_Glue.h"
9
10namespace morpheo                    {
11namespace behavioural {
12namespace core {
13namespace multi_execute_loop {
14namespace execute_loop {
15namespace register_unit {
16namespace register_unit_glue {
17
18
19#undef  FUNCTION
20#define FUNCTION "Register_unit_Glue::Register_unit_Glue"
21  Register_unit_Glue::Register_unit_Glue
22  (
23#ifdef SYSTEMC
24   sc_module_name name,
25#else
26   std::string name,
27#endif
28#ifdef STATISTICS
29   morpheo::behavioural::Parameters_Statistics * param_statistics,
30#endif
31   morpheo::behavioural::core::multi_execute_loop::execute_loop::register_unit::register_unit_glue::Parameters * param,
32   morpheo::behavioural::Tusage_t usage
33   ):
34    _name              (name)
35    ,_param            (param)
36    ,_usage            (usage)
37  {
38    log_printf(FUNC,Register_unit_Glue,FUNCTION,"Begin");
39
40// #if DEBUG_Register_unit_Glue == true
41//     log_printf(INFO,Register_unit_Glue,FUNCTION,_("<%s> Parameters"),_name.c_str());
42
43//     std::cout << *param << std::endl;
44// #endif   
45
46    log_printf(INFO,Register_unit_Glue,FUNCTION,"Allocation");
47    allocation ();
48
49#ifdef STATISTICS
50    if (usage_is_set(_usage,USE_STATISTICS))
51      {
52        log_printf(INFO,Register_unit_Glue,FUNCTION,"Allocation of statistics");
53       
54        // Allocation of statistics
55        statistics_declaration(param_statistics);
56      }
57#endif
58
59#ifdef VHDL
60    if (usage_is_set(_usage,USE_VHDL))
61      {
62        // generate the vhdl
63        log_printf(INFO,Register_unit_Glue,FUNCTION,"Generate the vhdl");
64       
65        vhdl();
66      }
67#endif
68
69#ifdef SYSTEMC
70    if (usage_is_set(_usage,USE_SYSTEMC))
71      {
72#ifdef SYSTEMCASS_SPECIFIC
73        constant();
74#else
75    log_printf(INFO,Register_unit_Glue,FUNCTION,"Method - constant");
76
77    SC_METHOD (constant);
78//     dont_initialize ();
79
80#ifdef SYSTEMCASS_SPECIFIC
81    // List dependency information
82#endif   
83#endif
84
85    log_printf(INFO,Register_unit_Glue,FUNCTION,"Method - transition");
86
87    SC_METHOD (transition);
88    dont_initialize ();
89    sensitive << (*(in_CLOCK)).pos();
90
91#ifdef SYSTEMCASS_SPECIFIC
92    // List dependency information
93#endif   
94
95    log_printf(INFO,Register_unit_Glue,FUNCTION,"Method - genMealy_gpr_read");
96
97    SC_METHOD (genMealy_gpr_read);
98    dont_initialize ();
99//     sensitive << (*(in_CLOCK)).neg();
100    sensitive << (*(in_NRESET));
101    for (uint32_t j=0; j<_param->_nb_gpr_read; j++)
102      {
103        if (_param->_have_port_ooo_engine_id == true)
104          sensitive << *(in_GPR_READ_OOO_ENGINE_ID [j]);
105
106        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
107          sensitive << *(in_GPR_READ_REGISTERFILE_ACK  [i][j])
108                    << *(in_GPR_READ_REGISTERFILE_DATA [i][j])
109                    << *(in_GPR_READ_STATUS_ACK        [i][j])
110                    << *(in_GPR_READ_STATUS_DATA_VAL   [i][j]);
111      }
112
113#ifdef SYSTEMCASS_SPECIFIC
114    // List dependency information
115    for (uint32_t j=0; j<_param->_nb_gpr_read; j++)
116      {
117        if (_param->_have_port_ooo_engine_id == true)
118          {
119            (*(out_GPR_READ_ACK                  [j])) (*( in_GPR_READ_OOO_ENGINE_ID        [j]));
120            (*(out_GPR_READ_DATA_VAL             [j])) (*( in_GPR_READ_OOO_ENGINE_ID        [j]));
121            (*(out_GPR_READ_DATA                 [j])) (*( in_GPR_READ_OOO_ENGINE_ID        [j]));
122          }
123        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
124          {
125            (*(out_GPR_READ_ACK                  [j])) (*( in_GPR_READ_REGISTERFILE_ACK  [i][j]));
126            (*(out_GPR_READ_ACK                  [j])) (*( in_GPR_READ_STATUS_ACK        [i][j]));
127            (*(out_GPR_READ_DATA                 [j])) (*( in_GPR_READ_REGISTERFILE_DATA [i][j]));
128            (*(out_GPR_READ_DATA_VAL             [j])) (*( in_GPR_READ_STATUS_DATA_VAL   [i][j]));     
129          }
130      }
131#endif   
132
133    log_printf(INFO,Register_unit_Glue,FUNCTION,"Method - genMealy_gpr_read_status");
134
135    SC_METHOD (genMealy_gpr_read_status);
136    dont_initialize ();
137//     sensitive << (*(in_CLOCK)).neg();
138    sensitive << (*(in_NRESET));
139    for (uint32_t j=0; j<_param->_nb_gpr_read; j++)
140      {
141        sensitive << *(in_GPR_READ_VAL           [j]);
142        if (_param->_have_port_ooo_engine_id == true)
143          sensitive << *(in_GPR_READ_OOO_ENGINE_ID [j]);
144
145        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
146          sensitive << *(in_GPR_READ_REGISTERFILE_ACK  [i][j]);
147      }
148
149#ifdef SYSTEMCASS_SPECIFIC
150    // List dependency information
151    for (uint32_t j=0; j<_param->_nb_gpr_read; j++)
152      {
153        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
154          {
155            (*(out_GPR_READ_STATUS_VAL        [i][j])) (*( in_GPR_READ_VAL                  [j]));
156            (*(out_GPR_READ_STATUS_VAL        [i][j])) (*( in_GPR_READ_REGISTERFILE_ACK  [i][j]));
157            if (_param->_have_port_ooo_engine_id == true)
158            (*(out_GPR_READ_STATUS_VAL        [i][j])) (*( in_GPR_READ_OOO_ENGINE_ID        [j]));
159          }
160      }
161#endif   
162
163    log_printf(INFO,Register_unit_Glue,FUNCTION,"Method - genMealy_gpr_read_registerfile");
164
165    SC_METHOD (genMealy_gpr_read_registerfile);
166    dont_initialize ();
167//     sensitive << (*(in_CLOCK)).neg();
168    sensitive << (*(in_NRESET));
169    for (uint32_t j=0; j<_param->_nb_gpr_read; j++)
170      {
171        sensitive << *(in_GPR_READ_VAL           [j]);
172        if (_param->_have_port_ooo_engine_id == true)
173          sensitive << *(in_GPR_READ_OOO_ENGINE_ID [j]);
174
175        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
176          sensitive << *(in_GPR_READ_STATUS_ACK        [i][j]);
177      }
178
179#ifdef SYSTEMCASS_SPECIFIC
180    // List dependency information
181    for (uint32_t j=0; j<_param->_nb_gpr_read; j++)
182      {
183        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
184          {
185            (*(out_GPR_READ_REGISTERFILE_VAL  [i][j])) (*( in_GPR_READ_VAL                  [j]));
186            (*(out_GPR_READ_REGISTERFILE_VAL  [i][j])) (*( in_GPR_READ_STATUS_ACK        [i][j]));
187            if (_param->_have_port_ooo_engine_id == true)
188            (*(out_GPR_READ_REGISTERFILE_VAL  [i][j])) (*( in_GPR_READ_OOO_ENGINE_ID        [j]));
189          }
190      }
191#endif   
192
193    log_printf(INFO,Register_unit_Glue,FUNCTION,"Method - genMealy_gpr_write");
194
195    SC_METHOD (genMealy_gpr_write);
196    dont_initialize ();
197//     sensitive << (*(in_CLOCK)).neg();
198    sensitive << (*(in_NRESET));
199    for (uint32_t j=0; j<_param->_nb_gpr_write; j++)
200      {
201        if (_param->_have_port_ooo_engine_id == true)
202          sensitive << *(in_GPR_WRITE_OOO_ENGINE_ID [j]);
203
204        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
205          sensitive << *(in_GPR_WRITE_REGISTERFILE_ACK  [i][j])
206                    << *(in_GPR_WRITE_STATUS_ACK        [i][j]);
207      }
208
209#ifdef SYSTEMCASS_SPECIFIC
210    // List dependency information
211    for (uint32_t j=0; j<_param->_nb_gpr_write; j++)
212      {
213        if (_param->_have_port_ooo_engine_id == true)
214        (*(out_GPR_WRITE_ACK                  [j])) (*( in_GPR_WRITE_OOO_ENGINE_ID        [j]));
215                   
216        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
217          {
218            (*(out_GPR_WRITE_ACK                  [j])) (*( in_GPR_WRITE_REGISTERFILE_ACK  [i][j]));
219            (*(out_GPR_WRITE_ACK                  [j])) (*( in_GPR_WRITE_STATUS_ACK        [i][j]));
220          }
221      }
222#endif   
223
224    log_printf(INFO,Register_unit_Glue,FUNCTION,"Method - genMealy_gpr_write_status");
225
226    SC_METHOD (genMealy_gpr_write_status);
227    dont_initialize ();
228//     sensitive << (*(in_CLOCK)).neg();
229    sensitive << (*(in_NRESET));
230    for (uint32_t j=0; j<_param->_nb_gpr_write; j++)
231      {
232        sensitive << *(in_GPR_WRITE_VAL           [j]);
233        if (_param->_have_port_ooo_engine_id == true)
234          sensitive << *(in_GPR_WRITE_OOO_ENGINE_ID [j]);
235
236        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
237          sensitive << *(in_GPR_WRITE_REGISTERFILE_ACK  [i][j]);
238      }
239
240#ifdef SYSTEMCASS_SPECIFIC
241    // List dependency information
242    for (uint32_t j=0; j<_param->_nb_gpr_write; j++)
243      {
244        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
245          {
246            (*(out_GPR_WRITE_STATUS_VAL        [i][j])) (*( in_GPR_WRITE_VAL                  [j]));
247            (*(out_GPR_WRITE_STATUS_VAL        [i][j])) (*( in_GPR_WRITE_REGISTERFILE_ACK  [i][j]));
248            if (_param->_have_port_ooo_engine_id == true)
249            (*(out_GPR_WRITE_STATUS_VAL        [i][j])) (*( in_GPR_WRITE_OOO_ENGINE_ID        [j]));
250          }
251      }
252#endif   
253
254    log_printf(INFO,Register_unit_Glue,FUNCTION,"Method - genMealy_gpr_write_registerfile");
255
256    SC_METHOD (genMealy_gpr_write_registerfile);
257    dont_initialize ();
258//     sensitive << (*(in_CLOCK)).neg();
259    sensitive << (*(in_NRESET));
260    for (uint32_t j=0; j<_param->_nb_gpr_write; j++)
261      {
262        sensitive << *(in_GPR_WRITE_VAL           [j]);
263        if (_param->_have_port_ooo_engine_id == true)
264          sensitive << *(in_GPR_WRITE_OOO_ENGINE_ID [j]);
265
266        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
267          sensitive << *(in_GPR_WRITE_STATUS_ACK        [i][j]);
268      }
269
270#ifdef SYSTEMCASS_SPECIFIC
271    // List dependency information
272    for (uint32_t j=0; j<_param->_nb_gpr_write; j++)
273      {
274        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
275          {
276            (*(out_GPR_WRITE_REGISTERFILE_VAL  [i][j])) (*( in_GPR_WRITE_VAL                  [j]));
277            (*(out_GPR_WRITE_REGISTERFILE_VAL  [i][j])) (*( in_GPR_WRITE_STATUS_ACK        [i][j]));
278            if (_param->_have_port_ooo_engine_id == true)
279            (*(out_GPR_WRITE_REGISTERFILE_VAL  [i][j])) (*( in_GPR_WRITE_OOO_ENGINE_ID        [j]));
280          }
281      }
282#endif   
283
284    log_printf(INFO,Register_unit_Glue,FUNCTION,"Method - genMealy_spr_read");
285
286    SC_METHOD (genMealy_spr_read);
287    dont_initialize ();
288//     sensitive << (*(in_CLOCK)).neg();
289    sensitive << (*(in_NRESET));
290    for (uint32_t j=0; j<_param->_nb_spr_read; j++)
291      {
292        if (_param->_have_port_ooo_engine_id == true)
293          sensitive << *(in_SPR_READ_OOO_ENGINE_ID [j]);
294
295        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
296          sensitive << *(in_SPR_READ_REGISTERFILE_ACK  [i][j])
297                    << *(in_SPR_READ_REGISTERFILE_DATA [i][j])
298                    << *(in_SPR_READ_STATUS_ACK        [i][j])
299                    << *(in_SPR_READ_STATUS_DATA_VAL   [i][j]);
300      }
301
302#ifdef SYSTEMCASS_SPECIFIC
303    // List dependency information
304    for (uint32_t j=0; j<_param->_nb_spr_read; j++)
305      {
306        if (_param->_have_port_ooo_engine_id == true)
307          {
308            (*(out_SPR_READ_ACK                  [j])) (*( in_SPR_READ_OOO_ENGINE_ID        [j]));
309            (*(out_SPR_READ_DATA_VAL             [j])) (*( in_SPR_READ_OOO_ENGINE_ID        [j]));
310            (*(out_SPR_READ_DATA                 [j])) (*( in_SPR_READ_OOO_ENGINE_ID        [j]));
311          }
312        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
313          {
314            (*(out_SPR_READ_ACK                  [j])) (*( in_SPR_READ_REGISTERFILE_ACK  [i][j]));
315            (*(out_SPR_READ_ACK                  [j])) (*( in_SPR_READ_STATUS_ACK        [i][j]));
316            (*(out_SPR_READ_DATA                 [j])) (*( in_SPR_READ_REGISTERFILE_DATA [i][j]));
317            (*(out_SPR_READ_DATA_VAL             [j])) (*( in_SPR_READ_STATUS_DATA_VAL   [i][j]));     
318          }
319      }
320#endif   
321
322    log_printf(INFO,Register_unit_Glue,FUNCTION,"Method - genMealy_spr_read_status");
323
324    SC_METHOD (genMealy_spr_read_status);
325    dont_initialize ();
326//     sensitive << (*(in_CLOCK)).neg();
327    sensitive << (*(in_NRESET));
328    for (uint32_t j=0; j<_param->_nb_spr_read; j++)
329      {
330        sensitive << *(in_SPR_READ_VAL           [j]);
331        if (_param->_have_port_ooo_engine_id == true)
332          sensitive << *(in_SPR_READ_OOO_ENGINE_ID [j]);
333
334        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
335          sensitive << *(in_SPR_READ_REGISTERFILE_ACK  [i][j]);
336      }
337
338#ifdef SYSTEMCASS_SPECIFIC
339    // List dependency information
340    for (uint32_t j=0; j<_param->_nb_spr_read; j++)
341      {
342        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
343          {
344            (*(out_SPR_READ_STATUS_VAL        [i][j])) (*( in_SPR_READ_VAL                  [j]));
345            (*(out_SPR_READ_STATUS_VAL        [i][j])) (*( in_SPR_READ_REGISTERFILE_ACK  [i][j]));
346            if (_param->_have_port_ooo_engine_id == true)
347            (*(out_SPR_READ_STATUS_VAL        [i][j])) (*( in_SPR_READ_OOO_ENGINE_ID        [j]));
348          }
349      }
350#endif   
351
352    log_printf(INFO,Register_unit_Glue,FUNCTION,"Method - genMealy_spr_read_registerfile");
353
354    SC_METHOD (genMealy_spr_read_registerfile);
355    dont_initialize ();
356//     sensitive << (*(in_CLOCK)).neg();
357    sensitive << (*(in_NRESET));
358    for (uint32_t j=0; j<_param->_nb_spr_read; j++)
359      {
360        sensitive << *(in_SPR_READ_VAL           [j]);
361        if (_param->_have_port_ooo_engine_id == true)
362          sensitive << *(in_SPR_READ_OOO_ENGINE_ID [j]);
363
364        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
365          sensitive << *(in_SPR_READ_STATUS_ACK        [i][j]);
366      }
367
368#ifdef SYSTEMCASS_SPECIFIC
369    // List dependency information
370    for (uint32_t j=0; j<_param->_nb_spr_read; j++)
371      {
372        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
373          {
374            (*(out_SPR_READ_REGISTERFILE_VAL  [i][j])) (*( in_SPR_READ_VAL                  [j]));
375            (*(out_SPR_READ_REGISTERFILE_VAL  [i][j])) (*( in_SPR_READ_STATUS_ACK        [i][j]));
376            if (_param->_have_port_ooo_engine_id == true)
377            (*(out_SPR_READ_REGISTERFILE_VAL  [i][j])) (*( in_SPR_READ_OOO_ENGINE_ID        [j]));
378          }
379      }
380#endif   
381
382    log_printf(INFO,Register_unit_Glue,FUNCTION,"Method - genMealy_spr_write");
383
384    SC_METHOD (genMealy_spr_write);
385    dont_initialize ();
386//     sensitive << (*(in_CLOCK)).neg();
387    sensitive << (*(in_NRESET));
388    for (uint32_t j=0; j<_param->_nb_spr_write; j++)
389      {
390        if (_param->_have_port_ooo_engine_id == true)
391          sensitive << *(in_SPR_WRITE_OOO_ENGINE_ID [j]);
392
393        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
394          sensitive << *(in_SPR_WRITE_REGISTERFILE_ACK  [i][j])
395                    << *(in_SPR_WRITE_STATUS_ACK        [i][j]);
396      }
397
398#ifdef SYSTEMCASS_SPECIFIC
399    // List dependency information
400    for (uint32_t j=0; j<_param->_nb_spr_write; j++)
401      {
402        if (_param->_have_port_ooo_engine_id == true)
403        (*(out_SPR_WRITE_ACK                  [j])) (*( in_SPR_WRITE_OOO_ENGINE_ID        [j]));
404                   
405        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
406          {
407            (*(out_SPR_WRITE_ACK                  [j])) (*( in_SPR_WRITE_REGISTERFILE_ACK  [i][j]));
408            (*(out_SPR_WRITE_ACK                  [j])) (*( in_SPR_WRITE_STATUS_ACK        [i][j]));
409          }
410      }
411#endif   
412
413    log_printf(INFO,Register_unit_Glue,FUNCTION,"Method - genMealy_spr_write_status");
414
415    SC_METHOD (genMealy_spr_write_status);
416    dont_initialize ();
417//     sensitive << (*(in_CLOCK)).neg();
418    sensitive << (*(in_NRESET));
419    for (uint32_t j=0; j<_param->_nb_spr_write; j++)
420      {
421        sensitive << *(in_SPR_WRITE_VAL           [j]);
422        if (_param->_have_port_ooo_engine_id == true)
423          sensitive << *(in_SPR_WRITE_OOO_ENGINE_ID [j]);
424
425        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
426          sensitive << *(in_SPR_WRITE_REGISTERFILE_ACK  [i][j]);
427      }
428
429#ifdef SYSTEMCASS_SPECIFIC
430    // List dependency information
431    for (uint32_t j=0; j<_param->_nb_spr_write; j++)
432      {
433        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
434          {
435            (*(out_SPR_WRITE_STATUS_VAL        [i][j])) (*( in_SPR_WRITE_VAL                  [j]));
436            (*(out_SPR_WRITE_STATUS_VAL        [i][j])) (*( in_SPR_WRITE_REGISTERFILE_ACK  [i][j]));
437            if (_param->_have_port_ooo_engine_id == true)
438            (*(out_SPR_WRITE_STATUS_VAL        [i][j])) (*( in_SPR_WRITE_OOO_ENGINE_ID        [j]));
439          }
440      }
441#endif   
442
443    log_printf(INFO,Register_unit_Glue,FUNCTION,"Method - genMealy_spr_write_registerfile");
444
445    SC_METHOD (genMealy_spr_write_registerfile);
446    dont_initialize ();
447//     sensitive << (*(in_CLOCK)).neg();
448    sensitive << (*(in_NRESET));
449    for (uint32_t j=0; j<_param->_nb_spr_write; j++)
450      {
451        sensitive << *(in_SPR_WRITE_VAL           [j]);
452        if (_param->_have_port_ooo_engine_id == true)
453          sensitive << *(in_SPR_WRITE_OOO_ENGINE_ID [j]);
454
455        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
456          sensitive << *(in_SPR_WRITE_STATUS_ACK        [i][j]);
457      }
458
459#ifdef SYSTEMCASS_SPECIFIC
460    // List dependency information
461    for (uint32_t j=0; j<_param->_nb_spr_write; j++)
462      {
463        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
464          {
465            (*(out_SPR_WRITE_REGISTERFILE_VAL  [i][j])) (*( in_SPR_WRITE_VAL                  [j]));
466            (*(out_SPR_WRITE_REGISTERFILE_VAL  [i][j])) (*( in_SPR_WRITE_STATUS_ACK        [i][j]));
467            if (_param->_have_port_ooo_engine_id == true)
468            (*(out_SPR_WRITE_REGISTERFILE_VAL  [i][j])) (*( in_SPR_WRITE_OOO_ENGINE_ID        [j]));
469          }
470      }
471#endif   
472
473    log_printf(INFO,Register_unit_Glue,FUNCTION,"Method - genMealy_insert");
474
475    SC_METHOD (genMealy_insert);
476    dont_initialize ();
477//     sensitive << (*(in_CLOCK)).neg();
478    sensitive << (*(in_NRESET));
479    for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
480      {
481        uint32_t x=_param->_nb_inst_insert_rob [i];
482        for (uint32_t j=0; j<x; j++)
483          sensitive << *( in_INSERT_ROB_VAL            [i][j])
484                    << *( in_INSERT_ROB_RD_USE         [i][j]) 
485                    << *( in_INSERT_ROB_RE_USE         [i][j]) 
486                    << *( in_INSERT_ROB_GPR_STATUS_ACK [i][j])
487                    << *( in_INSERT_ROB_SPR_STATUS_ACK [i][j]);
488      }
489#ifdef SYSTEMCASS_SPECIFIC
490    // List dependency information
491    for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
492      {
493        uint32_t x=_param->_nb_inst_insert_rob [i];
494        for (uint32_t j=0; j<x; j++)
495          {
496            (*(out_INSERT_ROB_ACK            [i][j]))(*( in_INSERT_ROB_GPR_STATUS_ACK [i][j]));
497            (*(out_INSERT_ROB_ACK            [i][j]))(*( in_INSERT_ROB_SPR_STATUS_ACK [i][j]));
498
499            (*(out_INSERT_ROB_GPR_STATUS_VAL [i][j]))(*( in_INSERT_ROB_VAL            [i][j]));
500            (*(out_INSERT_ROB_GPR_STATUS_VAL [i][j]))(*( in_INSERT_ROB_RD_USE         [i][j])); 
501            (*(out_INSERT_ROB_GPR_STATUS_VAL [i][j]))(*( in_INSERT_ROB_SPR_STATUS_ACK [i][j]));
502
503            (*(out_INSERT_ROB_SPR_STATUS_VAL [i][j]))(*( in_INSERT_ROB_VAL            [i][j])); 
504            (*(out_INSERT_ROB_SPR_STATUS_VAL [i][j]))(*( in_INSERT_ROB_RE_USE         [i][j]));
505            (*(out_INSERT_ROB_SPR_STATUS_VAL [i][j]))(*( in_INSERT_ROB_GPR_STATUS_ACK [i][j]));
506          }
507      }
508#endif   
509
510//     log_printf(INFO,Register_unit_Glue,FUNCTION,"Method - genMealy_retire");
511
512//     SC_METHOD (genMealy_retire);
513//     dont_initialize ();
514// //     sensitive << (*(in_CLOCK)).neg();
515//     for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
516//       {
517//      uint32_t x=_param->_nb_inst_retire_rob [i];
518//      for (uint32_t j=0; j<x; j++)
519//        sensitive << *( in_RETIRE_ROB_VAL                [i][j])
520//                  << *( in_RETIRE_ROB_RD_OLD_USE         [i][j])
521//                  << *( in_RETIRE_ROB_RD_NEW_USE         [i][j])
522//                  << *( in_RETIRE_ROB_RE_OLD_USE         [i][j])
523//                  << *( in_RETIRE_ROB_RE_NEW_USE         [i][j])
524//                  << *( in_RETIRE_ROB_GPR_STATUS_NEW_ACK [i][j])
525//                  << *( in_RETIRE_ROB_GPR_STATUS_OLD_ACK [i][j])
526//                  << *( in_RETIRE_ROB_SPR_STATUS_NEW_ACK [i][j])
527//                  << *( in_RETIRE_ROB_SPR_STATUS_OLD_ACK [i][j]);
528//       }
529// #ifdef SYSTEMCASS_SPECIFIC
530//     // List dependency information
531//     for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
532//       {
533//      uint32_t x=_param->_nb_inst_retire_rob [i];
534//      for (uint32_t j=0; j<x; j++)
535//        {
536//          (*(out_RETIRE_ROB_ACK                [i][j]))(*( in_RETIRE_ROB_GPR_STATUS_NEW_ACK [i][j]));
537//          (*(out_RETIRE_ROB_ACK                [i][j]))(*( in_RETIRE_ROB_GPR_STATUS_OLD_ACK [i][j]));
538//          (*(out_RETIRE_ROB_ACK                [i][j]))(*( in_RETIRE_ROB_SPR_STATUS_NEW_ACK [i][j]));
539//          (*(out_RETIRE_ROB_ACK                [i][j]))(*( in_RETIRE_ROB_SPR_STATUS_OLD_ACK [i][j]));
540
541//          (*(out_RETIRE_ROB_GPR_STATUS_OLD_VAL [i][j]))(*( in_RETIRE_ROB_VAL                [i][j]));
542//          (*(out_RETIRE_ROB_GPR_STATUS_OLD_VAL [i][j]))(*( in_RETIRE_ROB_RD_OLD_USE         [i][j]));
543//          (*(out_RETIRE_ROB_GPR_STATUS_OLD_VAL [i][j]))(*( in_RETIRE_ROB_GPR_STATUS_NEW_ACK [i][j]));
544//          (*(out_RETIRE_ROB_GPR_STATUS_OLD_VAL [i][j]))(*( in_RETIRE_ROB_SPR_STATUS_NEW_ACK [i][j]));
545//          (*(out_RETIRE_ROB_GPR_STATUS_OLD_VAL [i][j]))(*( in_RETIRE_ROB_SPR_STATUS_OLD_ACK [i][j]));
546
547//          (*(out_RETIRE_ROB_GPR_STATUS_NEW_VAL [i][j]))(*( in_RETIRE_ROB_VAL                [i][j]));
548//          (*(out_RETIRE_ROB_GPR_STATUS_NEW_VAL [i][j]))(*( in_RETIRE_ROB_RD_NEW_USE         [i][j]));
549//          (*(out_RETIRE_ROB_GPR_STATUS_NEW_VAL [i][j]))(*( in_RETIRE_ROB_GPR_STATUS_OLD_ACK [i][j]));
550//          (*(out_RETIRE_ROB_GPR_STATUS_NEW_VAL [i][j]))(*( in_RETIRE_ROB_SPR_STATUS_NEW_ACK [i][j]));
551//          (*(out_RETIRE_ROB_GPR_STATUS_NEW_VAL [i][j]))(*( in_RETIRE_ROB_SPR_STATUS_OLD_ACK [i][j]));
552
553//          (*(out_RETIRE_ROB_SPR_STATUS_OLD_VAL [i][j]))(*( in_RETIRE_ROB_VAL                [i][j]));
554//          (*(out_RETIRE_ROB_SPR_STATUS_OLD_VAL [i][j]))(*( in_RETIRE_ROB_RE_OLD_USE         [i][j]));
555//          (*(out_RETIRE_ROB_SPR_STATUS_OLD_VAL [i][j]))(*( in_RETIRE_ROB_GPR_STATUS_NEW_ACK [i][j]));
556//          (*(out_RETIRE_ROB_SPR_STATUS_OLD_VAL [i][j]))(*( in_RETIRE_ROB_GPR_STATUS_OLD_ACK [i][j]));
557//          (*(out_RETIRE_ROB_SPR_STATUS_OLD_VAL [i][j]))(*( in_RETIRE_ROB_SPR_STATUS_NEW_ACK [i][j]));
558
559//          (*(out_RETIRE_ROB_SPR_STATUS_NEW_VAL [i][j]))(*( in_RETIRE_ROB_VAL                [i][j]));
560//          (*(out_RETIRE_ROB_SPR_STATUS_NEW_VAL [i][j]))(*( in_RETIRE_ROB_RE_NEW_USE         [i][j]));
561//          (*(out_RETIRE_ROB_SPR_STATUS_NEW_VAL [i][j]))(*( in_RETIRE_ROB_GPR_STATUS_NEW_ACK [i][j]));
562//          (*(out_RETIRE_ROB_SPR_STATUS_NEW_VAL [i][j]))(*( in_RETIRE_ROB_GPR_STATUS_OLD_ACK [i][j]));
563//          (*(out_RETIRE_ROB_SPR_STATUS_NEW_VAL [i][j]))(*( in_RETIRE_ROB_SPR_STATUS_OLD_ACK [i][j]));
564//        }
565//       }
566// #endif   
567      }
568#endif
569    log_printf(FUNC,Register_unit_Glue,FUNCTION,"End");
570  };
571 
572#undef  FUNCTION
573#define FUNCTION "Register_unit_Glue::~Register_unit_Glue"
574  Register_unit_Glue::~Register_unit_Glue (void)
575  {
576    log_printf(FUNC,Register_unit_Glue,FUNCTION,"Begin");
577
578#ifdef STATISTICS
579    if (usage_is_set(_usage,USE_STATISTICS))
580      {
581        log_printf(INFO,Register_unit_Glue,FUNCTION,"Generate Statistics file");
582       
583        delete _stat;
584      }
585#endif
586
587    log_printf(INFO,Register_unit_Glue,FUNCTION,"Deallocation");
588    deallocation ();
589
590    log_printf(FUNC,Register_unit_Glue,FUNCTION,"End");
591  };
592
593}; // end namespace register_unit_glue
594}; // end namespace register_unit
595}; // end namespace execute_loop
596}; // end namespace multi_execute_loop
597}; // end namespace core
598
599}; // end namespace behavioural
600}; // end namespace morpheo             
601
602
603
Note: See TracBrowser for help on using the repository browser.