source: trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/src/Execute_loop_allocation.cpp @ 112

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

1) Stat_list : fix retire old and new register bug
2) Stat_list : remove read_counter and valid flag, because validation of destination is in retire step (not in commit step)
3) Model : add class Model (cf Morpheo.sim)
4) Allocation : alloc_interface_begin and alloc_interface_end to delete temporary array.
5) Script : add distexe.sh
6) Add Comparator, Multiplier, Divider. But this component are not implemented
7) Software : add Dhrystone

  • Property svn:keywords set to Id
File size: 96.5 KB
Line 
1/*
2 * $Id: Execute_loop_allocation.cpp 112 2009-03-18 22:36:26Z rosiere $
3 *
4 * [ Description ]
5 *
6 */
7
8#include "Behavioural/Core/Multi_Execute_loop/Execute_loop/include/Execute_loop.h"
9#include "Behavioural/include/Allocation.h"
10
11namespace morpheo                    {
12namespace behavioural {
13namespace core {
14namespace multi_execute_loop {
15namespace execute_loop {
16
17
18
19#undef  FUNCTION
20#define FUNCTION "Execute_loop::allocation"
21  void Execute_loop::allocation (
22#ifdef STATISTICS
23                               morpheo::behavioural::Parameters_Statistics * param_statistics
24#else
25                               void
26#endif
27                               )
28  {
29    log_printf(FUNC,Execute_loop,FUNCTION,"Begin");
30
31    _component   = new Component (_usage);
32
33    Entity * entity = _component->set_entity (_name       
34                                              ,"Execute_loop"
35#ifdef POSITION
36                                              ,COMBINATORY
37#endif
38                                              );
39
40    _interfaces = entity->set_interfaces();
41
42    // ~~~~~[ Interface : "" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
43
44      Interface * interface = _interfaces->set_interface(""
45#ifdef POSITION
46                                                         ,IN
47                                                         ,SOUTH,
48                                                         "Generalist interface"
49#endif
50                                                         );
51
52     in_CLOCK        = interface->set_signal_clk              ("clock" ,1, CLOCK_VHDL_YES);
53     in_NRESET       = interface->set_signal_in  <Tcontrol_t> ("nreset",1, RESET_VHDL_YES);
54
55    // ~~~~~[ Interface "execute_loop_in" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
56     {
57       ALLOC1_INTERFACE_BEGIN("execute_loop_in", IN, EAST, "Operation's Input", _param->_nb_read_unit);
58
59       ALLOC1_VALACK_IN ( in_EXECUTE_LOOP_IN_VAL,VAL);
60       ALLOC1_VALACK_OUT(out_EXECUTE_LOOP_IN_ACK,ACK);
61       ALLOC1_SIGNAL_IN ( in_EXECUTE_LOOP_IN_CONTEXT_ID           ,"context_id"           ,Tcontext_t        ,_param->_size_context_id);
62       ALLOC1_SIGNAL_IN ( in_EXECUTE_LOOP_IN_FRONT_END_ID         ,"front_end_id"         ,Tcontext_t        ,_param->_size_front_end_id);
63       ALLOC1_SIGNAL_IN ( in_EXECUTE_LOOP_IN_OOO_ENGINE_ID        ,"ooo_engine_id"        ,Tcontext_t        ,_param->_size_ooo_engine_id);
64       ALLOC1_SIGNAL_IN ( in_EXECUTE_LOOP_IN_PACKET_ID            ,"packet_id"            ,Tpacket_t         ,_param->_size_rob_ptr  );
65       ALLOC1_SIGNAL_IN ( in_EXECUTE_LOOP_IN_OPERATION            ,"operation"            ,Toperation_t      ,_param->_size_operation);
66       ALLOC1_SIGNAL_IN ( in_EXECUTE_LOOP_IN_TYPE                 ,"type"                 ,Ttype_t           ,_param->_size_type);         
67       ALLOC1_SIGNAL_IN ( in_EXECUTE_LOOP_IN_STORE_QUEUE_PTR_WRITE,"store_queue_ptr_write",Tlsq_ptr_t        ,_param->_size_store_queue_ptr);
68       ALLOC1_SIGNAL_IN ( in_EXECUTE_LOOP_IN_LOAD_QUEUE_PTR_WRITE ,"load_queue_ptr_write" ,Tlsq_ptr_t        ,_param->_size_load_queue_ptr);
69       ALLOC1_SIGNAL_IN ( in_EXECUTE_LOOP_IN_HAS_IMMEDIAT         ,"has_immediat"         ,Tcontrol_t        ,1);
70       ALLOC1_SIGNAL_IN ( in_EXECUTE_LOOP_IN_IMMEDIAT             ,"immediat"             ,Tgeneral_data_t   ,_param->_size_general_data);
71       ALLOC1_SIGNAL_IN ( in_EXECUTE_LOOP_IN_READ_RA              ,"read_ra"              ,Tcontrol_t        ,1);
72       ALLOC1_SIGNAL_IN ( in_EXECUTE_LOOP_IN_NUM_REG_RA           ,"num_reg_ra"           ,Tgeneral_address_t,_param->_size_general_register);
73       ALLOC1_SIGNAL_IN ( in_EXECUTE_LOOP_IN_READ_RB              ,"read_rb"              ,Tcontrol_t        ,1);
74       ALLOC1_SIGNAL_IN ( in_EXECUTE_LOOP_IN_NUM_REG_RB           ,"num_reg_rb"           ,Tgeneral_address_t,_param->_size_general_register);
75       ALLOC1_SIGNAL_IN ( in_EXECUTE_LOOP_IN_READ_RC              ,"read_rc"              ,Tcontrol_t        ,1);
76       ALLOC1_SIGNAL_IN ( in_EXECUTE_LOOP_IN_NUM_REG_RC           ,"num_reg_rc"           ,Tspecial_address_t,_param->_size_special_register);
77       ALLOC1_SIGNAL_IN ( in_EXECUTE_LOOP_IN_WRITE_RD             ,"write_rd"             ,Tcontrol_t        ,1);
78       ALLOC1_SIGNAL_IN ( in_EXECUTE_LOOP_IN_NUM_REG_RD           ,"num_reg_rd"           ,Tgeneral_address_t,_param->_size_general_register);
79       ALLOC1_SIGNAL_IN ( in_EXECUTE_LOOP_IN_WRITE_RE             ,"write_re"             ,Tcontrol_t        ,1);
80       ALLOC1_SIGNAL_IN ( in_EXECUTE_LOOP_IN_NUM_REG_RE           ,"num_reg_re"           ,Tspecial_address_t,_param->_size_special_register);
81
82       ALLOC1_INTERFACE_END(param->_nb_read_unit);
83     }
84    // ~~~~~[ Interface "execute_loop_out" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
85     {
86       ALLOC1_INTERFACE_BEGIN("execute_loop_out",OUT, EAST, "Operation's Output", _param->_nb_write_unit);
87
88       ALLOC1_VALACK_OUT(out_EXECUTE_LOOP_OUT_VAL,VAL);
89       ALLOC1_VALACK_IN ( in_EXECUTE_LOOP_OUT_ACK,ACK);
90       ALLOC1_SIGNAL_OUT(out_EXECUTE_LOOP_OUT_CONTEXT_ID   ,"context_id"   ,Tcontext_t     ,_param->_size_context_id);
91       ALLOC1_SIGNAL_OUT(out_EXECUTE_LOOP_OUT_FRONT_END_ID ,"front_end_id" ,Tcontext_t     ,_param->_size_front_end_id);
92       ALLOC1_SIGNAL_OUT(out_EXECUTE_LOOP_OUT_OOO_ENGINE_ID,"ooo_engine_id",Tcontext_t     ,_param->_size_ooo_engine_id);
93       ALLOC1_SIGNAL_OUT(out_EXECUTE_LOOP_OUT_PACKET_ID    ,"packet_id"    ,Tpacket_t      ,_param->_size_rob_ptr  );
94//     ALLOC1_SIGNAL_OUT(out_EXECUTE_LOOP_OUT_OPERATION    ,"operation"    ,Toperation_t   ,_param->_size_operation);
95//     ALLOC1_SIGNAL_OUT(out_EXECUTE_LOOP_OUT_TYPE         ,"type"         ,Ttype_t        ,_param->_size_type);
96       ALLOC1_SIGNAL_OUT(out_EXECUTE_LOOP_OUT_FLAGS        ,"flags"        ,Tspecial_data_t,_param->_size_special_data);
97       ALLOC1_SIGNAL_OUT(out_EXECUTE_LOOP_OUT_EXCEPTION    ,"exception"    ,Texception_t   ,_param->_size_exception);
98       ALLOC1_SIGNAL_OUT(out_EXECUTE_LOOP_OUT_NO_SEQUENCE  ,"no_sequence"  ,Tcontrol_t     ,1);
99       ALLOC1_SIGNAL_OUT(out_EXECUTE_LOOP_OUT_ADDRESS      ,"address"      ,Taddress_t     ,_param->_size_instruction_address);
100       ALLOC1_SIGNAL_OUT(out_EXECUTE_LOOP_OUT_DATA         ,"data"         ,Tgeneral_data_t,_param->_size_general_data);
101
102       ALLOC1_INTERFACE_END(_param->_nb_write_unit);
103     }
104    // ~~~~~[ Interface "dcache_req" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
105     {
106       ALLOC2_INTERFACE_BEGIN("dcache_req",OUT, NORTH, "Data cache port : request", _param->_nb_load_store_unit, _param->_nb_cache_port[it1]);
107       
108       _ALLOC2_VALACK_OUT(out_DCACHE_REQ_VAL,VAL, _param->_nb_load_store_unit, _param->_nb_cache_port[it1]);
109       _ALLOC2_VALACK_IN ( in_DCACHE_REQ_ACK,ACK, _param->_nb_load_store_unit, _param->_nb_cache_port[it1]);
110       _ALLOC2_SIGNAL_OUT(out_DCACHE_REQ_CONTEXT_ID,"context_id",Tcontext_t       ,_param->_max_size_dcache_context_id, _param->_nb_load_store_unit, _param->_nb_cache_port[it1]);
111       _ALLOC2_SIGNAL_OUT(out_DCACHE_REQ_PACKET_ID ,"packet_id" ,Tpacket_t        ,_param->_max_size_dcache_packet_id , _param->_nb_load_store_unit, _param->_nb_cache_port[it1]);
112       _ALLOC2_SIGNAL_OUT(out_DCACHE_REQ_ADDRESS   ,"address"   ,Tdcache_address_t,_param->_size_general_data         , _param->_nb_load_store_unit, _param->_nb_cache_port[it1]);
113       _ALLOC2_SIGNAL_OUT(out_DCACHE_REQ_TYPE      ,"type"      ,Tdcache_type_t   ,_param->_size_dcache_type          , _param->_nb_load_store_unit, _param->_nb_cache_port[it1]);
114       _ALLOC2_SIGNAL_OUT(out_DCACHE_REQ_WDATA     ,"wdata"     ,Tdcache_data_t   ,_param->_size_general_data         , _param->_nb_load_store_unit, _param->_nb_cache_port[it1]);
115
116       ALLOC2_INTERFACE_END(_param->_nb_load_store_unit, _param->_nb_cache_port[it1]);
117     }
118
119    // ~~~~~[ Interface "dcache_rsp" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
120     {
121       ALLOC2_INTERFACE_BEGIN("dcache_rsp",IN, NORTH, "Data cache port : respons", _param->_nb_load_store_unit, _param->_nb_cache_port[it1]);
122
123       _ALLOC2_VALACK_IN ( in_DCACHE_RSP_VAL,VAL, _param->_nb_load_store_unit, _param->_nb_cache_port[it1]);
124       _ALLOC2_VALACK_OUT(out_DCACHE_RSP_ACK,ACK, _param->_nb_load_store_unit, _param->_nb_cache_port[it1]);
125       _ALLOC2_SIGNAL_IN ( in_DCACHE_RSP_CONTEXT_ID,"context_id",Tcontext_t     ,_param->_max_size_dcache_context_id, _param->_nb_load_store_unit, _param->_nb_cache_port[it1]);
126       _ALLOC2_SIGNAL_IN ( in_DCACHE_RSP_PACKET_ID ,"packet_id" ,Tpacket_t      ,_param->_max_size_dcache_packet_id , _param->_nb_load_store_unit, _param->_nb_cache_port[it1]);
127       _ALLOC2_SIGNAL_IN ( in_DCACHE_RSP_RDATA     ,"rdata"     ,Tdcache_data_t ,_param->_size_general_data         , _param->_nb_load_store_unit, _param->_nb_cache_port[it1]);
128       _ALLOC2_SIGNAL_IN ( in_DCACHE_RSP_ERROR     ,"error"     ,Tdcache_error_t,_param->_size_dcache_error         , _param->_nb_load_store_unit, _param->_nb_cache_port[it1]);
129
130       ALLOC2_INTERFACE_END(_param->_nb_load_store_unit, _param->_nb_cache_port[it1]);
131     }
132
133    // ~~~~~[ Interface "insert_rob" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
134     {
135       ALLOC2_INTERFACE_BEGIN("insert_rob",IN, EAST, "Rename's stage : insert a new instruction in the Re Order Buffer",_param->_nb_ooo_engine,_param->_nb_inst_insert_rob[it1]);
136       
137       _ALLOC2_VALACK_IN ( in_INSERT_ROB_VAL,VAL,_param->_nb_ooo_engine,_param->_nb_inst_insert_rob[it1]);
138       _ALLOC2_VALACK_OUT(out_INSERT_ROB_ACK,ACK,_param->_nb_ooo_engine,_param->_nb_inst_insert_rob[it1]);
139
140       _ALLOC2_SIGNAL_IN ( in_INSERT_ROB_RD_USE    ,"rd_use"    ,Tcontrol_t        ,1                             ,_param->_nb_ooo_engine,_param->_nb_inst_insert_rob[it1]);
141       _ALLOC2_SIGNAL_IN ( in_INSERT_ROB_RD_NUM_REG,"rd_num_reg",Tgeneral_address_t,_param->_size_general_register,_param->_nb_ooo_engine,_param->_nb_inst_insert_rob[it1]);
142       _ALLOC2_SIGNAL_IN ( in_INSERT_ROB_RE_USE    ,"re_use"    ,Tcontrol_t        ,1                             ,_param->_nb_ooo_engine,_param->_nb_inst_insert_rob[it1]);
143       _ALLOC2_SIGNAL_IN ( in_INSERT_ROB_RE_NUM_REG,"re_num_reg",Tspecial_address_t,_param->_size_special_register,_param->_nb_ooo_engine,_param->_nb_inst_insert_rob[it1]);
144
145       ALLOC2_INTERFACE_END(_param->_nb_ooo_engine,_param->_nb_inst_insert_rob[it1]);
146     }
147
148//     // ~~~~~[ Interface "retire_rob" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
149//      {
150//        ALLOC2_INTERFACE("retire_rob",IN, EAST, "Rename's stage : retire a new instruction in the Re Order Buffer",_param->_nb_ooo_engine,_param->_nb_inst_retire_rob[it1]);
151       
152//        _ALLOC2_VALACK_IN ( in_RETIRE_ROB_VAL,VAL,_param->_nb_ooo_engine,_param->_nb_inst_retire_rob[it1]);
153//        _ALLOC2_VALACK_OUT(out_RETIRE_ROB_ACK,ACK,_param->_nb_ooo_engine,_param->_nb_inst_retire_rob[it1]);
154
155//        _ALLOC2_SIGNAL_IN ( in_RETIRE_ROB_RD_OLD_USE    ,"rd_old_use"    ,Tcontrol_t        ,1                             ,_param->_nb_ooo_engine,_param->_nb_inst_retire_rob[it1]);
156//        _ALLOC2_SIGNAL_IN ( in_RETIRE_ROB_RD_OLD_NUM_REG,"rd_old_num_reg",Tgeneral_address_t,_param->_size_general_register,_param->_nb_ooo_engine,_param->_nb_inst_retire_rob[it1]);
157//        _ALLOC2_SIGNAL_IN ( in_RETIRE_ROB_RD_NEW_USE    ,"rd_new_use"    ,Tcontrol_t        ,1                             ,_param->_nb_ooo_engine,_param->_nb_inst_retire_rob[it1]);
158//        _ALLOC2_SIGNAL_IN ( in_RETIRE_ROB_RD_NEW_NUM_REG,"rd_new_num_reg",Tgeneral_address_t,_param->_size_general_register,_param->_nb_ooo_engine,_param->_nb_inst_retire_rob[it1]);
159//        _ALLOC2_SIGNAL_IN ( in_RETIRE_ROB_RE_OLD_USE    ,"re_old_use"    ,Tcontrol_t        ,1                             ,_param->_nb_ooo_engine,_param->_nb_inst_retire_rob[it1]);
160//        _ALLOC2_SIGNAL_IN ( in_RETIRE_ROB_RE_OLD_NUM_REG,"re_old_num_reg",Tspecial_address_t,_param->_size_special_register,_param->_nb_ooo_engine,_param->_nb_inst_retire_rob[it1]);
161//        _ALLOC2_SIGNAL_IN ( in_RETIRE_ROB_RE_NEW_USE    ,"re_new_use"    ,Tcontrol_t        ,1                             ,_param->_nb_ooo_engine,_param->_nb_inst_retire_rob[it1]);
162//        _ALLOC2_SIGNAL_IN ( in_RETIRE_ROB_RE_NEW_NUM_REG,"re_new_num_reg",Tspecial_address_t,_param->_size_special_register,_param->_nb_ooo_engine,_param->_nb_inst_retire_rob[it1]);
163//      }
164
165     // ~~~~~[ Component ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~   
166     std::string name;
167
168     {
169       name = _name+"_glue";
170       log_printf(INFO,Core,FUNCTION,_("Create   : %s"),name.c_str());
171       
172       _component_glue = new morpheo::behavioural::core::multi_execute_loop::execute_loop::execute_loop_glue::Execute_loop_Glue
173         (name.c_str()
174#ifdef STATISTICS
175          ,param_statistics
176#endif
177          ,_param->_param_glue
178          ,_usage);
179       
180       _component->set_component (_component_glue->_component
181#ifdef POSITION
182                                  , 50, 50, 10, 10
183#endif
184                                  );
185     }
186       
187     _component_read_unit = new morpheo::behavioural::core::multi_execute_loop::execute_loop::multi_read_unit::read_unit::Read_unit * [_param->_nb_read_unit];
188     for (uint32_t i=0; i<_param->_nb_read_unit; i++)
189       {
190         name = _name+"_read_unit_"+toString(i);
191         log_printf(INFO,Core,FUNCTION,_("Create   : %s"),name.c_str());
192
193         _component_read_unit [i] = new morpheo::behavioural::core::multi_execute_loop::execute_loop::multi_read_unit::read_unit::Read_unit
194           (name.c_str()
195#ifdef STATISTICS
196            ,param_statistics
197#endif
198            ,_param->_param_read_unit[i]
199            ,_usage);
200
201         _component->set_component (_component_read_unit [i]->_component
202#ifdef POSITION
203                                    , 50, 50, 10, 10
204#endif
205                                    );
206       }
207
208     _component_functionnal_unit = new morpheo::behavioural::core::multi_execute_loop::execute_loop::multi_execute_unit::execute_unit::functionnal_unit::Functionnal_unit * [_param->_nb_functionnal_unit];
209     for (uint32_t i=0; i<_param->_nb_functionnal_unit; i++)
210       {
211         name = _name+"_functionnal_unit_"+toString(i);
212         log_printf(INFO,Core,FUNCTION,_("Create   : %s"),name.c_str());
213
214         _component_functionnal_unit [i] = new morpheo::behavioural::core::multi_execute_loop::execute_loop::multi_execute_unit::execute_unit::functionnal_unit::Functionnal_unit
215           (name.c_str()
216#ifdef STATISTICS
217            ,param_statistics
218#endif
219            ,_param->_param_functionnal_unit[i]
220            ,_usage);
221
222         _component->set_component (_component_functionnal_unit [i]->_component
223#ifdef POSITION
224                                    , 50, 50, 10, 10
225#endif
226                                    );
227       }
228
229     _component_load_store_unit = new morpheo::behavioural::core::multi_execute_loop::execute_loop::multi_execute_unit::execute_unit::load_store_unit::Load_store_unit * [_param->_nb_load_store_unit];
230     for (uint32_t i=0; i<_param->_nb_load_store_unit; i++)
231       {
232         name = _name+"_load_store_unit_"+toString(i);
233         log_printf(INFO,Core,FUNCTION,_("Create   : %s"),name.c_str());
234
235         _component_load_store_unit [i] = new morpheo::behavioural::core::multi_execute_loop::execute_loop::multi_execute_unit::execute_unit::load_store_unit::Load_store_unit
236           (name.c_str()
237#ifdef STATISTICS
238            ,param_statistics
239#endif
240            ,_param->_param_load_store_unit[i]
241            ,_usage);
242
243         _component->set_component (_component_load_store_unit [i]->_component
244#ifdef POSITION
245                                    , 50, 50, 10, 10
246#endif
247                                    );
248       }
249
250     _component_write_unit = new morpheo::behavioural::core::multi_execute_loop::execute_loop::multi_write_unit::write_unit::Write_unit * [_param->_nb_write_unit];
251     for (uint32_t i=0; i<_param->_nb_write_unit; i++)
252       {
253         name = _name+"_write_unit_"+toString(i);
254         log_printf(INFO,Core,FUNCTION,_("Create   : %s"),name.c_str());
255
256         _component_write_unit [i] = new morpheo::behavioural::core::multi_execute_loop::execute_loop::multi_write_unit::write_unit::Write_unit
257           (name.c_str()
258#ifdef STATISTICS
259            ,param_statistics
260#endif
261            ,_param->_param_write_unit[i]
262            ,_usage);
263
264         _component->set_component (_component_write_unit [i]->_component
265#ifdef POSITION
266                                    , 50, 50, 10, 10
267#endif
268                                    );
269       }
270     
271     {
272       name = _name+"_read_unit_to_execution_unit";
273       log_printf(INFO,Core,FUNCTION,_("Create   : %s"),name.c_str());
274       
275       _component_read_unit_to_execution_unit = new morpheo::behavioural::core::multi_execute_loop::execute_loop::network::read_unit_to_execution_unit::Read_unit_to_Execution_unit
276         (name.c_str()
277#ifdef STATISTICS
278          ,param_statistics
279#endif
280          ,_param->_param_read_unit_to_execution_unit
281          ,_usage);
282       
283       _component->set_component (_component_read_unit_to_execution_unit->_component
284#ifdef POSITION
285                                  , 50, 50, 10, 10
286#endif
287                                  );
288     }
289
290     {
291       name = _name+"_execution_unit_to_write_unit";
292       log_printf(INFO,Core,FUNCTION,_("Create   : %s"),name.c_str());
293       
294       _component_execution_unit_to_write_unit = new morpheo::behavioural::core::multi_execute_loop::execute_loop::network::execution_unit_to_write_unit::Execution_unit_to_Write_unit
295         (name.c_str()
296#ifdef STATISTICS
297          ,param_statistics
298#endif
299          ,_param->_param_execution_unit_to_write_unit
300          ,_usage);
301       
302       _component->set_component (_component_execution_unit_to_write_unit->_component
303#ifdef POSITION
304                                  , 50, 50, 10, 10
305#endif
306                                  );
307     }
308
309     {
310       name = _name+"_register_unit";
311       log_printf(INFO,Core,FUNCTION,_("Create   : %s"),name.c_str());
312       
313       _component_register_unit = new morpheo::behavioural::core::multi_execute_loop::execute_loop::register_unit::Register_unit
314         (name.c_str()
315#ifdef STATISTICS
316          ,param_statistics
317#endif
318          ,_param->_param_register_unit
319          ,_usage);
320       
321       _component->set_component (_component_register_unit->_component
322#ifdef POSITION
323                                  , 50, 50, 10, 10
324#endif
325                                  );
326     }
327
328     // ~~~~~[ Instanciation ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~   
329     std::string src,dest;
330
331     // ===================================================================
332     // =====[ GLUE ]======================================================
333     // ===================================================================
334     {
335       src = _name+"_glue";
336       log_printf(INFO,Core,FUNCTION,_("Instance : %s"),src.c_str());
337       
338       {
339         dest = _name;
340#ifdef POSITION
341         _component->interface_map (src ,"",
342                                    dest,"");
343#endif
344         PORT_MAP(_component ,src , "in_CLOCK" ,dest, "in_CLOCK");
345         PORT_MAP(_component ,src , "in_NRESET",dest, "in_NRESET");
346       }
347
348       for (uint32_t i=0; i<_param->_nb_gpr_write; i++)
349         {
350           {
351             dest = _name+"_write_unit_"+toString(i);
352             
353#ifdef POSITION
354             _component->interface_map (src ,"gpr_write_write_unit_"+toString(i),
355                                        dest,"gpr_write");
356#endif
357
358             //  in_GPR_WRITE_WRITE_UNIT_VAL               
359             // out_GPR_WRITE_WRITE_UNIT_ACK               
360             //  in_GPR_WRITE_WRITE_UNIT_OOO_ENGINE_ID     
361             //  in_GPR_WRITE_WRITE_UNIT_NUM_REG           
362             //  in_GPR_WRITE_WRITE_UNIT_DATA             
363           }
364
365           {
366             dest = _name+"_register_unit";
367             
368#ifdef POSITION
369             _component->interface_map (src ,"gpr_write_register_file_"+toString(i),
370                                        dest,"gpr_write_"+toString(i));
371#endif
372             // out_GPR_WRITE_REGISTER_FILE_VAL           
373             //  in_GPR_WRITE_REGISTER_FILE_ACK           
374             // out_GPR_WRITE_REGISTER_FILE_OOO_ENGINE_ID 
375             // out_GPR_WRITE_REGISTER_FILE_NUM_REG       
376             // out_GPR_WRITE_REGISTER_FILE_DATA           
377           }
378
379           {
380             dest = _name+"_read_unit_0";
381
382#ifdef POSITION
383             _component->interface_map (src ,"gpr_write_read_unit_"+toString(i),
384                                        dest,"gpr_write");
385#endif
386
387             // out_GPR_WRITE_READ_UNIT_VAL               
388             // out_GPR_WRITE_READ_UNIT_OOO_ENGINE_ID     
389             // out_GPR_WRITE_READ_UNIT_NUM_REG           
390             // out_GPR_WRITE_READ_UNIT_DATA               
391           }
392         }
393
394       for (uint32_t i=0; i<_param->_nb_spr_write; i++)
395         {
396           {
397             dest = _name+"_write_unit_"+toString(i);
398             
399#ifdef POSITION
400             _component->interface_map (src ,"spr_write_write_unit_"+toString(i),
401                                        dest,"spr_write");
402#endif
403
404             //  in_SPR_WRITE_WRITE_UNIT_VAL               
405             // out_SPR_WRITE_WRITE_UNIT_ACK               
406             //  in_SPR_WRITE_WRITE_UNIT_OOO_ENGINE_ID     
407             //  in_SPR_WRITE_WRITE_UNIT_NUM_REG           
408             //  in_SPR_WRITE_WRITE_UNIT_DATA             
409           }
410
411           {
412             dest = _name+"_register_unit";
413             
414#ifdef POSITION
415             _component->interface_map (src ,"spr_write_register_file_"+toString(i),
416                                        dest,"spr_write_"+toString(i));
417#endif
418             // out_SPR_WRITE_REGISTER_FILE_VAL           
419             //  in_SPR_WRITE_REGISTER_FILE_ACK           
420             // out_SPR_WRITE_REGISTER_FILE_OOO_ENGINE_ID 
421             // out_SPR_WRITE_REGISTER_FILE_NUM_REG       
422             // out_SPR_WRITE_REGISTER_FILE_DATA           
423           }
424
425           {
426             dest = _name+"_read_unit_0";
427
428#ifdef POSITION
429             _component->interface_map (src ,"spr_write_read_unit_"+toString(i),
430                                        dest,"spr_write");
431#endif
432
433             // out_SPR_WRITE_READ_UNIT_VAL               
434             // out_SPR_WRITE_READ_UNIT_OOO_ENGINE_ID     
435             // out_SPR_WRITE_READ_UNIT_NUM_REG           
436             // out_SPR_WRITE_READ_UNIT_DATA               
437           }
438         }
439
440       
441     }
442
443     // ===================================================================
444     // =====[ READ_UNIT ]=================================================
445     // ===================================================================
446     {
447       uint32_t it_read_unit_out = 0;
448       
449       for (uint32_t i=0; i<_param->_nb_read_unit; i++)
450         {
451           src = _name+"_read_unit_"+toString(i);
452           log_printf(INFO,Core,FUNCTION,_("Instance : %s"),src.c_str());
453           
454           {
455             dest = _name;
456#ifdef POSITION
457             _component->interface_map (src ,"",
458                                        dest,"");
459#endif
460             PORT_MAP(_component ,src , "in_CLOCK" ,dest, "in_CLOCK");
461             PORT_MAP(_component ,src , "in_NRESET",dest, "in_NRESET");
462           }
463           
464           // ~~~~~[ Interface "read_unit_in" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
465           {
466             dest = _name;
467#ifdef POSITION
468             _component->interface_map (src ,"read_unit_in",
469                                        dest,"execute_loop_in_"+toString(i));
470#endif
471
472             PORT_MAP(_component ,src , "in_READ_UNIT_IN_VAL"                  ,dest , "in_EXECUTE_LOOP_IN_"+toString(i)+"_VAL"                  );
473             PORT_MAP(_component ,src ,"out_READ_UNIT_IN_ACK"                  ,dest ,"out_EXECUTE_LOOP_IN_"+toString(i)+"_ACK"                  );
474             if (_param->_have_port_context_id)
475             PORT_MAP(_component ,src , "in_READ_UNIT_IN_CONTEXT_ID"           ,dest , "in_EXECUTE_LOOP_IN_"+toString(i)+"_CONTEXT_ID"           );
476             if (_param->_have_port_front_end_id)
477             PORT_MAP(_component ,src , "in_READ_UNIT_IN_FRONT_END_ID"         ,dest , "in_EXECUTE_LOOP_IN_"+toString(i)+"_FRONT_END_ID"         );
478             if (_param->_have_port_ooo_engine_id)
479             PORT_MAP(_component ,src , "in_READ_UNIT_IN_OOO_ENGINE_ID"        ,dest , "in_EXECUTE_LOOP_IN_"+toString(i)+"_OOO_ENGINE_ID"        );
480             if (_param->_have_port_rob_ptr  )
481             PORT_MAP(_component ,src , "in_READ_UNIT_IN_PACKET_ID"            ,dest , "in_EXECUTE_LOOP_IN_"+toString(i)+"_PACKET_ID"            );
482             PORT_MAP(_component ,src , "in_READ_UNIT_IN_OPERATION"            ,dest , "in_EXECUTE_LOOP_IN_"+toString(i)+"_OPERATION"            );
483             PORT_MAP(_component ,src , "in_READ_UNIT_IN_TYPE"                 ,dest , "in_EXECUTE_LOOP_IN_"+toString(i)+"_TYPE"                 );
484             PORT_MAP(_component ,src , "in_READ_UNIT_IN_STORE_QUEUE_PTR_WRITE",dest , "in_EXECUTE_LOOP_IN_"+toString(i)+"_STORE_QUEUE_PTR_WRITE");
485             if (_param->_have_port_load_queue_ptr)
486             PORT_MAP(_component ,src , "in_READ_UNIT_IN_LOAD_QUEUE_PTR_WRITE" ,dest , "in_EXECUTE_LOOP_IN_"+toString(i)+"_LOAD_QUEUE_PTR_WRITE" );
487             PORT_MAP(_component ,src , "in_READ_UNIT_IN_HAS_IMMEDIAT"         ,dest , "in_EXECUTE_LOOP_IN_"+toString(i)+"_HAS_IMMEDIAT"         );
488             PORT_MAP(_component ,src , "in_READ_UNIT_IN_IMMEDIAT"             ,dest , "in_EXECUTE_LOOP_IN_"+toString(i)+"_IMMEDIAT"             );
489             PORT_MAP(_component ,src , "in_READ_UNIT_IN_READ_RA"              ,dest , "in_EXECUTE_LOOP_IN_"+toString(i)+"_READ_RA"              );
490             PORT_MAP(_component ,src , "in_READ_UNIT_IN_NUM_REG_RA"           ,dest , "in_EXECUTE_LOOP_IN_"+toString(i)+"_NUM_REG_RA"           );
491             PORT_MAP(_component ,src , "in_READ_UNIT_IN_READ_RB"              ,dest , "in_EXECUTE_LOOP_IN_"+toString(i)+"_READ_RB"              );
492             PORT_MAP(_component ,src , "in_READ_UNIT_IN_NUM_REG_RB"           ,dest , "in_EXECUTE_LOOP_IN_"+toString(i)+"_NUM_REG_RB"           );
493             PORT_MAP(_component ,src , "in_READ_UNIT_IN_READ_RC"              ,dest , "in_EXECUTE_LOOP_IN_"+toString(i)+"_READ_RC"              );
494             PORT_MAP(_component ,src , "in_READ_UNIT_IN_NUM_REG_RC"           ,dest , "in_EXECUTE_LOOP_IN_"+toString(i)+"_NUM_REG_RC"           );
495             PORT_MAP(_component ,src , "in_READ_UNIT_IN_WRITE_RD"             ,dest , "in_EXECUTE_LOOP_IN_"+toString(i)+"_WRITE_RD"             );
496             PORT_MAP(_component ,src , "in_READ_UNIT_IN_NUM_REG_RD"           ,dest , "in_EXECUTE_LOOP_IN_"+toString(i)+"_NUM_REG_RD"           );
497             PORT_MAP(_component ,src , "in_READ_UNIT_IN_WRITE_RE"             ,dest , "in_EXECUTE_LOOP_IN_"+toString(i)+"_WRITE_RE"             );
498             PORT_MAP(_component ,src , "in_READ_UNIT_IN_NUM_REG_RE"           ,dest , "in_EXECUTE_LOOP_IN_"+toString(i)+"_NUM_REG_RE"           );
499           }
500
501           // ~~~~~[ Interface "read_unit_out" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
502           for (uint32_t j=0; j < _param->_nb_inst_retire[i]; j++)
503             {
504               dest = _name+"_read_unit_to_execution_unit";
505               
506#ifdef POSITION
507               _component->interface_map (src ,"read_unit_"+toString(j),
508                                          dest,"read_unit_"+toString(it_read_unit_out));
509#endif
510             
511               COMPONENT_MAP(_component ,src ,"out_READ_UNIT_OUT_"+toString(j               )+"_VAL"                  ,
512                                         dest, "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_"+toString(j)+"_VAL"                  );
513               COMPONENT_MAP(_component ,src , "in_READ_UNIT_OUT_"+toString(j               )+"_ACK"                  ,
514                                         dest,"out_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_"+toString(j)+"_ACK"                  );
515               if (_param->_have_port_context_id)
516               COMPONENT_MAP(_component ,src ,"out_READ_UNIT_OUT_"+toString(j               )+"_CONTEXT_ID"           ,
517                                         dest, "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_"+toString(j)+"_CONTEXT_ID"           );
518               if (_param->_have_port_front_end_id)
519               COMPONENT_MAP(_component ,src ,"out_READ_UNIT_OUT_"+toString(j               )+"_FRONT_END_ID"         ,
520                                         dest, "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_"+toString(j)+"_FRONT_END_ID"         );
521               if (_param->_have_port_ooo_engine_id)
522               COMPONENT_MAP(_component ,src ,"out_READ_UNIT_OUT_"+toString(j               )+"_OOO_ENGINE_ID"        ,
523                                         dest, "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_"+toString(j)+"_OOO_ENGINE_ID"        );
524               if (_param->_have_port_rob_ptr  )
525               COMPONENT_MAP(_component ,src ,"out_READ_UNIT_OUT_"+toString(j               )+"_PACKET_ID"            ,
526                                         dest, "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_"+toString(j)+"_PACKET_ID"            );
527               COMPONENT_MAP(_component ,src ,"out_READ_UNIT_OUT_"+toString(j               )+"_OPERATION"            ,
528                                         dest, "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_"+toString(j)+"_OPERATION"            );
529               COMPONENT_MAP(_component ,src ,"out_READ_UNIT_OUT_"+toString(j               )+"_TYPE"                 ,
530                                         dest, "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_"+toString(j)+"_TYPE"                 );
531               COMPONENT_MAP(_component ,src ,"out_READ_UNIT_OUT_"+toString(j               )+"_STORE_QUEUE_PTR_WRITE",
532                                         dest, "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_"+toString(j)+"_STORE_QUEUE_PTR_WRITE");
533               if (_param->_have_port_load_queue_ptr)
534               COMPONENT_MAP(_component ,src ,"out_READ_UNIT_OUT_"+toString(j               )+"_LOAD_QUEUE_PTR_WRITE" ,
535                                         dest, "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_"+toString(j)+"_LOAD_QUEUE_PTR_WRITE" );
536               COMPONENT_MAP(_component ,src ,"out_READ_UNIT_OUT_"+toString(j               )+"_HAS_IMMEDIAT"         ,
537                                         dest, "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_"+toString(j)+"_HAS_IMMEDIAT"         );
538               COMPONENT_MAP(_component ,src ,"out_READ_UNIT_OUT_"+toString(j               )+"_IMMEDIAT"             ,
539                                         dest, "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_"+toString(j)+"_IMMEDIAT"             );
540               COMPONENT_MAP(_component ,src ,"out_READ_UNIT_OUT_"+toString(j               )+"_DATA_RA"              ,
541                                         dest, "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_"+toString(j)+"_DATA_RA"              );
542               COMPONENT_MAP(_component ,src ,"out_READ_UNIT_OUT_"+toString(j               )+"_DATA_RB"              ,
543                                         dest, "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_"+toString(j)+"_DATA_RB"              );
544               COMPONENT_MAP(_component ,src ,"out_READ_UNIT_OUT_"+toString(j               )+"_DATA_RC"              ,
545                                         dest, "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_"+toString(j)+"_DATA_RC"              );
546               COMPONENT_MAP(_component ,src ,"out_READ_UNIT_OUT_"+toString(j               )+"_WRITE_RD"             ,
547                                         dest, "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_"+toString(j)+"_WRITE_RD"             );
548               COMPONENT_MAP(_component ,src ,"out_READ_UNIT_OUT_"+toString(j               )+"_NUM_REG_RD"           ,
549                                         dest, "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_"+toString(j)+"_NUM_REG_RD"           );
550               COMPONENT_MAP(_component ,src ,"out_READ_UNIT_OUT_"+toString(j               )+"_WRITE_RE"             ,
551                                         dest, "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_"+toString(j)+"_WRITE_RE"             );
552               COMPONENT_MAP(_component ,src ,"out_READ_UNIT_OUT_"+toString(j               )+"_NUM_REG_RE"           ,
553                                         dest, "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_"+toString(j)+"_NUM_REG_RE"           );
554             
555           }
556           it_read_unit_out ++;
557           
558           // ~~~~~[ Interface "gpr_read" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
559           {
560             dest = _name+"_register_unit";
561#ifdef POSITION
562             _component->interface_map (src ,"gpr_read_0",
563                                        dest,"gpr_read_"+toString(2*));
564             _component->interface_map (src ,"gpr_read_1",
565                                        dest,"gpr_read_"+toString(2*i+1));
566#endif
567             COMPONENT_MAP(_component ,src ,"out_GPR_READ_0_VAL"          , dest, "in_GPR_READ_"+toString(2*)+"_VAL"          );
568             COMPONENT_MAP(_component ,src , "in_GPR_READ_0_ACK"          , dest,"out_GPR_READ_"+toString(2*)+"_ACK"          );
569             if (_param->_have_port_ooo_engine_id)
570             COMPONENT_MAP(_component ,src ,"out_GPR_READ_0_OOO_ENGINE_ID", dest, "in_GPR_READ_"+toString(2*)+"_OOO_ENGINE_ID");
571             COMPONENT_MAP(_component ,src ,"out_GPR_READ_0_NUM_REG"      , dest, "in_GPR_READ_"+toString(2*)+"_NUM_REG"      );
572             COMPONENT_MAP(_component ,src , "in_GPR_READ_0_DATA"         , dest,"out_GPR_READ_"+toString(2*)+"_DATA"         );
573             COMPONENT_MAP(_component ,src , "in_GPR_READ_0_DATA_VAL"     , dest,"out_GPR_READ_"+toString(2*)+"_DATA_VAL"     );
574             COMPONENT_MAP(_component ,src ,"out_GPR_READ_1_VAL"          , dest, "in_GPR_READ_"+toString(2*i+1)+"_VAL"          );
575             COMPONENT_MAP(_component ,src , "in_GPR_READ_1_ACK"          , dest,"out_GPR_READ_"+toString(2*i+1)+"_ACK"          );
576             if (_param->_have_port_ooo_engine_id)
577             COMPONENT_MAP(_component ,src ,"out_GPR_READ_1_OOO_ENGINE_ID", dest, "in_GPR_READ_"+toString(2*i+1)+"_OOO_ENGINE_ID");
578             COMPONENT_MAP(_component ,src ,"out_GPR_READ_1_NUM_REG"      , dest, "in_GPR_READ_"+toString(2*i+1)+"_NUM_REG"      );
579             COMPONENT_MAP(_component ,src , "in_GPR_READ_1_DATA"         , dest,"out_GPR_READ_"+toString(2*i+1)+"_DATA"         );
580             COMPONENT_MAP(_component ,src , "in_GPR_READ_1_DATA_VAL"     , dest,"out_GPR_READ_"+toString(2*i+1)+"_DATA_VAL"     );
581           }
582           
583           // ~~~~~[ Interface "spr_read" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
584           {
585             dest = _name+"_register_unit";
586#ifdef POSITION
587             _component->interface_map (src ,"spr_read_0",
588                                        dest,"spr_read_"+toString(i));
589#endif
590             COMPONENT_MAP(_component ,src ,"out_SPR_READ_0_VAL"          , dest, "in_SPR_READ_"+toString(i)+"_VAL"          );
591             COMPONENT_MAP(_component ,src , "in_SPR_READ_0_ACK"          , dest,"out_SPR_READ_"+toString(i)+"_ACK"          );
592             if (_param->_have_port_ooo_engine_id)
593             COMPONENT_MAP(_component ,src ,"out_SPR_READ_0_OOO_ENGINE_ID", dest, "in_SPR_READ_"+toString(i)+"_OOO_ENGINE_ID");
594             COMPONENT_MAP(_component ,src ,"out_SPR_READ_0_NUM_REG"      , dest, "in_SPR_READ_"+toString(i)+"_NUM_REG"      );
595             COMPONENT_MAP(_component ,src , "in_SPR_READ_0_DATA"         , dest,"out_SPR_READ_"+toString(i)+"_DATA"         );
596             COMPONENT_MAP(_component ,src , "in_SPR_READ_0_DATA_VAL"     , dest,"out_SPR_READ_"+toString(i)+"_DATA_VAL"     );
597           }
598           
599           // ~~~~~[ Interface "gpr_write" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
600           uint32_t it_gpr_write = 0;
601           for (std::set<uint32_t>::iterator it=_param->_set_read_unit_source_register_write[i].begin();
602                it!=_param->_set_read_unit_source_register_write[i].end();
603                it++)
604             {
605               uint32_t num_port = (*it);
606
607               dest = _name+"_glue";
608#ifdef POSITION
609               _component->interface_map (src ,"gpr_write_"+toString(it_gpr_write),
610                                          dest,"gpr_write_read_unit_"+toString(num_port));
611#endif
612               
613               COMPONENT_MAP(_component ,src , "in_GPR_WRITE_"+toString(it_gpr_write)+"_VAL"          ,
614                                         dest,"out_GPR_WRITE_READ_UNIT_"+toString(num_port)+"_VAL"          );
615               if (_param->_have_port_ooo_engine_id)
616               COMPONENT_MAP(_component ,src , "in_GPR_WRITE_"+toString(it_gpr_write)+"_OOO_ENGINE_ID",
617                                         dest,"out_GPR_WRITE_READ_UNIT_"+toString(num_port)+"_OOO_ENGINE_ID");
618               COMPONENT_MAP(_component ,src , "in_GPR_WRITE_"+toString(it_gpr_write)+"_NUM_REG"      ,
619                                         dest,"out_GPR_WRITE_READ_UNIT_"+toString(num_port)+"_NUM_REG"      );
620               COMPONENT_MAP(_component ,src , "in_GPR_WRITE_"+toString(it_gpr_write)+"_DATA"         ,
621                                         dest,"out_GPR_WRITE_READ_UNIT_"+toString(num_port)+"_DATA"         );
622               
623               it_gpr_write ++;
624             }
625           
626           // ~~~~~[ Interface "spr_write" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
627           uint32_t it_spr_write = 0;
628           for (std::set<uint32_t>::iterator it=_param->_set_read_unit_source_register_write[i].begin();
629                it!=_param->_set_read_unit_source_register_write[i].end();
630                it++)
631             {
632               uint32_t num_port = (*it);
633
634               dest = _name+"_glue";
635#ifdef POSITION
636               _component->interface_map (src ,"spr_write_"+toString(it_spr_write),
637                                          dest,"spr_write_read_unit_"+toString(num_port));
638#endif
639               
640               COMPONENT_MAP(_component ,src , "in_SPR_WRITE_"+toString(it_spr_write)+"_VAL"          ,
641                                         dest,"out_SPR_WRITE_READ_UNIT_"+toString(num_port)+"_VAL"          );
642
643               if (_param->_have_port_ooo_engine_id)
644               COMPONENT_MAP(_component ,src , "in_SPR_WRITE_"+toString(it_spr_write)+"_OOO_ENGINE_ID",
645                                         dest,"out_SPR_WRITE_READ_UNIT_"+toString(num_port)+"_OOO_ENGINE_ID");
646               COMPONENT_MAP(_component ,src , "in_SPR_WRITE_"+toString(it_spr_write)+"_NUM_REG"      ,
647                                         dest,"out_SPR_WRITE_READ_UNIT_"+toString(num_port)+"_NUM_REG"      );
648               COMPONENT_MAP(_component ,src , "in_SPR_WRITE_"+toString(it_spr_write)+"_DATA"         ,
649                                         dest,"out_SPR_WRITE_READ_UNIT_"+toString(num_port)+"_DATA"         );
650               
651               it_spr_write ++;
652             }
653
654           // ~~~~~[ Interface "bypass_write" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
655           uint32_t it_bypass_write = 0;
656           for (std::set<uint32_t>::iterator it=_param->_set_read_unit_source_bypass_write[i].begin();
657                it!=_param->_set_read_unit_source_bypass_write[i].end();
658                it++)
659             {
660               dest = _name+"_write_unit_"+toString(*it);
661
662               for (uint32_t j=0; j<_param->_nb_bypass_write[*it]; j++)
663                 {
664#ifdef POSITION
665                   _component->interface_map (src ,"bypass_write_"+toString(it_bypass_write),
666                                              dest,"bypass_write_"+toString(j));
667#endif
668                   
669                   if (_param->_have_port_ooo_engine_id)
670                   COMPONENT_MAP(_component ,src , "in_BYPASS_WRITE_"+toString(it_bypass_write)+"_OOO_ENGINE_ID",
671                                             dest,"out_BYPASS_WRITE_"+toString(j              )+"_OOO_ENGINE_ID");
672                   COMPONENT_MAP(_component ,src , "in_BYPASS_WRITE_"+toString(it_bypass_write)+"_GPR_VAL"      ,
673                                             dest,"out_BYPASS_WRITE_"+toString(j              )+"_GPR_VAL"      );
674                   COMPONENT_MAP(_component ,src , "in_BYPASS_WRITE_"+toString(it_bypass_write)+"_GPR_NUM_REG"  ,
675                                             dest,"out_BYPASS_WRITE_"+toString(j              )+"_GPR_NUM_REG"  );
676                   COMPONENT_MAP(_component ,src , "in_BYPASS_WRITE_"+toString(it_bypass_write)+"_GPR_DATA"     ,
677                                             dest,"out_BYPASS_WRITE_"+toString(j              )+"_GPR_DATA"     );
678                   COMPONENT_MAP(_component ,src , "in_BYPASS_WRITE_"+toString(it_bypass_write)+"_SPR_VAL"      ,
679                                             dest,"out_BYPASS_WRITE_"+toString(j              )+"_SPR_VAL"      );
680                   COMPONENT_MAP(_component ,src , "in_BYPASS_WRITE_"+toString(it_bypass_write)+"_SPR_NUM_REG"  ,
681                                             dest,"out_BYPASS_WRITE_"+toString(j              )+"_SPR_NUM_REG"  );
682                   COMPONENT_MAP(_component ,src , "in_BYPASS_WRITE_"+toString(it_bypass_write)+"_SPR_DATA"     ,
683                                             dest,"out_BYPASS_WRITE_"+toString(j              )+"_SPR_DATA"     );
684
685#ifdef POSITION
686                   _component->interface_map (dest,"bypass_write_"+toString(j),
687                                              src ,"bypass_write_"+toString(it_bypass_write));
688#endif
689                   
690//                 if (_param->_have_port_ooo_engine_id)
691//                 PORT_MAP(_component ,dest,"out_BYPASS_WRITE_"+toString(j              )+"_OOO_ENGINE_ID",
692//                                      src , "in_BYPASS_WRITE_"+toString(it_bypass_write)+"_OOO_ENGINE_ID");
693//                 PORT_MAP(_component ,dest,"out_BYPASS_WRITE_"+toString(j              )+"_GPR_VAL"      ,
694//                                      src , "in_BYPASS_WRITE_"+toString(it_bypass_write)+"_GPR_VAL"      );
695//                 PORT_MAP(_component ,dest,"out_BYPASS_WRITE_"+toString(j              )+"_GPR_NUM_REG"  ,
696//                                      src , "in_BYPASS_WRITE_"+toString(it_bypass_write)+"_GPR_NUM_REG"  );
697//                 PORT_MAP(_component ,dest,"out_BYPASS_WRITE_"+toString(j              )+"_GPR_DATA"     ,
698//                                      src , "in_BYPASS_WRITE_"+toString(it_bypass_write)+"_GPR_DATA"     );
699//                 PORT_MAP(_component ,dest,"out_BYPASS_WRITE_"+toString(j              )+"_SPR_VAL"      ,
700//                                      src , "in_BYPASS_WRITE_"+toString(it_bypass_write)+"_SPR_VAL"      );
701//                 PORT_MAP(_component ,dest,"out_BYPASS_WRITE_"+toString(j              )+"_SPR_NUM_REG"  ,
702//                                      src , "in_BYPASS_WRITE_"+toString(it_bypass_write)+"_SPR_NUM_REG"  );
703//                 PORT_MAP(_component ,dest,"out_BYPASS_WRITE_"+toString(j              )+"_SPR_DATA"     ,
704//                                      src , "in_BYPASS_WRITE_"+toString(it_bypass_write)+"_SPR_DATA"     );
705
706                   it_bypass_write ++;
707                 }
708             }
709
710           // ~~~~~[ Interface "bypass_memory" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
711           uint32_t it_bypass_memory = 0;
712           for (std::set<uint32_t>::iterator it=_param->_set_read_unit_source_bypass_memory[i].begin();
713                it!=_param->_set_read_unit_source_bypass_memory[i].end();
714                it++)
715             {
716               dest = _name+"_load_store_unit_"+toString(_param->_translate_num_execute_unit[*it]);
717
718               for (uint32_t j=0; j<_param->_nb_bypass_memory[_param->_translate_num_execute_unit[*it]]; j++)
719                 {
720#ifdef POSITION
721                   _component->interface_map (src ,"bypass_memory_"+toString(it_bypass_memory),
722                                              dest,"bypass_memory_"+toString(j));
723#endif
724                   
725                   if (_param->_have_port_ooo_engine_id)
726                   COMPONENT_MAP(_component ,src , "in_BYPASS_MEMORY_"+toString(it_bypass_memory)+"_OOO_ENGINE_ID",
727                                             dest,"out_BYPASS_MEMORY_"+toString(j               )+"_OOO_ENGINE_ID");
728                   COMPONENT_MAP(_component ,src , "in_BYPASS_MEMORY_"+toString(it_bypass_memory)+"_VAL"          ,
729                                             dest,"out_BYPASS_MEMORY_"+toString(j               )+"_VAL"          );
730                   COMPONENT_MAP(_component ,src , "in_BYPASS_MEMORY_"+toString(it_bypass_memory)+"_NUM_REG"      ,
731                                             dest,"out_BYPASS_MEMORY_"+toString(j               )+"_NUM_REG"      );
732                   COMPONENT_MAP(_component ,src , "in_BYPASS_MEMORY_"+toString(it_bypass_memory)+"_DATA"         ,
733                                             dest,"out_BYPASS_MEMORY_"+toString(j               )+"_DATA"         );
734
735                   // port map to the "load_store_unit" component
736#ifdef POSITION
737                   _component->interface_map (dest,"bypass_memory_"+toString(j),
738                                              src ,"bypass_memory_"+toString(it_bypass_memory));
739#endif
740                   
741//                 if (_param->_have_port_ooo_engine_id)
742//                 PORT_MAP(_component ,dest,"out_BYPASS_MEMORY_"+toString(j               )+"_OOO_ENGINE_ID",
743//                                      src , "in_BYPASS_MEMORY_"+toString(it_bypass_memory)+"_OOO_ENGINE_ID");
744//                 PORT_MAP(_component ,dest,"out_BYPASS_MEMORY_"+toString(j               )+"_VAL"          ,
745//                                      src , "in_BYPASS_MEMORY_"+toString(it_bypass_memory)+"_VAL"          );
746//                 PORT_MAP(_component ,dest,"out_BYPASS_MEMORY_"+toString(j               )+"_NUM_REG"      ,
747//                                      src , "in_BYPASS_MEMORY_"+toString(it_bypass_memory)+"_NUM_REG"      );
748//                 PORT_MAP(_component ,dest,"out_BYPASS_MEMORY_"+toString(j               )+"_DATA"         ,
749//                                      src , "in_BYPASS_MEMORY_"+toString(it_bypass_memory)+"_DATA"         );
750
751                   it_bypass_memory ++;
752                 }
753             }
754         }
755     }
756
757     // ===================================================================
758     // =====[ EXECUTE_UNIT ]==============================================   
759     // ===================================================================
760     for (uint32_t i=0; i<_param->_nb_execute_unit; i++)
761       {
762         uint32_t x=_param->_translate_num_execute_unit[i];
763         
764         if (_param->_is_load_store_unit[i] == false)
765           {
766             // ===================================================================
767             // =====[ FUNCTIONNAL_UNIT ]==========================================   
768             // ===================================================================
769
770             src = _name+"_functionnal_unit_"+toString(x);
771             log_printf(INFO,Core,FUNCTION,_("Instance : %s"),src.c_str());
772             
773             {
774               dest = _name;
775#ifdef POSITION
776               _component->interface_map (src ,"",
777                                          dest,"");
778#endif
779               PORT_MAP(_component ,src , "in_CLOCK" ,dest, "in_CLOCK");
780               PORT_MAP(_component ,src , "in_NRESET",dest, "in_NRESET");
781             }
782   
783             // ~~~~~[ Interface "execute_in" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
784             {
785               dest = _name+"_read_unit_to_execution_unit";
786
787#ifdef POSITION
788               _component->interface_map (src ,"execute_in",
789                                          dest,"execute_unit_in_"+toString(i)+"_0");
790#endif
791
792               COMPONENT_MAP(_component ,src , "in_EXECUTE_IN_VAL"                  ,
793                                         dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_0_VAL"                  );
794               COMPONENT_MAP(_component ,src ,"out_EXECUTE_IN_ACK"                  ,
795                                         dest, "in_EXECUTE_UNIT_IN_"+toString(i)+"_0_ACK"                  );
796               if (_param->_have_port_context_id)
797               COMPONENT_MAP(_component ,src , "in_EXECUTE_IN_CONTEXT_ID"           ,
798                                         dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_0_CONTEXT_ID"           );
799               if (_param->_have_port_front_end_id)
800               COMPONENT_MAP(_component ,src , "in_EXECUTE_IN_FRONT_END_ID"         ,
801                                         dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_0_FRONT_END_ID"         );
802               if (_param->_have_port_ooo_engine_id)
803               COMPONENT_MAP(_component ,src , "in_EXECUTE_IN_OOO_ENGINE_ID"        ,
804                                         dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_0_OOO_ENGINE_ID"        );
805               if (_param->_have_port_rob_ptr  )
806               COMPONENT_MAP(_component ,src , "in_EXECUTE_IN_PACKET_ID"            ,
807                                         dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_0_PACKET_ID"            );
808               COMPONENT_MAP(_component ,src , "in_EXECUTE_IN_OPERATION"            ,
809                                         dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_0_OPERATION"            );
810               COMPONENT_MAP(_component ,src , "in_EXECUTE_IN_TYPE"                 ,
811                                         dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_0_TYPE"                 );
812               COMPONENT_MAP(_component ,src , "in_EXECUTE_IN_STORE_QUEUE_PTR_WRITE",
813                                         dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_0_STORE_QUEUE_PTR_WRITE");
814               if (_param->_have_port_load_queue_ptr)
815               COMPONENT_MAP(_component ,src , "in_EXECUTE_IN_LOAD_QUEUE_PTR_WRITE" ,
816                                         dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_0_LOAD_QUEUE_PTR_WRITE" );
817               COMPONENT_MAP(_component ,src , "in_EXECUTE_IN_HAS_IMMEDIAT"         ,
818                                         dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_0_HAS_IMMEDIAT"         );
819               COMPONENT_MAP(_component ,src , "in_EXECUTE_IN_IMMEDIAT"             ,
820                                         dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_0_IMMEDIAT"             );
821               COMPONENT_MAP(_component ,src , "in_EXECUTE_IN_DATA_RA"              ,
822                                         dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_0_DATA_RA"              );
823               COMPONENT_MAP(_component ,src , "in_EXECUTE_IN_DATA_RB"              ,
824                                         dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_0_DATA_RB"              );
825               COMPONENT_MAP(_component ,src , "in_EXECUTE_IN_DATA_RC"              ,
826                                         dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_0_DATA_RC"              );
827               COMPONENT_MAP(_component ,src , "in_EXECUTE_IN_WRITE_RD"             ,
828                                         dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_0_WRITE_RD"             );
829               COMPONENT_MAP(_component ,src , "in_EXECUTE_IN_NUM_REG_RD"           ,
830                                         dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_0_NUM_REG_RD"           );
831               COMPONENT_MAP(_component ,src , "in_EXECUTE_IN_WRITE_RE"             ,
832                                         dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_0_WRITE_RE"             );
833               COMPONENT_MAP(_component ,src , "in_EXECUTE_IN_NUM_REG_RE"           ,
834                                         dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_0_NUM_REG_RE"           );
835             }
836             
837             // ~~~~~[ Interface "execute_out" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
838             {
839               dest = _name+"_execution_unit_to_write_unit";
840               
841#ifdef POSITION
842               _component->interface_map (src ,"execute_out",
843                                          dest,"execute_unit_out_"+toString(i)+"_0");
844#endif
845
846               COMPONENT_MAP(_component ,src ,"out_EXECUTE_OUT_VAL"          ,
847                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_0_VAL"          );
848               COMPONENT_MAP(_component ,src , "in_EXECUTE_OUT_ACK"          ,
849                                         dest,"out_EXECUTE_UNIT_OUT_"+toString(i)+"_0_ACK"          );
850               if (_param->_have_port_context_id)
851               COMPONENT_MAP(_component ,src ,"out_EXECUTE_OUT_CONTEXT_ID"   ,
852                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_0_CONTEXT_ID"   );
853               if (_param->_have_port_front_end_id)
854               COMPONENT_MAP(_component ,src ,"out_EXECUTE_OUT_FRONT_END_ID" ,
855                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_0_FRONT_END_ID" );
856               if (_param->_have_port_ooo_engine_id)
857               COMPONENT_MAP(_component ,src ,"out_EXECUTE_OUT_OOO_ENGINE_ID",
858                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_0_OOO_ENGINE_ID");
859               if (_param->_have_port_rob_ptr  )
860               COMPONENT_MAP(_component ,src ,"out_EXECUTE_OUT_PACKET_ID"    ,
861                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_0_PACKET_ID"    );
862//             COMPONENT_MAP(_component ,src ,"out_EXECUTE_OUT_OPERATION"    ,
863//                                       dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_0_OPERATION"    );
864//             COMPONENT_MAP(_component ,src ,"out_EXECUTE_OUT_TYPE"         ,
865//                                       dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_0_TYPE"         );
866               COMPONENT_MAP(_component ,src ,"out_EXECUTE_OUT_WRITE_RD"     ,
867                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_0_WRITE_RD"     );
868               COMPONENT_MAP(_component ,src ,"out_EXECUTE_OUT_NUM_REG_RD"   ,
869                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_0_NUM_REG_RD"   );
870               COMPONENT_MAP(_component ,src ,"out_EXECUTE_OUT_DATA_RD"      ,
871                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_0_DATA_RD"      );
872               COMPONENT_MAP(_component ,src ,"out_EXECUTE_OUT_WRITE_RE"     ,
873                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_0_WRITE_RE"     );
874               COMPONENT_MAP(_component ,src ,"out_EXECUTE_OUT_NUM_REG_RE"   ,
875                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_0_NUM_REG_RE"   );
876               COMPONENT_MAP(_component ,src ,"out_EXECUTE_OUT_DATA_RE"      ,
877                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_0_DATA_RE"      );
878               COMPONENT_MAP(_component ,src ,"out_EXECUTE_OUT_EXCEPTION"    ,
879                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_0_EXCEPTION"    );
880               COMPONENT_MAP(_component ,src ,"out_EXECUTE_OUT_NO_SEQUENCE"  ,
881                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_0_NO_SEQUENCE"  );
882               COMPONENT_MAP(_component ,src ,"out_EXECUTE_OUT_ADDRESS"      ,
883                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_0_ADDRESS"      );
884             }
885           }
886         else
887           {
888             // ===================================================================
889             // =====[ LOAD_STORE_UNIT ]===========================================   
890             // ===================================================================
891 
892             src = _name+"_load_store_unit_"+toString(x);
893             log_printf(INFO,Core,FUNCTION,_("Instance : %s"),src.c_str());
894
895             // ~~~~~[ Interface "" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
896             {
897               dest = _name;
898#ifdef POSITION
899               _component->interface_map (src ,"",
900                                          dest,"");
901#endif
902               PORT_MAP(_component ,src , "in_CLOCK" ,dest, "in_CLOCK");
903               PORT_MAP(_component ,src , "in_NRESET",dest, "in_NRESET");
904             }
905         
906             // ~~~~~[ Interface "memory_in" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
907             for (uint32_t j=0; j<_param->_nb_inst_memory [x]; j++)
908               {
909                 dest = _name+"_read_unit_to_execution_unit";
910                 
911#ifdef POSITION
912                 _component->interface_map (src ,"memory_in_"+toString(j),
913                                            dest,"execute_unit_in_"+toString(i)+"_"+toString(j));
914#endif
915
916                 COMPONENT_MAP(_component ,src , "in_MEMORY_IN_"+toString(j)+"_VAL"                  ,
917                                           dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_"+toString(j)+"_VAL"                  );
918                 COMPONENT_MAP(_component ,src ,"out_MEMORY_IN_"+toString(j)+"_ACK"                  ,
919                                           dest, "in_EXECUTE_UNIT_IN_"+toString(i)+"_"+toString(j)+"_ACK"                  );
920                 if (_param->_have_port_context_id)
921                 COMPONENT_MAP(_component ,src , "in_MEMORY_IN_"+toString(j)+"_CONTEXT_ID"           ,
922                                           dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_"+toString(j)+"_CONTEXT_ID"           );
923                 if (_param->_have_port_front_end_id)
924                 COMPONENT_MAP(_component ,src , "in_MEMORY_IN_"+toString(j)+"_FRONT_END_ID"         ,
925                                           dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_"+toString(j)+"_FRONT_END_ID"         );
926                 if (_param->_have_port_ooo_engine_id)
927                 COMPONENT_MAP(_component ,src , "in_MEMORY_IN_"+toString(j)+"_OOO_ENGINE_ID"        ,
928                                           dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_"+toString(j)+"_OOO_ENGINE_ID"        );
929                 if (_param->_have_port_rob_ptr  )
930                 COMPONENT_MAP(_component ,src , "in_MEMORY_IN_"+toString(j)+"_PACKET_ID"            ,
931                                           dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_"+toString(j)+"_PACKET_ID"            );
932                 COMPONENT_MAP(_component ,src , "in_MEMORY_IN_"+toString(j)+"_OPERATION"            ,
933                                           dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_"+toString(j)+"_OPERATION"            );
934                 COMPONENT_MAP(_component ,src , "in_MEMORY_IN_"+toString(j)+"_TYPE"                 ,
935                                           dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_"+toString(j)+"_TYPE"                 );
936                 COMPONENT_MAP(_component ,src , "in_MEMORY_IN_"+toString(j)+"_STORE_QUEUE_PTR_WRITE",
937                                           dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_"+toString(j)+"_STORE_QUEUE_PTR_WRITE");
938                 if (_param->_have_port_load_queue_ptr)
939                 COMPONENT_MAP(_component ,src , "in_MEMORY_IN_"+toString(j)+"_LOAD_QUEUE_PTR_WRITE" ,
940                                           dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_"+toString(j)+"_LOAD_QUEUE_PTR_WRITE" );
941                 COMPONENT_MAP(_component ,src , "in_MEMORY_IN_"+toString(j)+"_HAS_IMMEDIAT"         ,
942                                           dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_"+toString(j)+"_HAS_IMMEDIAT"         );
943                 COMPONENT_MAP(_component ,src , "in_MEMORY_IN_"+toString(j)+"_IMMEDIAT"             ,
944                                           dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_"+toString(j)+"_IMMEDIAT"             );
945                 COMPONENT_MAP(_component ,src , "in_MEMORY_IN_"+toString(j)+"_DATA_RA"              ,
946                                           dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_"+toString(j)+"_DATA_RA"              );
947                 COMPONENT_MAP(_component ,src , "in_MEMORY_IN_"+toString(j)+"_DATA_RB"              ,
948                                           dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_"+toString(j)+"_DATA_RB"              );
949                 COMPONENT_MAP(_component ,src , "in_MEMORY_IN_"+toString(j)+"_DATA_RC"              ,
950                                           dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_"+toString(j)+"_DATA_RC"              );
951                 COMPONENT_MAP(_component ,src , "in_MEMORY_IN_"+toString(j)+"_WRITE_RD"             ,
952                                           dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_"+toString(j)+"_WRITE_RD"             );
953                 COMPONENT_MAP(_component ,src , "in_MEMORY_IN_"+toString(j)+"_NUM_REG_RD"           ,
954                                           dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_"+toString(j)+"_NUM_REG_RD"           );
955                 COMPONENT_MAP(_component ,src , "in_MEMORY_IN_"+toString(j)+"_WRITE_RE"             ,
956                                           dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_"+toString(j)+"_WRITE_RE"             );
957                 COMPONENT_MAP(_component ,src , "in_MEMORY_IN_"+toString(j)+"_NUM_REG_RE"           ,
958                                           dest,"out_EXECUTE_UNIT_IN_"+toString(i)+"_"+toString(j)+"_NUM_REG_RE"           );
959               }
960
961             // ~~~~~[ Interface "memory_out" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
962             for (uint32_t j=0; j<_param->_nb_inst_memory [x]; j++)
963               {
964               dest = _name+"_execution_unit_to_write_unit";
965               
966#ifdef POSITION
967               _component->interface_map (src ,"memory_out_"+toString(j)
968                                          dest,"execute_unit_out_"+toString(i)+"_"+toString(j));
969#endif
970
971               COMPONENT_MAP(_component ,src ,"out_MEMORY_OUT_"+toString(j)+"_VAL"          ,
972                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_"+toString(j)+"_VAL"          );
973               COMPONENT_MAP(_component ,src , "in_MEMORY_OUT_"+toString(j)+"_ACK"          ,
974                                         dest,"out_EXECUTE_UNIT_OUT_"+toString(i)+"_"+toString(j)+"_ACK"          );
975               if (_param->_have_port_context_id)
976               COMPONENT_MAP(_component ,src ,"out_MEMORY_OUT_"+toString(j)+"_CONTEXT_ID"   ,
977                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_"+toString(j)+"_CONTEXT_ID"   );
978               if (_param->_have_port_front_end_id)
979               COMPONENT_MAP(_component ,src ,"out_MEMORY_OUT_"+toString(j)+"_FRONT_END_ID" ,
980                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_"+toString(j)+"_FRONT_END_ID" );
981               if (_param->_have_port_ooo_engine_id)
982               COMPONENT_MAP(_component ,src ,"out_MEMORY_OUT_"+toString(j)+"_OOO_ENGINE_ID",
983                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_"+toString(j)+"_OOO_ENGINE_ID");
984               if (_param->_have_port_rob_ptr  )
985               COMPONENT_MAP(_component ,src ,"out_MEMORY_OUT_"+toString(j)+"_PACKET_ID"    ,
986                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_"+toString(j)+"_PACKET_ID"    );
987//             COMPONENT_MAP(_component ,src ,"out_MEMORY_OUT_"+toString(j)+"_OPERATION"    ,
988//                                       dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_"+toString(j)+"_OPERATION"    );
989//             COMPONENT_MAP(_component ,src ,"out_MEMORY_OUT_"+toString(j)+"_TYPE"         ,
990//                                       dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_"+toString(j)+"_TYPE"         );
991               COMPONENT_MAP(_component ,src ,"out_MEMORY_OUT_"+toString(j)+"_WRITE_RD"     ,
992                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_"+toString(j)+"_WRITE_RD"     );
993               COMPONENT_MAP(_component ,src ,"out_MEMORY_OUT_"+toString(j)+"_NUM_REG_RD"   ,
994                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_"+toString(j)+"_NUM_REG_RD"   );
995               COMPONENT_MAP(_component ,src ,"out_MEMORY_OUT_"+toString(j)+"_DATA_RD"      ,
996                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_"+toString(j)+"_DATA_RD"      );
997               COMPONENT_MAP(_component ,src ,"out_MEMORY_OUT_"+toString(j)+"_WRITE_RE"     ,
998                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_"+toString(j)+"_WRITE_RE"     );
999               COMPONENT_MAP(_component ,src ,"out_MEMORY_OUT_"+toString(j)+"_NUM_REG_RE"   ,
1000                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_"+toString(j)+"_NUM_REG_RE"   );
1001               COMPONENT_MAP(_component ,src ,"out_MEMORY_OUT_"+toString(j)+"_DATA_RE"      ,
1002                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_"+toString(j)+"_DATA_RE"      );
1003               COMPONENT_MAP(_component ,src ,"out_MEMORY_OUT_"+toString(j)+"_EXCEPTION"    ,
1004                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_"+toString(j)+"_EXCEPTION"    );
1005               COMPONENT_MAP(_component ,src ,"out_MEMORY_OUT_"+toString(j)+"_NO_SEQUENCE"  ,
1006                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_"+toString(j)+"_NO_SEQUENCE"  );
1007               COMPONENT_MAP(_component ,src ,"out_MEMORY_OUT_"+toString(j)+"_ADDRESS"      ,
1008                                         dest, "in_EXECUTE_UNIT_OUT_"+toString(i)+"_"+toString(j)+"_ADDRESS"      );
1009             }
1010             
1011             // ~~~~~[ Interface "dcache_req" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1012             for (uint32_t j=0; j<_param->_nb_cache_port [x]; j++)
1013             {
1014               dest = _name;
1015               
1016#ifdef POSITION
1017               _component->interface_map (src ,"dcache_req_"+toString(j),
1018                                          dest,"dcache_req_"+toString(x)+"_"+toString(j));
1019#endif
1020               PORT_MAP(_component ,src ,"out_DCACHE_REQ_"+toString(j)+"_VAL"       ,dest,"out_DCACHE_REQ_"+toString(x)+"_"+toString(j)+"_VAL"       );
1021               PORT_MAP(_component ,src , "in_DCACHE_REQ_"+toString(j)+"_ACK"       ,dest, "in_DCACHE_REQ_"+toString(x)+"_"+toString(j)+"_ACK"       );
1022               if (_param->_have_port_dcache_context_id)
1023               PORT_MAP(_component ,src ,"out_DCACHE_REQ_"+toString(j)+"_CONTEXT_ID",dest,"out_DCACHE_REQ_"+toString(x)+"_"+toString(j)+"_CONTEXT_ID");
1024               PORT_MAP(_component ,src ,"out_DCACHE_REQ_"+toString(j)+"_PACKET_ID" ,dest,"out_DCACHE_REQ_"+toString(x)+"_"+toString(j)+"_PACKET_ID" );
1025               PORT_MAP(_component ,src ,"out_DCACHE_REQ_"+toString(j)+"_ADDRESS"   ,dest,"out_DCACHE_REQ_"+toString(x)+"_"+toString(j)+"_ADDRESS"   );
1026               PORT_MAP(_component ,src ,"out_DCACHE_REQ_"+toString(j)+"_TYPE"      ,dest,"out_DCACHE_REQ_"+toString(x)+"_"+toString(j)+"_TYPE"      );
1027               PORT_MAP(_component ,src ,"out_DCACHE_REQ_"+toString(j)+"_WDATA"     ,dest,"out_DCACHE_REQ_"+toString(x)+"_"+toString(j)+"_WDATA"     );
1028             }
1029
1030             // ~~~~~[ Interface "dcache_rsp" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1031             for (uint32_t j=0; j<_param->_nb_cache_port [x]; j++)
1032             {
1033               dest = _name;
1034               
1035#ifdef POSITION
1036               _component->interface_map (src ,"dcache_rsp_"+toString(j),
1037                                          dest,"dcache_rsp_"+toString(x)+"_"+toString(j));
1038#endif
1039               PORT_MAP(_component ,src , "in_DCACHE_RSP_"+toString(j)+"_VAL"       ,dest, "in_DCACHE_RSP_"+toString(x)+"_"+toString(j)+"_VAL"       );
1040               PORT_MAP(_component ,src ,"out_DCACHE_RSP_"+toString(j)+"_ACK"       ,dest,"out_DCACHE_RSP_"+toString(x)+"_"+toString(j)+"_ACK"       );
1041               if (_param->_have_port_dcache_context_id)
1042               PORT_MAP(_component ,src , "in_DCACHE_RSP_"+toString(j)+"_CONTEXT_ID",dest, "in_DCACHE_RSP_"+toString(x)+"_"+toString(j)+"_CONTEXT_ID");
1043               PORT_MAP(_component ,src , "in_DCACHE_RSP_"+toString(j)+"_PACKET_ID" ,dest, "in_DCACHE_RSP_"+toString(x)+"_"+toString(j)+"_PACKET_ID" );
1044               PORT_MAP(_component ,src , "in_DCACHE_RSP_"+toString(j)+"_RDATA"     ,dest, "in_DCACHE_RSP_"+toString(x)+"_"+toString(j)+"_RDATA"     );
1045               PORT_MAP(_component ,src , "in_DCACHE_RSP_"+toString(j)+"_ERROR"     ,dest, "in_DCACHE_RSP_"+toString(x)+"_"+toString(j)+"_ERROR"     );
1046             }
1047
1048             // ~~~~~[ Interface "bypass_memory" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1049             {
1050               // Port map with "read_unit" is ok!
1051             }
1052           }
1053       }
1054
1055     // ===================================================================
1056     // =====[ WRITE_UNIT ]================================================
1057     // ===================================================================
1058     for (uint32_t i=0; i<_param->_nb_write_unit; i++)
1059       {
1060         src = _name+"_write_unit_"+toString(i);
1061         log_printf(INFO,Core,FUNCTION,_("Instance : %s"),src.c_str());
1062         
1063         {
1064           dest = _name;
1065#ifdef POSITION
1066           _component->interface_map (src ,"",
1067                                      dest,"");
1068#endif
1069           PORT_MAP(_component ,src , "in_CLOCK" ,dest, "in_CLOCK");
1070           PORT_MAP(_component ,src , "in_NRESET",dest, "in_NRESET");
1071         }
1072
1073         // -----[ Interface "write_unit_in" ]---------------------------------   
1074         {
1075           dest = _name+"_execution_unit_to_write_unit";
1076#ifdef POSITION
1077           _component->interface_map (src ,"write_unit_in",
1078                                      dest,"execute_unit_in_"+toString(i));
1079#endif
1080           
1081           COMPONENT_MAP(_component ,src , "in_WRITE_UNIT_IN_VAL"          ,
1082                                     dest,"out_WRITE_UNIT_IN_"+toString(i)+"_VAL"          );
1083           COMPONENT_MAP(_component ,src ,"out_WRITE_UNIT_IN_ACK"          ,
1084                                     dest, "in_WRITE_UNIT_IN_"+toString(i)+"_ACK"          );
1085           if (_param->_have_port_context_id)
1086           COMPONENT_MAP(_component ,src , "in_WRITE_UNIT_IN_CONTEXT_ID"   ,
1087                                     dest,"out_WRITE_UNIT_IN_"+toString(i)+"_CONTEXT_ID"   );
1088           if (_param->_have_port_front_end_id)
1089           COMPONENT_MAP(_component ,src , "in_WRITE_UNIT_IN_FRONT_END_ID" ,
1090                                     dest,"out_WRITE_UNIT_IN_"+toString(i)+"_FRONT_END_ID" );
1091           if (_param->_have_port_ooo_engine_id)
1092           COMPONENT_MAP(_component ,src , "in_WRITE_UNIT_IN_OOO_ENGINE_ID",
1093                                     dest,"out_WRITE_UNIT_IN_"+toString(i)+"_OOO_ENGINE_ID");
1094           if (_param->_have_port_rob_ptr  )
1095           COMPONENT_MAP(_component ,src , "in_WRITE_UNIT_IN_PACKET_ID"    ,
1096                                     dest,"out_WRITE_UNIT_IN_"+toString(i)+"_PACKET_ID"    );
1097//         COMPONENT_MAP(_component ,src , "in_WRITE_UNIT_IN_OPERATION"    ,
1098//                                   dest,"out_WRITE_UNIT_IN_"+toString(i)+"_OPERATION"    );
1099//         COMPONENT_MAP(_component ,src , "in_WRITE_UNIT_IN_TYPE"         ,
1100//                                   dest,"out_WRITE_UNIT_IN_"+toString(i)+"_TYPE"         );
1101           COMPONENT_MAP(_component ,src , "in_WRITE_UNIT_IN_WRITE_RD"     ,
1102                                     dest,"out_WRITE_UNIT_IN_"+toString(i)+"_WRITE_RD"     );
1103           COMPONENT_MAP(_component ,src , "in_WRITE_UNIT_IN_NUM_REG_RD"   ,
1104                                     dest,"out_WRITE_UNIT_IN_"+toString(i)+"_NUM_REG_RD"   );
1105           COMPONENT_MAP(_component ,src , "in_WRITE_UNIT_IN_DATA_RD"      ,
1106                                     dest,"out_WRITE_UNIT_IN_"+toString(i)+"_DATA_RD"      );
1107           COMPONENT_MAP(_component ,src , "in_WRITE_UNIT_IN_WRITE_RE"     ,
1108                                     dest,"out_WRITE_UNIT_IN_"+toString(i)+"_WRITE_RE"     );
1109           COMPONENT_MAP(_component ,src , "in_WRITE_UNIT_IN_NUM_REG_RE"   ,
1110                                     dest,"out_WRITE_UNIT_IN_"+toString(i)+"_NUM_REG_RE"   );
1111           COMPONENT_MAP(_component ,src , "in_WRITE_UNIT_IN_DATA_RE"      ,
1112                                     dest,"out_WRITE_UNIT_IN_"+toString(i)+"_DATA_RE"      );
1113           COMPONENT_MAP(_component ,src , "in_WRITE_UNIT_IN_EXCEPTION"    ,
1114                                     dest,"out_WRITE_UNIT_IN_"+toString(i)+"_EXCEPTION"    );
1115           COMPONENT_MAP(_component ,src , "in_WRITE_UNIT_IN_NO_SEQUENCE"  ,
1116                                     dest,"out_WRITE_UNIT_IN_"+toString(i)+"_NO_SEQUENCE"  );
1117           COMPONENT_MAP(_component ,src , "in_WRITE_UNIT_IN_ADDRESS"      ,
1118                                     dest,"out_WRITE_UNIT_IN_"+toString(i)+"_ADDRESS"      );
1119         }
1120
1121         // -----[ Interface "write_unit_out" ]--------------------------------   
1122         {
1123           dest = _name;
1124#ifdef POSITION
1125           _component->interface_map (src ,"write_unit_out",
1126                                      dest,"execute_loop_out_"+toString(i));
1127#endif
1128           
1129           PORT_MAP(_component ,src ,"out_WRITE_UNIT_OUT_VAL"          ,
1130                                dest,"out_EXECUTE_LOOP_OUT_"+toString(i)+"_VAL"          );
1131           PORT_MAP(_component ,src , "in_WRITE_UNIT_OUT_ACK"          ,
1132                                dest, "in_EXECUTE_LOOP_OUT_"+toString(i)+"_ACK"          );
1133           if (_param->_have_port_context_id)
1134           PORT_MAP(_component ,src ,"out_WRITE_UNIT_OUT_CONTEXT_ID"   ,
1135                                dest,"out_EXECUTE_LOOP_OUT_"+toString(i)+"_CONTEXT_ID"   );
1136           if (_param->_have_port_front_end_id)
1137           PORT_MAP(_component ,src ,"out_WRITE_UNIT_OUT_FRONT_END_ID" ,
1138                                dest,"out_EXECUTE_LOOP_OUT_"+toString(i)+"_FRONT_END_ID" );
1139           if (_param->_have_port_ooo_engine_id)
1140           PORT_MAP(_component ,src ,"out_WRITE_UNIT_OUT_OOO_ENGINE_ID",
1141                                dest,"out_EXECUTE_LOOP_OUT_"+toString(i)+"_OOO_ENGINE_ID");
1142           if (_param->_have_port_rob_ptr  )
1143           PORT_MAP(_component ,src ,"out_WRITE_UNIT_OUT_PACKET_ID"    ,
1144                                dest,"out_EXECUTE_LOOP_OUT_"+toString(i)+"_PACKET_ID"    );
1145//         PORT_MAP(_component ,src ,"out_WRITE_UNIT_OUT_OPERATION"    ,
1146//                              dest,"out_EXECUTE_LOOP_OUT_"+toString(i)+"_OPERATION"    );
1147//         PORT_MAP(_component ,src ,"out_WRITE_UNIT_OUT_TYPE"         ,
1148//                              dest,"out_EXECUTE_LOOP_OUT_"+toString(i)+"_TYPE"         );
1149           PORT_MAP(_component ,src ,"out_WRITE_UNIT_OUT_FLAGS"        ,
1150                                dest,"out_EXECUTE_LOOP_OUT_"+toString(i)+"_FLAGS"        );
1151           PORT_MAP(_component ,src ,"out_WRITE_UNIT_OUT_EXCEPTION"    ,
1152                                dest,"out_EXECUTE_LOOP_OUT_"+toString(i)+"_EXCEPTION"    );
1153           PORT_MAP(_component ,src ,"out_WRITE_UNIT_OUT_NO_SEQUENCE"  ,
1154                                dest,"out_EXECUTE_LOOP_OUT_"+toString(i)+"_NO_SEQUENCE"  );
1155           PORT_MAP(_component ,src ,"out_WRITE_UNIT_OUT_ADDRESS"      ,
1156                                dest,"out_EXECUTE_LOOP_OUT_"+toString(i)+"_ADDRESS"      );
1157           PORT_MAP(_component ,src ,"out_WRITE_UNIT_OUT_DATA"         ,
1158                                dest,"out_EXECUTE_LOOP_OUT_"+toString(i)+"_DATA"         );
1159         }
1160
1161         // -----[ Interface "gpr_write" ]-------------------------------------
1162         {
1163           dest = _name+"_glue";
1164#ifdef POSITION
1165           _component->interface_map (src ,"gpr_write",
1166                                      dest,"gpr_write_write_unit_"+toString(i));
1167#endif
1168
1169           COMPONENT_MAP(_component ,src ,"out_GPR_WRITE_0_VAL"          ,
1170                                     dest, "in_GPR_WRITE_WRITE_UNIT_"+toString(i)+"_VAL"          );
1171           COMPONENT_MAP(_component ,src , "in_GPR_WRITE_0_ACK"          ,
1172                                     dest,"out_GPR_WRITE_WRITE_UNIT_"+toString(i)+"_ACK"          );
1173           if (_param->_have_port_ooo_engine_id)
1174           COMPONENT_MAP(_component ,src ,"out_GPR_WRITE_0_OOO_ENGINE_ID",
1175                                     dest, "in_GPR_WRITE_WRITE_UNIT_"+toString(i)+"_OOO_ENGINE_ID");
1176           COMPONENT_MAP(_component ,src ,"out_GPR_WRITE_0_NUM_REG"      ,
1177                                     dest, "in_GPR_WRITE_WRITE_UNIT_"+toString(i)+"_NUM_REG"      );
1178           COMPONENT_MAP(_component ,src ,"out_GPR_WRITE_0_DATA"         ,
1179                                     dest, "in_GPR_WRITE_WRITE_UNIT_"+toString(i)+"_DATA"         );
1180         }
1181
1182         // -----[ Interface "spr_write" ]-------------------------------------
1183         {
1184           // Port map with "read_unit" is ok!
1185
1186           dest = _name+"_glue";
1187#ifdef POSITION
1188           _component->interface_map (src ,"spr_write",
1189                                      dest,"spr_write_write_unit_"+toString(i));
1190#endif
1191
1192           COMPONENT_MAP(_component ,src ,"out_SPR_WRITE_0_VAL"          ,
1193                                     dest, "in_SPR_WRITE_WRITE_UNIT_"+toString(i)+"_VAL"          );
1194           COMPONENT_MAP(_component ,src , "in_SPR_WRITE_0_ACK"          ,
1195                                     dest,"out_SPR_WRITE_WRITE_UNIT_"+toString(i)+"_ACK"          );
1196           if (_param->_have_port_ooo_engine_id)
1197           COMPONENT_MAP(_component ,src ,"out_SPR_WRITE_0_OOO_ENGINE_ID",
1198                                     dest, "in_SPR_WRITE_WRITE_UNIT_"+toString(i)+"_OOO_ENGINE_ID");
1199           COMPONENT_MAP(_component ,src ,"out_SPR_WRITE_0_NUM_REG"      ,
1200                                     dest, "in_SPR_WRITE_WRITE_UNIT_"+toString(i)+"_NUM_REG"      );
1201           COMPONENT_MAP(_component ,src ,"out_SPR_WRITE_0_DATA"         ,
1202                                     dest, "in_SPR_WRITE_WRITE_UNIT_"+toString(i)+"_DATA"         );
1203         }
1204
1205         // -----[ Interface "bypass_write" ]----------------------------------
1206         {
1207           // Port map with "read_unit" is ok!
1208         }
1209       }
1210
1211     // ===================================================================
1212     // =====[ REGISTER_UNIT ]=============================================
1213     // ===================================================================
1214     {
1215       src = _name+"_register_unit";
1216       log_printf(INFO,Core,FUNCTION,_("Instance : %s"),src.c_str());
1217       
1218       {
1219         dest = _name;
1220#ifdef POSITION
1221         _component->interface_map (src ,"",
1222                                    dest,"");
1223#endif
1224         PORT_MAP(_component ,src , "in_CLOCK" ,dest, "in_CLOCK");
1225         PORT_MAP(_component ,src , "in_NRESET",dest, "in_NRESET");
1226       }
1227
1228       // ~~~~~[ Interface "gpr_read" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1229       for (uint32_t i=0; i<_param->_nb_read_unit; i++)
1230         {
1231           dest = _name+"_read_unit_"+toString(i);
1232#ifdef POSITION
1233           _component->interface_map (src ,"gpr_read_"+toString(2*)
1234                                      dest,"gpr_read_0");
1235           _component->interface_map (src ,"gpr_read_"+toString(2*i+1)
1236                                      dest,"gpr_read_1");
1237#endif
1238       
1239//       PORT_MAP(_component ,src , "in_GPR_READ_"+toString(2*i  )+"_VAL"          ,dest,"out_GPR_READ_0_VAL"          );
1240//       PORT_MAP(_component ,src ,"out_GPR_READ_"+toString(2*i  )+"_ACK"          ,dest, "in_GPR_READ_0_ACK"          );
1241//       if (_param->_have_port_context_id)
1242//       PORT_MAP(_component ,src , "in_GPR_READ_"+toString(2*i  )+"_OOO_ENGINE_ID",dest,"out_GPR_READ_0_OOO_ENGINE_ID");
1243//       PORT_MAP(_component ,src , "in_GPR_READ_"+toString(2*i  )+"_NUM_REG"      ,dest,"out_GPR_READ_0_NUM_REG"      );
1244//       PORT_MAP(_component ,src ,"out_GPR_READ_"+toString(2*i  )+"_DATA"         ,dest, "in_GPR_READ_0_DATA"         );
1245//       PORT_MAP(_component ,src ,"out_GPR_READ_"+toString(2*i  )+"_DATA_VAL"     ,dest, "in_GPR_READ_0_DATA_VAL"     );
1246
1247//       PORT_MAP(_component ,src , "in_GPR_READ_"+toString(2*i+1)+"_VAL"          ,dest,"out_GPR_READ_1_VAL"          );
1248//       PORT_MAP(_component ,src ,"out_GPR_READ_"+toString(2*i+1)+"_ACK"          ,dest, "in_GPR_READ_1_ACK"          );
1249//       if (_param->_have_port_context_id)
1250//       PORT_MAP(_component ,src , "in_GPR_READ_"+toString(2*i+1)+"_OOO_ENGINE_ID",dest,"out_GPR_READ_1_OOO_ENGINE_ID");
1251//       PORT_MAP(_component ,src , "in_GPR_READ_"+toString(2*i+1)+"_NUM_REG"      ,dest,"out_GPR_READ_1_NUM_REG"      );
1252//       PORT_MAP(_component ,src ,"out_GPR_READ_"+toString(2*i+1)+"_DATA"         ,dest, "in_GPR_READ_1_DATA"         );
1253//       PORT_MAP(_component ,src ,"out_GPR_READ_"+toString(2*i+1)+"_DATA_VAL"     ,dest, "in_GPR_READ_1_DATA_VAL"     );
1254         }
1255
1256       // ~~~~~[ Interface "gpr_write" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1257       for (uint32_t i=0; i<_param->_nb_write_unit; i++)
1258         {
1259           dest = _name+"_glue";
1260#ifdef POSITION
1261           _component->interface_map (src ,"gpr_write_"+toString(i),
1262                                      dest,"gpr_write_register_file_"+toString(i));
1263#endif
1264       
1265           COMPONENT_MAP(_component ,src , "in_GPR_WRITE_"+toString(i)+"_VAL"          ,dest,"out_GPR_WRITE_REGISTER_FILE_"+toString(i)+"_VAL"          );
1266           COMPONENT_MAP(_component ,src ,"out_GPR_WRITE_"+toString(i)+"_ACK"          ,dest, "in_GPR_WRITE_REGISTER_FILE_"+toString(i)+"_ACK"          );
1267           if (_param->_have_port_ooo_engine_id)
1268           COMPONENT_MAP(_component ,src , "in_GPR_WRITE_"+toString(i)+"_OOO_ENGINE_ID",dest,"out_GPR_WRITE_REGISTER_FILE_"+toString(i)+"_OOO_ENGINE_ID");
1269           COMPONENT_MAP(_component ,src , "in_GPR_WRITE_"+toString(i)+"_NUM_REG"      ,dest,"out_GPR_WRITE_REGISTER_FILE_"+toString(i)+"_NUM_REG"      );
1270           COMPONENT_MAP(_component ,src , "in_GPR_WRITE_"+toString(i)+"_DATA"         ,dest,"out_GPR_WRITE_REGISTER_FILE_"+toString(i)+"_DATA"         );
1271         }
1272
1273       // ~~~~~[ Interface "spr_read" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1274       for (uint32_t i=0; i<_param->_nb_read_unit; i++)
1275         {
1276           dest = _name+"_read_unit_"+toString(i);
1277#ifdef POSITION
1278           _component->interface_map (src ,"spr_read_"+toString(i),
1279                                      dest,"spr_read_0");
1280#endif
1281       
1282//         PORT_MAP(_component ,src , "in_SPR_READ_"+toString(i)+"_VAL"          ,dest,"out_SPR_READ_0_VAL"          );
1283//         PORT_MAP(_component ,src ,"out_SPR_READ_"+toString(i)+"_ACK"          ,dest, "in_SPR_READ_0_ACK"          );
1284//         if (_param->_have_port_context_id)
1285//         PORT_MAP(_component ,src , "in_SPR_READ_"+toString(i)+"_OOO_ENGINE_ID",dest,"out_SPR_READ_0_OOO_ENGINE_ID");
1286//         PORT_MAP(_component ,src , "in_SPR_READ_"+toString(i)+"_NUM_REG"      ,dest,"out_SPR_READ_0_NUM_REG"      );
1287//         PORT_MAP(_component ,src ,"out_SPR_READ_"+toString(i)+"_DATA"         ,dest, "in_SPR_READ_0_DATA"         );
1288//         PORT_MAP(_component ,src ,"out_SPR_READ_"+toString(i)+"_DATA_VAL"     ,dest, "in_SPR_READ_0_DATA_VAL"     );
1289         }
1290
1291       // ~~~~~[ Interface "spr_write" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1292       for (uint32_t i=0; i<_param->_nb_write_unit; i++)
1293         {
1294           dest = _name+"_glue";
1295#ifdef POSITION
1296           _component->interface_map (src ,"spr_write_"+toString(i),
1297                                      dest,"spr_write_register_file_"+toString(i));
1298#endif
1299       
1300           COMPONENT_MAP(_component ,src , "in_SPR_WRITE_"+toString(i)+"_VAL"          ,dest,"out_SPR_WRITE_REGISTER_FILE_"+toString(i)+"_VAL"          );
1301           COMPONENT_MAP(_component ,src ,"out_SPR_WRITE_"+toString(i)+"_ACK"          ,dest, "in_SPR_WRITE_REGISTER_FILE_"+toString(i)+"_ACK"          );
1302           if (_param->_have_port_ooo_engine_id)
1303           COMPONENT_MAP(_component ,src , "in_SPR_WRITE_"+toString(i)+"_OOO_ENGINE_ID",dest,"out_SPR_WRITE_REGISTER_FILE_"+toString(i)+"_OOO_ENGINE_ID");
1304           COMPONENT_MAP(_component ,src , "in_SPR_WRITE_"+toString(i)+"_NUM_REG"      ,dest,"out_SPR_WRITE_REGISTER_FILE_"+toString(i)+"_NUM_REG"      );
1305           COMPONENT_MAP(_component ,src , "in_SPR_WRITE_"+toString(i)+"_DATA"         ,dest,"out_SPR_WRITE_REGISTER_FILE_"+toString(i)+"_DATA"         );
1306         }
1307   
1308       // ~~~~~[ Interface "insert_rob" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1309       for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
1310         {
1311           uint32_t x=_param->_nb_inst_insert_rob [i];
1312           
1313           for (uint32_t j=0; j<x; j++)
1314             {
1315               dest = _name;
1316#ifdef POSITION
1317               _component->interface_map (src ,"insert_rob_"+toString(i)+"_"+toString(j),
1318                                          dest,"insert_rob_"+toString(i)+"_"+toString(j));
1319#endif
1320
1321               PORT_MAP(_component ,src , "in_INSERT_ROB_"+toString(i)+"_"+toString(j)+"_VAL"       ,
1322                                    dest, "in_INSERT_ROB_"+toString(i)+"_"+toString(j)+"_VAL"       );
1323               PORT_MAP(_component ,src ,"out_INSERT_ROB_"+toString(i)+"_"+toString(j)+"_ACK"       ,
1324                                    dest,"out_INSERT_ROB_"+toString(i)+"_"+toString(j)+"_ACK"       );
1325               PORT_MAP(_component ,src , "in_INSERT_ROB_"+toString(i)+"_"+toString(j)+"_RD_USE"    ,
1326                                    dest, "in_INSERT_ROB_"+toString(i)+"_"+toString(j)+"_RD_USE"    );
1327               PORT_MAP(_component ,src , "in_INSERT_ROB_"+toString(i)+"_"+toString(j)+"_RD_NUM_REG",
1328                                    dest, "in_INSERT_ROB_"+toString(i)+"_"+toString(j)+"_RD_NUM_REG");
1329               PORT_MAP(_component ,src , "in_INSERT_ROB_"+toString(i)+"_"+toString(j)+"_RE_USE"    ,
1330                                    dest, "in_INSERT_ROB_"+toString(i)+"_"+toString(j)+"_RE_USE"    );
1331               PORT_MAP(_component ,src , "in_INSERT_ROB_"+toString(i)+"_"+toString(j)+"_RE_NUM_REG",
1332                                    dest, "in_INSERT_ROB_"+toString(i)+"_"+toString(j)+"_RE_NUM_REG");
1333             }
1334         }
1335
1336//        // ~~~~~[ Interface "retire_rob" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1337//        for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
1338//       {
1339//         uint32_t x=_param->_nb_inst_retire_rob [i];
1340           
1341//         for (uint32_t j=0; j<x; j++)
1342//           {
1343//             dest = _name;
1344// #ifdef POSITION
1345//             _component->interface_map (src ,"retire_rob_"+toString(i)+"_"+toString(j),
1346//                                        dest,"retire_rob_"+toString(i)+"_"+toString(j));
1347// #endif
1348
1349//             PORT_MAP(_component ,src , "in_RETIRE_ROB_"+toString(i)+"_"+toString(j)+"_VAL"           ,
1350//                                  dest, "in_RETIRE_ROB_"+toString(i)+"_"+toString(j)+"_VAL"           );
1351//             PORT_MAP(_component ,src ,"out_RETIRE_ROB_"+toString(i)+"_"+toString(j)+"_ACK"           ,
1352//                                  dest,"out_RETIRE_ROB_"+toString(i)+"_"+toString(j)+"_ACK"           );
1353//             PORT_MAP(_component ,src , "in_RETIRE_ROB_"+toString(i)+"_"+toString(j)+"_RD_OLD_USE"    ,
1354//                                  dest, "in_RETIRE_ROB_"+toString(i)+"_"+toString(j)+"_RD_OLD_USE"    );
1355//             PORT_MAP(_component ,src , "in_RETIRE_ROB_"+toString(i)+"_"+toString(j)+"_RD_OLD_NUM_REG",
1356//                                  dest, "in_RETIRE_ROB_"+toString(i)+"_"+toString(j)+"_RD_OLD_NUM_REG");
1357//             PORT_MAP(_component ,src , "in_RETIRE_ROB_"+toString(i)+"_"+toString(j)+"_RD_NEW_USE"    ,
1358//                                  dest, "in_RETIRE_ROB_"+toString(i)+"_"+toString(j)+"_RD_NEW_USE"    );
1359//             PORT_MAP(_component ,src , "in_RETIRE_ROB_"+toString(i)+"_"+toString(j)+"_RD_NEW_NUM_REG",
1360//                                  dest, "in_RETIRE_ROB_"+toString(i)+"_"+toString(j)+"_RD_NEW_NUM_REG");
1361//             PORT_MAP(_component ,src , "in_RETIRE_ROB_"+toString(i)+"_"+toString(j)+"_RE_OLD_USE"    ,
1362//                                  dest, "in_RETIRE_ROB_"+toString(i)+"_"+toString(j)+"_RE_OLD_USE"    );
1363//             PORT_MAP(_component ,src , "in_RETIRE_ROB_"+toString(i)+"_"+toString(j)+"_RE_OLD_NUM_REG",
1364//                                  dest, "in_RETIRE_ROB_"+toString(i)+"_"+toString(j)+"_RE_OLD_NUM_REG");
1365//             PORT_MAP(_component ,src , "in_RETIRE_ROB_"+toString(i)+"_"+toString(j)+"_RE_NEW_USE"    ,
1366//                                  dest, "in_RETIRE_ROB_"+toString(i)+"_"+toString(j)+"_RE_NEW_USE"    );
1367//             PORT_MAP(_component ,src , "in_RETIRE_ROB_"+toString(i)+"_"+toString(j)+"_RE_NEW_NUM_REG",
1368//                                  dest, "in_RETIRE_ROB_"+toString(i)+"_"+toString(j)+"_RE_NEW_NUM_REG");
1369//           }
1370//       }
1371     }
1372
1373     // ===================================================================
1374     // =====[ READ_UNIT_TO_EXECUTION_UNIT ]===============================
1375     // ===================================================================
1376     {
1377       src = _name+"_read_unit_to_execution_unit";
1378       log_printf(INFO,Core,FUNCTION,_("Instance : %s"),src.c_str());
1379       
1380       {
1381         dest = _name;
1382#ifdef POSITION
1383         _component->interface_map (src ,"",
1384                                    dest,"");
1385#endif
1386         PORT_MAP(_component ,src , "in_CLOCK" ,dest, "in_CLOCK");
1387         PORT_MAP(_component ,src , "in_NRESET",dest, "in_NRESET");
1388       }
1389
1390       // ~~~~~[ Interface "read_unit_out" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1391       uint32_t it_read_unit_out =0;
1392       for (uint32_t i=0; i < _param->_nb_read_unit; i++)
1393         for (uint32_t j=0; j < _param->_nb_inst_retire[i]; j++)
1394           {
1395             dest = _name+"_read_unit_"+toString(i);
1396             
1397#ifdef POSITION
1398             _component->interface_map (src ,"read_unit_"+toString(it_read_unit_out),
1399                                        dest,"read_unit_"+toString(j));
1400#endif
1401             
1402//           PORT_MAP(_component ,src , "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_VAL"                  ,
1403//                                dest,"out_READ_UNIT_OUT_"+toString(j               )+"_VAL"                  );
1404//           PORT_MAP(_component ,src ,"out_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_ACK"                  ,
1405//                                dest, "in_READ_UNIT_OUT_"+toString(j               )+"_ACK"                  );
1406//           if (_param->_have_port_context_id)
1407//           PORT_MAP(_component ,src , "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_CONTEXT_ID"           ,
1408//                                dest,"out_READ_UNIT_OUT_"+toString(j               )+"_CONTEXT_ID"           );
1409//           if (_param->_have_port_front_end_id)
1410//           PORT_MAP(_component ,src , "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_FRONT_END_ID"         ,
1411//                                dest,"out_READ_UNIT_OUT_"+toString(j               )+"_FRONT_END_ID"         );
1412//           if (_param->_have_port_ooo_engine_id)
1413//           PORT_MAP(_component ,src , "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_OOO_ENGINE_ID"        ,
1414//                                dest,"out_READ_UNIT_OUT_"+toString(j               )+"_OOO_ENGINE_ID"        );
1415//           if (_param->_have_port_rob_ptr  )
1416//           PORT_MAP(_component ,src , "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_PACKET_ID"            ,
1417//                                dest,"out_READ_UNIT_OUT_"+toString(j               )+"_PACKET_ID"            );
1418//           PORT_MAP(_component ,src , "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_OPERATION"            ,
1419//                                dest,"out_READ_UNIT_OUT_"+toString(j               )+"_OPERATION"            );
1420//           PORT_MAP(_component ,src , "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_TYPE"                 ,
1421//                                dest,"out_READ_UNIT_OUT_"+toString(j               )+"_TYPE"                 );
1422//           PORT_MAP(_component ,src , "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_STORE_QUEUE_PTR_WRITE",
1423//                                dest,"out_READ_UNIT_OUT_"+toString(j               )+"_STORE_QUEUE_PTR_WRITE");
1424//           if (_param->_have_port_load_queue_ptr)
1425//           PORT_MAP(_component ,src , "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_LOAD_QUEUE_PTR_WRITE" ,
1426//                                dest,"out_READ_UNIT_OUT_"+toString(j               )+"_LOAD_QUEUE_PTR_WRITE" );
1427//           PORT_MAP(_component ,src , "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_HAS_IMMEDIAT"         ,
1428//                                dest,"out_READ_UNIT_OUT_"+toString(j               )+"_HAS_IMMEDIAT"         );
1429//           PORT_MAP(_component ,src , "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_IMMEDIAT"             ,
1430//                                dest,"out_READ_UNIT_OUT_"+toString(j               )+"_IMMEDIAT"             );
1431//           PORT_MAP(_component ,src , "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_DATA_RA"              ,
1432//                                dest,"out_READ_UNIT_OUT_"+toString(j               )+"_DATA_RA"              );
1433//           PORT_MAP(_component ,src , "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_DATA_RB"              ,
1434//                                dest,"out_READ_UNIT_OUT_"+toString(j               )+"_DATA_RB"              );
1435//           PORT_MAP(_component ,src , "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_DATA_RC"              ,
1436//                                dest,"out_READ_UNIT_OUT_"+toString(j               )+"_DATA_RC"              );
1437//           PORT_MAP(_component ,src , "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_WRITE_RD"             ,
1438//                                dest,"out_READ_UNIT_OUT_"+toString(j               )+"_WRITE_RD"             );
1439//           PORT_MAP(_component ,src , "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_NUM_REG_RD"           ,
1440//                                dest,"out_READ_UNIT_OUT_"+toString(j               )+"_NUM_REG_RD"           );
1441//           PORT_MAP(_component ,src , "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_WRITE_RE"             ,
1442//                                dest,"out_READ_UNIT_OUT_"+toString(j               )+"_WRITE_RE"             );
1443//           PORT_MAP(_component ,src , "in_READ_UNIT_OUT_"+toString(it_read_unit_out)+"_NUM_REG_RE"           ,
1444//                                dest,"out_READ_UNIT_OUT_"+toString(j               )+"_NUM_REG_RE"           );
1445             
1446             it_read_unit_out ++;
1447           }
1448       
1449       // ~~~~~[ Interface "execute_unit_in" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1450       for (uint32_t i=0; i<_param->_nb_execute_unit; i++)
1451         {
1452           uint32_t x=_param->_translate_num_execute_unit[i];
1453           
1454           if (_param->_is_load_store_unit[i] == false)
1455             {
1456               dest = _name+"_functionnal_unit_"+toString(x);
1457               
1458#ifdef POSITION
1459               _component->interface_map (src ,"execute_unit_in_"+toString(i),
1460                                          dest,"execute_in");
1461#endif
1462               
1463//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_VAL"                  ,
1464//                                  dest, "in_EXECUTE_IN_VAL"                  );
1465//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_IN_"+toString(i)+"_ACK"                  ,
1466//                                  dest,"out_EXECUTE_IN_ACK"                  );
1467//             if (_param->_have_port_context_id)
1468//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_CONTEXT_ID"           ,
1469//                                  dest, "in_EXECUTE_IN_CONTEXT_ID"           );
1470//             if (_param->_have_port_front_end_id)
1471//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_FRONT_END_ID"         ,
1472//                                  dest, "in_EXECUTE_IN_FRONT_END_ID"         );
1473//             if (_param->_have_port_ooo_engine_id)
1474//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_OOO_ENGINE_ID"        ,
1475//                                  dest, "in_EXECUTE_IN_OOO_ENGINE_ID"        );
1476//             if (_param->_have_port_rob_ptr  )
1477//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_PACKET_ID"            ,
1478//                                  dest, "in_EXECUTE_IN_PACKET_ID"            );
1479//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_OPERATION"            ,
1480//                                  dest, "in_EXECUTE_IN_OPERATION"            );
1481//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_TYPE"                 ,
1482//                                  dest, "in_EXECUTE_IN_TYPE"                 );
1483//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_STORE_QUEUE_PTR_WRITE",
1484//                                  dest, "in_EXECUTE_IN_STORE_QUEUE_PTR_WRITE");
1485//             if (_param->_have_port_load_queue_ptr)
1486//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_LOAD_QUEUE_PTR_WRITE" ,
1487//                                  dest, "in_EXECUTE_IN_LOAD_QUEUE_PTR_WRITE" );
1488//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_HAS_IMMEDIAT"         ,
1489//                                  dest, "in_EXECUTE_IN_HAS_IMMEDIAT"         );
1490//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_IMMEDIAT"             ,
1491//                                  dest, "in_EXECUTE_IN_IMMEDIAT"             );
1492//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_DATA_RA"              ,
1493//                                  dest, "in_EXECUTE_IN_DATA_RA"              );
1494//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_DATA_RB"              ,
1495//                                  dest, "in_EXECUTE_IN_DATA_RB"              );
1496//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_DATA_RC"              ,
1497//                                  dest, "in_EXECUTE_IN_DATA_RC"              );
1498//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_WRITE_RD"             ,
1499//                                  dest, "in_EXECUTE_IN_WRITE_RD"             );
1500//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_NUM_REG_RD"           ,
1501//                                  dest, "in_EXECUTE_IN_NUM_REG_RD"           );
1502//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_WRITE_RE"             ,
1503//                                  dest, "in_EXECUTE_IN_WRITE_RE"             );
1504//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_NUM_REG_RE"           ,
1505//                                  dest, "in_EXECUTE_IN_NUM_REG_RE"           );
1506             }
1507           else
1508             {
1509               dest = _name+"_load_store_unit_"+toString(x);
1510               
1511#ifdef POSITION
1512               _component->interface_map (src ,"execute_unit_in_"+toString(i),
1513                                          dest,"memory_in");
1514#endif
1515               
1516//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_VAL"                  ,
1517//                                  dest, "in_MEMORY_IN_VAL"                  );
1518//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_IN_"+toString(i)+"_ACK"                  ,
1519//                                  dest,"out_MEMORY_IN_ACK"                  );
1520//             if (_param->_have_port_context_id)
1521//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_CONTEXT_ID"           ,
1522//                                  dest, "in_MEMORY_IN_CONTEXT_ID"           );
1523//             if (_param->_have_port_front_end_id)
1524//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_FRONT_END_ID"         ,
1525//                                  dest, "in_MEMORY_IN_FRONT_END_ID"         );
1526//             if (_param->_have_port_ooo_engine_id)
1527//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_OOO_ENGINE_ID"        ,
1528//                                  dest, "in_MEMORY_IN_OOO_ENGINE_ID"        );
1529//             if (_param->_have_port_rob_ptr  )
1530//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_PACKET_ID"            ,
1531//                                  dest, "in_MEMORY_IN_PACKET_ID"            );
1532//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_OPERATION"            ,
1533//                                  dest, "in_MEMORY_IN_OPERATION"            );
1534//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_TYPE"                 ,
1535//                                  dest, "in_MEMORY_IN_TYPE"                 );
1536//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_STORE_QUEUE_PTR_WRITE",
1537//                                  dest, "in_MEMORY_IN_STORE_QUEUE_PTR_WRITE");
1538//             if (_param->_have_port_load_queue_ptr)
1539//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_LOAD_QUEUE_PTR_WRITE" ,
1540//                                  dest, "in_MEMORY_IN_LOAD_QUEUE_PTR_WRITE" );
1541//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_HAS_IMMEDIAT"         ,
1542//                                  dest, "in_MEMORY_IN_HAS_IMMEDIAT"         );
1543//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_IMMEDIAT"             ,
1544//                                  dest, "in_MEMORY_IN_IMMEDIAT"             );
1545//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_DATA_RA"              ,
1546//                                  dest, "in_MEMORY_IN_DATA_RA"              );
1547//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_DATA_RB"              ,
1548//                                  dest, "in_MEMORY_IN_DATA_RB"              );
1549//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_DATA_RC"              ,
1550//                                  dest, "in_MEMORY_IN_DATA_RC"              );
1551//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_WRITE_RD"             ,
1552//                                  dest, "in_MEMORY_IN_WRITE_RD"             );
1553//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_NUM_REG_RD"           ,
1554//                                  dest, "in_MEMORY_IN_NUM_REG_RD"           );
1555//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_WRITE_RE"             ,
1556//                                  dest, "in_MEMORY_IN_WRITE_RE"             );
1557//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_IN_"+toString(i)+"_NUM_REG_RE"           ,
1558//                                  dest, "in_MEMORY_IN_NUM_REG_RE"           );
1559             }
1560         }
1561     }
1562     
1563     // ===================================================================
1564     // =====[ EXECUTION_UNIT_TO_WRITE_UNIT ]==============================
1565     // ===================================================================
1566     {
1567       src = _name+"_execution_unit_to_write_unit";
1568       log_printf(INFO,Core,FUNCTION,_("Instance : %s"),src.c_str());
1569
1570       {
1571         dest = _name;
1572#ifdef POSITION
1573         _component->interface_map (src ,"",
1574                                    dest,"");
1575#endif
1576         PORT_MAP(_component ,src , "in_CLOCK" ,dest, "in_CLOCK");
1577         PORT_MAP(_component ,src , "in_NRESET",dest, "in_NRESET");
1578       }
1579
1580       // ~~~~~[ Interface "execute_unit_out" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1581       for (uint32_t i=0; i<_param->_nb_execute_unit; i++)
1582         {
1583           uint32_t x=_param->_translate_num_execute_unit[i];
1584           
1585           if (_param->_is_load_store_unit[i] == false)
1586             {
1587               dest = _name+"_functionnal_unit_"+toString(x);
1588               
1589#ifdef POSITION
1590               _component->interface_map (src ,"execute_unit_out_"+toString(i),
1591                                          dest,"execute_out");
1592#endif
1593//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_VAL"          ,
1594//                                  dest,"out_EXECUTE_OUT_VAL"          );
1595//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_OUT_"+toString(i)+"_ACK"          ,
1596//                                  dest, "in_EXECUTE_OUT_ACK"          );
1597//             if (_param->_have_port_context_id)
1598//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_CONTEXT_ID"   ,
1599//                                  dest,"out_EXECUTE_OUT_CONTEXT_ID"   );
1600//             if (_param->_have_port_front_end_id)
1601//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_FRONT_END_ID" ,
1602//                                  dest,"out_EXECUTE_OUT_FRONT_END_ID" );
1603//             if (_param->_have_port_ooo_engine_id)
1604//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_OOO_ENGINE_ID",
1605//                                  dest,"out_EXECUTE_OUT_OOO_ENGINE_ID");
1606//             if (_param->_have_port_rob_ptr  )
1607//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_PACKET_ID"    ,
1608//                                  dest,"out_EXECUTE_OUT_PACKET_ID"    );
1609// //          PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_OPERATION"    ,
1610// //                               dest,"out_EXECUTE_OUT_OPERATION"    );
1611// //          PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_TYPE"         ,
1612// //                               dest,"out_EXECUTE_OUT_TYPE"         );
1613//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_WRITE_RD"     ,
1614//                                  dest,"out_EXECUTE_OUT_WRITE_RD"     );
1615//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_NUM_REG_RD"   ,
1616//                                  dest,"out_EXECUTE_OUT_NUM_REG_RD"   );
1617//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_DATA_RD"      ,
1618//                                  dest,"out_EXECUTE_OUT_DATA_RD"      );
1619//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_WRITE_RE"     ,
1620//                                  dest,"out_EXECUTE_OUT_WRITE_RE"     );
1621//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_NUM_REG_RE"   ,
1622//                                  dest,"out_EXECUTE_OUT_NUM_REG_RE"   );
1623//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_DATA_RE"      ,
1624//                                  dest,"out_EXECUTE_OUT_DATA_RE"      );
1625//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_EXCEPTION"    ,
1626//                                  dest,"out_EXECUTE_OUT_EXCEPTION"    );
1627//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_NO_SEQUENCE"  ,
1628//                                  dest,"out_EXECUTE_OUT_NO_SEQUENCE"  );
1629//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_ADDRESS"      ,
1630//                                  dest,"out_EXECUTE_OUT_ADDRESS"      );
1631             }
1632           else
1633             {
1634               dest = _name+"_load_store_unit_"+toString(x);
1635               
1636#ifdef POSITION
1637               _component->interface_map (src ,"execute_unit_out_"+toString(i),
1638                                          dest,"memory_out");
1639#endif
1640//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_VAL"          ,
1641//                                  dest,"out_MEMORY_OUT_VAL"          );
1642//             PORT_MAP(_component ,src ,"out_EXECUTE_UNIT_OUT_"+toString(i)+"_ACK"          ,
1643//                                  dest, "in_MEMORY_OUT_ACK"          );
1644//             if (_param->_have_port_context_id)
1645//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_CONTEXT_ID"   ,
1646//                                  dest,"out_MEMORY_OUT_CONTEXT_ID"   );
1647//             if (_param->_have_port_front_end_id)
1648//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_FRONT_END_ID" ,
1649//                                  dest,"out_MEMORY_OUT_FRONT_END_ID" );
1650//             if (_param->_have_port_ooo_engine_id)
1651//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_OOO_ENGINE_ID",
1652//                                  dest,"out_MEMORY_OUT_OOO_ENGINE_ID");
1653//             if (_param->_have_port_rob_ptr  )
1654//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_PACKET_ID"    ,
1655//                                  dest,"out_MEMORY_OUT_PACKET_ID"    );
1656// //          PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_OPERATION"    ,
1657// //                               dest,"out_MEMORY_OUT_OPERATION"    );
1658// //          PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_TYPE"         ,
1659// //                               dest,"out_MEMORY_OUT_TYPE"         );
1660//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_WRITE_RD"     ,
1661//                                  dest,"out_MEMORY_OUT_WRITE_RD"     );
1662//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_NUM_REG_RD"   ,
1663//                                  dest,"out_MEMORY_OUT_NUM_REG_RD"   );
1664//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_DATA_RD"      ,
1665//                                  dest,"out_MEMORY_OUT_DATA_RD"      );
1666//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_WRITE_RE"     ,
1667//                                  dest,"out_MEMORY_OUT_WRITE_RE"     );
1668//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_NUM_REG_RE"   ,
1669//                                  dest,"out_MEMORY_OUT_NUM_REG_RE"   );
1670//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_DATA_RE"      ,
1671//                                  dest,"out_MEMORY_OUT_DATA_RE"      );
1672//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_EXCEPTION"    ,
1673//                                  dest,"out_MEMORY_OUT_EXCEPTION"    );
1674//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_NO_SEQUENCE"  ,
1675//                                  dest,"out_MEMORY_OUT_NO_SEQUENCE"  );
1676//             PORT_MAP(_component ,src , "in_EXECUTE_UNIT_OUT_"+toString(i)+"_ADDRESS"      ,
1677//                                  dest,"out_MEMORY_OUT_ADDRESS"      );
1678             }
1679         }
1680
1681       // ~~~~~[ Interface "write_unit_in" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1682       for (uint32_t i=0; i<_param->_nb_write_unit; i++)
1683         {
1684           dest = _name+"_write_unit_"+toString(i);
1685           
1686#ifdef POSITION
1687           _component->interface_map (src ,"write_unit_out_"+toString(i),
1688                                      dest,"write_out");
1689#endif
1690           
1691//         PORT_MAP(_component ,src ,"out_WRITE_UNIT_IN_"+toString(i)+"_VAL"          ,
1692//                              dest, "in_WRITE_UNIT_IN_VAL"          );
1693//         PORT_MAP(_component ,src , "in_WRITE_UNIT_IN_"+toString(i)+"_ACK"          ,
1694//                              dest,"out_WRITE_UNIT_IN_ACK"          );
1695//         if (_param->_have_port_context_id)
1696//         PORT_MAP(_component ,src ,"out_WRITE_UNIT_IN_"+toString(i)+"_CONTEXT_ID"   ,
1697//                              dest, "in_WRITE_UNIT_IN_CONTEXT_ID"   );
1698//         if (_param->_have_port_front_end_id)
1699//         PORT_MAP(_component ,src ,"out_WRITE_UNIT_IN_"+toString(i)+"_FRONT_END_ID" ,
1700//                              dest, "in_WRITE_UNIT_IN_FRONT_END_ID" );
1701//         if (_param->_have_port_ooo_engine_id)
1702//         PORT_MAP(_component ,src ,"out_WRITE_UNIT_IN_"+toString(i)+"_OOO_ENGINE_ID",
1703//                              dest, "in_WRITE_UNIT_IN_OOO_ENGINE_ID");
1704//         if (_param->_have_port_rob_ptr  )
1705//         PORT_MAP(_component ,src ,"out_WRITE_UNIT_IN_"+toString(i)+"_PACKET_ID"    ,
1706//                              dest, "in_WRITE_UNIT_IN_PACKET_ID"    );
1707// //      PORT_MAP(_component ,src ,"out_WRITE_UNIT_IN_"+toString(i)+"_OPERATION"    ,
1708// //                           dest, "in_WRITE_UNIT_IN_OPERATION"    );
1709// //      PORT_MAP(_component ,src ,"out_WRITE_UNIT_IN_"+toString(i)+"_TYPE"         ,
1710// //                           dest, "in_WRITE_UNIT_IN_TYPE"         );
1711//         PORT_MAP(_component ,src ,"out_WRITE_UNIT_IN_"+toString(i)+"_WRITE_RD"     ,
1712//                              dest, "in_WRITE_UNIT_IN_WRITE_RD"     );
1713//         PORT_MAP(_component ,src ,"out_WRITE_UNIT_IN_"+toString(i)+"_NUM_REG_RD"   ,
1714//                              dest, "in_WRITE_UNIT_IN_NUM_REG_RD"   );
1715//         PORT_MAP(_component ,src ,"out_WRITE_UNIT_IN_"+toString(i)+"_DATA_RD"      ,
1716//                              dest, "in_WRITE_UNIT_IN_DATA_RD"      );
1717//         PORT_MAP(_component ,src ,"out_WRITE_UNIT_IN_"+toString(i)+"_WRITE_RE"     ,
1718//                              dest, "in_WRITE_UNIT_IN_WRITE_RE"     );
1719//         PORT_MAP(_component ,src ,"out_WRITE_UNIT_IN_"+toString(i)+"_NUM_REG_RE"   ,
1720//                              dest, "in_WRITE_UNIT_IN_NUM_REG_RE"   );
1721//         PORT_MAP(_component ,src ,"out_WRITE_UNIT_IN_"+toString(i)+"_DATA_RE"      ,
1722//                              dest, "in_WRITE_UNIT_IN_DATA_RE"      );
1723//         PORT_MAP(_component ,src ,"out_WRITE_UNIT_IN_"+toString(i)+"_EXCEPTION"    ,
1724//                              dest, "in_WRITE_UNIT_IN_EXCEPTION"    );
1725//         PORT_MAP(_component ,src ,"out_WRITE_UNIT_IN_"+toString(i)+"_NO_SEQUENCE"  ,
1726//                              dest, "in_WRITE_UNIT_IN_NO_SEQUENCE"  );
1727//         PORT_MAP(_component ,src ,"out_WRITE_UNIT_IN_"+toString(i)+"_ADDRESS"      ,
1728//                              dest, "in_WRITE_UNIT_IN_ADDRESS"      );
1729         }
1730     }
1731     
1732#if DEBUG_Execute_loop == true
1733     _component->test_map();
1734#endif
1735
1736#ifdef POSITION
1737     if (usage_is_set(_usage,USE_POSITION))
1738       _component->generate_file();
1739#endif
1740
1741    log_printf(FUNC,Execute_loop,FUNCTION,"End");
1742  };
1743
1744}; // end namespace execute_loop
1745}; // end namespace multi_execute_loop
1746}; // end namespace core
1747
1748}; // end namespace behavioural
1749}; // end namespace morpheo             
Note: See TracBrowser for help on using the repository browser.