Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/Register_unit_Glue/src/Register_unit_Glue_allocation.cpp
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/Register_unit_Glue/src/Register_unit_Glue_allocation.cpp	(revision 106)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/Register_unit_Glue/src/Register_unit_Glue_allocation.cpp	(revision 112)
@@ -7,4 +7,5 @@
 
 #include "Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/Register_unit_Glue/include/Register_unit_Glue.h"
+#include "Behavioural/include/Allocation.h"
 
 namespace morpheo                    {
@@ -50,353 +51,157 @@
     out_CONST_1      = interface->set_signal_out <Tcontrol_t> ("const_1",1);
 
-    // ~~~~~[ Interface "gpr_read" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-   in_GPR_READ_VAL               = new SC_IN (Tcontrol_t        )   * [_param->_nb_gpr_read];
-  out_GPR_READ_ACK               = new SC_OUT(Tcontrol_t        )   * [_param->_nb_gpr_read];
-  if (_param->_have_port_ooo_engine_id == true)
-   in_GPR_READ_OOO_ENGINE_ID     = new SC_IN (Tcontext_t        )   * [_param->_nb_gpr_read];
-  out_GPR_READ_DATA              = new SC_OUT(Tgeneral_data_t   )   * [_param->_nb_gpr_read];
-  out_GPR_READ_DATA_VAL          = new SC_OUT(Tcontrol_t        )   * [_param->_nb_gpr_read];
-
-  out_GPR_READ_REGISTERFILE_VAL  = new SC_OUT(Tcontrol_t        )  ** [_param->_nb_ooo_engine];
-   in_GPR_READ_REGISTERFILE_ACK  = new SC_IN (Tcontrol_t        )  ** [_param->_nb_ooo_engine];
-   in_GPR_READ_REGISTERFILE_DATA = new SC_IN (Tgeneral_data_t   )  ** [_param->_nb_ooo_engine];
-
-  out_GPR_READ_STATUS_VAL        = new SC_OUT(Tcontrol_t        )  ** [_param->_nb_ooo_engine];
-   in_GPR_READ_STATUS_ACK        = new SC_IN (Tcontrol_t        )  ** [_param->_nb_ooo_engine];
-   in_GPR_READ_STATUS_DATA_VAL   = new SC_IN (Tcontrol_t        )  ** [_param->_nb_ooo_engine];
-
-   for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
-     {
-       out_GPR_READ_REGISTERFILE_VAL  [i] = new SC_OUT(Tcontrol_t        )  * [_param->_nb_gpr_read];
-        in_GPR_READ_REGISTERFILE_ACK  [i] = new SC_IN (Tcontrol_t        )  * [_param->_nb_gpr_read];
-        in_GPR_READ_REGISTERFILE_DATA [i] = new SC_IN (Tgeneral_data_t   )  * [_param->_nb_gpr_read];
-
-       out_GPR_READ_STATUS_VAL        [i] = new SC_OUT(Tcontrol_t        )  * [_param->_nb_gpr_read];
-        in_GPR_READ_STATUS_ACK        [i] = new SC_IN (Tcontrol_t        )  * [_param->_nb_gpr_read];
-        in_GPR_READ_STATUS_DATA_VAL   [i] = new SC_IN (Tcontrol_t        )  * [_param->_nb_gpr_read];
-     }
-
-   for (uint32_t j=0; j<_param->_nb_gpr_read; j++)
-     {
-       Interface_fifo * interface = _interfaces->set_interface("gpr_read_"+toString(j)
-#ifdef POSITION
-							  ,IN
-							  ,NORTH,
-							  "Interface to read generalist register"
-#endif
-							  );
-      
-        in_GPR_READ_VAL           [j] = interface->set_signal_valack_in  (VAL);
-       out_GPR_READ_ACK           [j] = interface->set_signal_valack_out (ACK);
-       if (_param->_have_port_ooo_engine_id == true)
-        in_GPR_READ_OOO_ENGINE_ID [j] = interface->set_signal_in <Tcontext_t     > ("ooo_engine_id", _param->_size_ooo_engine_id);
-       out_GPR_READ_DATA          [j] = interface->set_signal_out<Tgeneral_data_t> ("data"         , _param->_size_general_data);
-       out_GPR_READ_DATA_VAL      [j] = interface->set_signal_out<Tcontrol_t     > ("data_val"     , 1);
-
-       for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
-	 {
-	   {
-	     Interface_fifo * interface = _interfaces->set_interface("gpr_read_registerfile_"+toString(i)+"_"+toString(j)
-#ifdef POSITION
-								,IN
-								,NORTH,
-								"Interface to read generalist register - from/to register file"
-#endif
-								);
-	     
-	     out_GPR_READ_REGISTERFILE_VAL  [i][j] = interface->set_signal_valack_out (VAL);
-	      in_GPR_READ_REGISTERFILE_ACK  [i][j] = interface->set_signal_valack_in  (ACK);
-	      in_GPR_READ_REGISTERFILE_DATA [i][j] = interface->set_signal_in <Tgeneral_data_t> ("data"         , _param->_size_general_data);
-	   }
-	   {
-	     Interface_fifo * interface = _interfaces->set_interface("gpr_read_status_"+toString(i)+"_"+toString(j)
-#ifdef POSITION
-								,IN
-								,NORTH,
-								"Interface to read generalist register - from/to status"
-#endif
-								);
-
-
-	     out_GPR_READ_STATUS_VAL        [i][j] = interface->set_signal_valack_out (VAL);
-	      in_GPR_READ_STATUS_ACK        [i][j] = interface->set_signal_valack_in  (ACK);
-	      in_GPR_READ_STATUS_DATA_VAL   [i][j] = interface->set_signal_in <Tcontrol_t     > ("data_val"     , 1);
-	   }
-	 }
-     }
-
-    // ~~~~~[ Interface "spr_read" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-   in_SPR_READ_VAL               = new SC_IN (Tcontrol_t        )   * [_param->_nb_spr_read];
-  out_SPR_READ_ACK               = new SC_OUT(Tcontrol_t        )   * [_param->_nb_spr_read];
-  if (_param->_have_port_ooo_engine_id == true)
-   in_SPR_READ_OOO_ENGINE_ID     = new SC_IN (Tcontext_t        )   * [_param->_nb_spr_read];
-  out_SPR_READ_DATA              = new SC_OUT(Tspecial_data_t   )   * [_param->_nb_spr_read];
-  out_SPR_READ_DATA_VAL          = new SC_OUT(Tcontrol_t        )   * [_param->_nb_spr_read];
-
-  out_SPR_READ_REGISTERFILE_VAL  = new SC_OUT(Tcontrol_t        )  ** [_param->_nb_ooo_engine];
-   in_SPR_READ_REGISTERFILE_ACK  = new SC_IN (Tcontrol_t        )  ** [_param->_nb_ooo_engine];
-   in_SPR_READ_REGISTERFILE_DATA = new SC_IN (Tspecial_data_t   )  ** [_param->_nb_ooo_engine];
-
-  out_SPR_READ_STATUS_VAL        = new SC_OUT(Tcontrol_t        )  ** [_param->_nb_ooo_engine];
-   in_SPR_READ_STATUS_ACK        = new SC_IN (Tcontrol_t        )  ** [_param->_nb_ooo_engine];
-   in_SPR_READ_STATUS_DATA_VAL   = new SC_IN (Tcontrol_t        )  ** [_param->_nb_ooo_engine];
-
-   for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
-     {
-       out_SPR_READ_REGISTERFILE_VAL  [i] = new SC_OUT(Tcontrol_t        )  * [_param->_nb_spr_read];
-        in_SPR_READ_REGISTERFILE_ACK  [i] = new SC_IN (Tcontrol_t        )  * [_param->_nb_spr_read];
-        in_SPR_READ_REGISTERFILE_DATA [i] = new SC_IN (Tspecial_data_t   )  * [_param->_nb_spr_read];
-
-       out_SPR_READ_STATUS_VAL        [i] = new SC_OUT(Tcontrol_t        )  * [_param->_nb_spr_read];
-        in_SPR_READ_STATUS_ACK        [i] = new SC_IN (Tcontrol_t        )  * [_param->_nb_spr_read];
-        in_SPR_READ_STATUS_DATA_VAL   [i] = new SC_IN (Tcontrol_t        )  * [_param->_nb_spr_read];
-     }
-
-   for (uint32_t j=0; j<_param->_nb_spr_read; j++)
-     {
-       Interface_fifo * interface = _interfaces->set_interface("spr_read_"+toString(j)
-#ifdef POSITION
-							  ,IN
-							  ,NORTH,
-							  "Interface to read special register"
-#endif
-							  );
-      
-        in_SPR_READ_VAL           [j] = interface->set_signal_valack_in  (VAL);
-       out_SPR_READ_ACK           [j] = interface->set_signal_valack_out (ACK);
-       if (_param->_have_port_ooo_engine_id == true)
-        in_SPR_READ_OOO_ENGINE_ID [j] = interface->set_signal_in <Tcontext_t     > ("ooo_engine_id", _param->_size_ooo_engine_id);
-       out_SPR_READ_DATA          [j] = interface->set_signal_out<Tspecial_data_t> ("data"         , _param->_size_special_data);
-       out_SPR_READ_DATA_VAL      [j] = interface->set_signal_out<Tcontrol_t     > ("data_val"     , 1);
-
-       for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
-	 {
-	   {
-	     Interface_fifo * interface = _interfaces->set_interface("spr_read_registerfile_"+toString(i)+"_"+toString(j)
-#ifdef POSITION
-								,IN
-								,NORTH,
-								"Interface to read special register - from/to register file"
-#endif
-								);
-	     
-	     out_SPR_READ_REGISTERFILE_VAL  [i][j] = interface->set_signal_valack_out (VAL);
-	      in_SPR_READ_REGISTERFILE_ACK  [i][j] = interface->set_signal_valack_in  (ACK);
-	      in_SPR_READ_REGISTERFILE_DATA [i][j] = interface->set_signal_in <Tspecial_data_t> ("data"         , _param->_size_special_data);
-	   }
-	   {
-	     Interface_fifo * interface = _interfaces->set_interface("spr_read_status_"+toString(i)+"_"+toString(j)
-#ifdef POSITION
-								,IN
-								,NORTH,
-								"Interface to read special register - from/to status"
-#endif
-								);
-
-
-	     out_SPR_READ_STATUS_VAL        [i][j] = interface->set_signal_valack_out (VAL);
-	      in_SPR_READ_STATUS_ACK        [i][j] = interface->set_signal_valack_in  (ACK);
-	      in_SPR_READ_STATUS_DATA_VAL   [i][j] = interface->set_signal_in <Tcontrol_t     > ("data_val"     , 1);
-	   }
-	 }
-     }
-
-    // ~~~~~[ Interface "gpr_write" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-   in_GPR_WRITE_VAL               = new SC_IN (Tcontrol_t        )   * [_param->_nb_gpr_write];
-  out_GPR_WRITE_ACK               = new SC_OUT(Tcontrol_t        )   * [_param->_nb_gpr_write];
-  if (_param->_have_port_ooo_engine_id == true) 
-  in_GPR_WRITE_OOO_ENGINE_ID     = new SC_IN (Tcontext_t        )   * [_param->_nb_gpr_write];
-
-  out_GPR_WRITE_REGISTERFILE_VAL  = new SC_OUT(Tcontrol_t        )  ** [_param->_nb_ooo_engine];
-   in_GPR_WRITE_REGISTERFILE_ACK  = new SC_IN (Tcontrol_t        )  ** [_param->_nb_ooo_engine];
-
-  out_GPR_WRITE_STATUS_VAL        = new SC_OUT(Tcontrol_t        )  ** [_param->_nb_ooo_engine];
-   in_GPR_WRITE_STATUS_ACK        = new SC_IN (Tcontrol_t        )  ** [_param->_nb_ooo_engine];
-
-   for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
-     {
-       out_GPR_WRITE_REGISTERFILE_VAL  [i] = new SC_OUT(Tcontrol_t        )  * [_param->_nb_gpr_write];
-        in_GPR_WRITE_REGISTERFILE_ACK  [i] = new SC_IN (Tcontrol_t        )  * [_param->_nb_gpr_write];
-
-       out_GPR_WRITE_STATUS_VAL        [i] = new SC_OUT(Tcontrol_t        )  * [_param->_nb_gpr_write];
-        in_GPR_WRITE_STATUS_ACK        [i] = new SC_IN (Tcontrol_t        )  * [_param->_nb_gpr_write];
-     }
-
-   for (uint32_t j=0; j<_param->_nb_gpr_write; j++)
-     {
-       Interface_fifo * interface = _interfaces->set_interface("gpr_write_"+toString(j)
-#ifdef POSITION
-							  ,IN
-							  ,NORTH,
-							  "Interface to write generalist register"
-#endif
-							  );
-      
-        in_GPR_WRITE_VAL           [j] = interface->set_signal_valack_in  (VAL);
-       out_GPR_WRITE_ACK           [j] = interface->set_signal_valack_out (ACK);
-       if (_param->_have_port_ooo_engine_id == true)
-        in_GPR_WRITE_OOO_ENGINE_ID [j] = interface->set_signal_in <Tcontext_t     > ("ooo_engine_id", _param->_size_ooo_engine_id);
-
-       for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
-	 {
-	   {
-	     Interface_fifo * interface = _interfaces->set_interface("gpr_write_registerfile_"+toString(i)+"_"+toString(j)
-#ifdef POSITION
-								,IN
-								,NORTH,
-								"Interface to write generalist register - from/to register file"
-#endif
-								);
-	     
-	     out_GPR_WRITE_REGISTERFILE_VAL  [i][j] = interface->set_signal_valack_out (VAL);
-	      in_GPR_WRITE_REGISTERFILE_ACK  [i][j] = interface->set_signal_valack_in  (ACK);
-	   }
-	   {
-	     Interface_fifo * interface = _interfaces->set_interface("gpr_write_status_"+toString(i)+"_"+toString(j)
-#ifdef POSITION
-								,IN
-								,NORTH,
-								"Interface to write generalist register - from/to status"
-#endif
-								);
-
-
-	     out_GPR_WRITE_STATUS_VAL        [i][j] = interface->set_signal_valack_out (VAL);
-	      in_GPR_WRITE_STATUS_ACK        [i][j] = interface->set_signal_valack_in  (ACK);
-	   }
-	 }
-     }
-
-    // ~~~~~[ Interface "spr_write" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-   in_SPR_WRITE_VAL               = new SC_IN (Tcontrol_t        )   * [_param->_nb_spr_write];
-  out_SPR_WRITE_ACK               = new SC_OUT(Tcontrol_t        )   * [_param->_nb_spr_write];
-  if (_param->_have_port_ooo_engine_id == true) 
-   in_SPR_WRITE_OOO_ENGINE_ID     = new SC_IN (Tcontext_t        )   * [_param->_nb_spr_write];
-
-  out_SPR_WRITE_REGISTERFILE_VAL  = new SC_OUT(Tcontrol_t        )  ** [_param->_nb_ooo_engine];
-   in_SPR_WRITE_REGISTERFILE_ACK  = new SC_IN (Tcontrol_t        )  ** [_param->_nb_ooo_engine];
-
-  out_SPR_WRITE_STATUS_VAL        = new SC_OUT(Tcontrol_t        )  ** [_param->_nb_ooo_engine];
-   in_SPR_WRITE_STATUS_ACK        = new SC_IN (Tcontrol_t        )  ** [_param->_nb_ooo_engine];
-
-   for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
-     {
-       out_SPR_WRITE_REGISTERFILE_VAL  [i] = new SC_OUT(Tcontrol_t        )  * [_param->_nb_spr_write];
-        in_SPR_WRITE_REGISTERFILE_ACK  [i] = new SC_IN (Tcontrol_t        )  * [_param->_nb_spr_write];
-
-       out_SPR_WRITE_STATUS_VAL        [i] = new SC_OUT(Tcontrol_t        )  * [_param->_nb_spr_write];
-        in_SPR_WRITE_STATUS_ACK        [i] = new SC_IN (Tcontrol_t        )  * [_param->_nb_spr_write];
-     }
-
-   for (uint32_t j=0; j<_param->_nb_spr_write; j++)
-     {
-       Interface_fifo * interface = _interfaces->set_interface("spr_write_"+toString(j)
-#ifdef POSITION
-							  ,IN
-							  ,NORTH,
-							  "Interface to write special register"
-#endif
-							  );
-      
-        in_SPR_WRITE_VAL           [j] = interface->set_signal_valack_in  (VAL);
-       out_SPR_WRITE_ACK           [j] = interface->set_signal_valack_out (ACK);
-       if (_param->_have_port_ooo_engine_id == true)
-        in_SPR_WRITE_OOO_ENGINE_ID [j] = interface->set_signal_in <Tcontext_t     > ("ooo_engine_id", _param->_size_ooo_engine_id);
-
-       for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
-	 {
-	   {
-	     Interface_fifo * interface = _interfaces->set_interface("spr_write_registerfile_"+toString(i)+"_"+toString(j)
-#ifdef POSITION
-								,IN
-								,NORTH,
-								"Interface to write special register - from/to register file"
-#endif
-								);
-	     
-	     out_SPR_WRITE_REGISTERFILE_VAL  [i][j] = interface->set_signal_valack_out (VAL);
-	      in_SPR_WRITE_REGISTERFILE_ACK  [i][j] = interface->set_signal_valack_in  (ACK);
-	   }
-	   {
-	     Interface_fifo * interface = _interfaces->set_interface("spr_write_status_"+toString(i)+"_"+toString(j)
-#ifdef POSITION
-								,IN
-								,NORTH,
-								"Interface to write special register - from/to status"
-#endif
-								);
-
-
-	     out_SPR_WRITE_STATUS_VAL        [i][j] = interface->set_signal_valack_out (VAL);
-	      in_SPR_WRITE_STATUS_ACK        [i][j] = interface->set_signal_valack_in  (ACK);
-	   }
-	 }
-     }
-
-   // ~~~~~[ Interface "insert_rob" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-    in_INSERT_ROB_VAL                  = new SC_IN (Tcontrol_t) ** [_param->_nb_ooo_engine];
-   out_INSERT_ROB_ACK                  = new SC_OUT(Tcontrol_t) ** [_param->_nb_ooo_engine];
-    in_INSERT_ROB_RD_USE               = new SC_IN (Tcontrol_t) ** [_param->_nb_ooo_engine];
-    in_INSERT_ROB_RE_USE               = new SC_IN (Tcontrol_t) ** [_param->_nb_ooo_engine];
-   out_INSERT_ROB_GPR_STATUS_VAL       = new SC_OUT(Tcontrol_t) ** [_param->_nb_ooo_engine];
-    in_INSERT_ROB_GPR_STATUS_ACK       = new SC_IN (Tcontrol_t) ** [_param->_nb_ooo_engine];
-   out_INSERT_ROB_SPR_STATUS_VAL       = new SC_OUT(Tcontrol_t) ** [_param->_nb_ooo_engine];
-    in_INSERT_ROB_SPR_STATUS_ACK       = new SC_IN (Tcontrol_t) ** [_param->_nb_ooo_engine];
-
-    for (uint32_t i=0; i<_param->_nb_ooo_engine; i++)
-      {
-	uint32_t x=_param->_nb_inst_insert_rob [i];
-
-	in_INSERT_ROB_VAL                  [i] = new SC_IN (Tcontrol_t) * [x];
-       out_INSERT_ROB_ACK                  [i] = new SC_OUT(Tcontrol_t) * [x];
-	in_INSERT_ROB_RD_USE               [i] = new SC_IN (Tcontrol_t) * [x];
-	in_INSERT_ROB_RE_USE               [i] = new SC_IN (Tcontrol_t) * [x];
-       out_INSERT_ROB_GPR_STATUS_VAL       [i] = new SC_OUT(Tcontrol_t) * [x];
-	in_INSERT_ROB_GPR_STATUS_ACK       [i] = new SC_IN (Tcontrol_t) * [x];
-       out_INSERT_ROB_SPR_STATUS_VAL       [i] = new SC_OUT(Tcontrol_t) * [x];
-	in_INSERT_ROB_SPR_STATUS_ACK       [i] = new SC_IN (Tcontrol_t) * [x];
-
-	for (uint32_t j=0; j<x; j++)
-	  {
-	    {
-	      Interface_fifo * interface = _interfaces->set_interface("insert_rob_"+toString(i)+"_"+toString(j)
-#ifdef POSITION
-								      ,IN
-								      ,WEST
-								      ,"Interface to update status (insert)"
-#endif
-								      );
-
-	       in_INSERT_ROB_VAL                  [i][j] = interface->set_signal_valack_in (VAL);
-	      out_INSERT_ROB_ACK                  [i][j] = interface->set_signal_valack_out(ACK);
-	       in_INSERT_ROB_RD_USE               [i][j] = interface->set_signal_in <Tcontrol_t> ("rd_use", 1);
-	       in_INSERT_ROB_RE_USE               [i][j] = interface->set_signal_in <Tcontrol_t> ("re_use", 1);
-	    }
-	    {
-	      Interface_fifo * interface = _interfaces->set_interface("insert_rob_gpr_status_"+toString(i)+"_"+toString(j)
-#ifdef POSITION
-								      ,IN
-								      ,EAST
-								      ,"Interface to update status (insert)"
-#endif
-								      );
-
-	      out_INSERT_ROB_GPR_STATUS_VAL       [i][j] = interface->set_signal_valack_out(VAL);
-	       in_INSERT_ROB_GPR_STATUS_ACK       [i][j] = interface->set_signal_valack_in (ACK);
-	    }
-	    {
-	      Interface_fifo * interface = _interfaces->set_interface("insert_rob_spr_status_"+toString(i)+"_"+toString(j)
-#ifdef POSITION
-								      ,IN
-								      ,EAST
-								      ,"Interface to update status (insert)"
-#endif
-								      );
-
-	      out_INSERT_ROB_SPR_STATUS_VAL       [i][j] = interface->set_signal_valack_out(VAL);
-	       in_INSERT_ROB_SPR_STATUS_ACK       [i][j] = interface->set_signal_valack_in (ACK);
-	    }
-	  }
-      }
+    // ~~~~~[ Interface "gpr_read" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+    {
+      ALLOC1_INTERFACE_BEGIN("gpr_read",IN,NORTH,_("Interface to read generalist register"),_param->_nb_gpr_read);
+
+      ALLOC1_VALACK_IN ( in_GPR_READ_VAL           ,VAL);
+      ALLOC1_VALACK_OUT(out_GPR_READ_ACK           ,ACK);
+      ALLOC1_SIGNAL_IN ( in_GPR_READ_OOO_ENGINE_ID ,"ooo_engine_id",Tcontext_t     , _param->_size_ooo_engine_id);
+      ALLOC1_SIGNAL_OUT(out_GPR_READ_DATA          ,"data"         ,Tgeneral_data_t, _param->_size_general_data);
+      ALLOC1_SIGNAL_OUT(out_GPR_READ_DATA_VAL      ,"data_val"     ,Tcontrol_t     , 1);
+
+      ALLOC1_INTERFACE_END(_param->_nb_gpr_read);
+    }
+
+    {
+      ALLOC2_INTERFACE_BEGIN("gpr_read_registerfile",IN,NORTH,_("Interface to read generalist register - from/to register file"),_param->_nb_ooo_engine,_param->_nb_gpr_read);
+      
+      ALLOC2_VALACK_OUT(out_GPR_READ_REGISTERFILE_VAL ,VAL);
+      ALLOC2_VALACK_IN ( in_GPR_READ_REGISTERFILE_ACK ,ACK);
+      ALLOC2_SIGNAL_IN ( in_GPR_READ_REGISTERFILE_DATA,"data",Tgeneral_data_t,_param->_size_general_data);
+      
+      ALLOC2_INTERFACE_END(_param->_nb_ooo_engine,_param->_nb_gpr_read);
+    }
+    
+    {
+      ALLOC2_INTERFACE_BEGIN("gpr_read_status",IN,NORTH,_("Interface to read generalist register - from/to register file"),_param->_nb_ooo_engine,_param->_nb_gpr_read);
+      
+      ALLOC2_VALACK_OUT(out_GPR_READ_STATUS_VAL      ,VAL);
+      ALLOC2_VALACK_IN ( in_GPR_READ_STATUS_ACK      ,ACK);
+      ALLOC2_SIGNAL_IN ( in_GPR_READ_STATUS_DATA_VAL,"data_val",Tcontrol_t,1);
+
+      ALLOC2_INTERFACE_END(_param->_nb_ooo_engine,_param->_nb_gpr_read);
+    }
+
+    // ~~~~~[ Interface "spr_read" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+    {
+      ALLOC1_INTERFACE_BEGIN("spr_read",IN,NORTH,_("Interface to read generalist register"),_param->_nb_spr_read);
+
+      ALLOC1_VALACK_IN ( in_SPR_READ_VAL           ,VAL);
+      ALLOC1_VALACK_OUT(out_SPR_READ_ACK           ,ACK);
+      ALLOC1_SIGNAL_IN ( in_SPR_READ_OOO_ENGINE_ID ,"ooo_engine_id",Tcontext_t     , _param->_size_ooo_engine_id);
+      ALLOC1_SIGNAL_OUT(out_SPR_READ_DATA          ,"data"         ,Tspecial_data_t, _param->_size_special_data);
+      ALLOC1_SIGNAL_OUT(out_SPR_READ_DATA_VAL      ,"data_val"     ,Tcontrol_t     , 1);
+
+      ALLOC1_INTERFACE_END(_param->_nb_spr_read);
+    }
+    
+    {
+      ALLOC2_INTERFACE_BEGIN("spr_read_registerfile",IN,NORTH,_("Interface to read generalist register - from/to register file"),_param->_nb_ooo_engine,_param->_nb_spr_read);
+      
+      ALLOC2_VALACK_OUT(out_SPR_READ_REGISTERFILE_VAL ,VAL);
+      ALLOC2_VALACK_IN ( in_SPR_READ_REGISTERFILE_ACK ,ACK);
+      ALLOC2_SIGNAL_IN ( in_SPR_READ_REGISTERFILE_DATA,"data",Tspecial_data_t,_param->_size_special_data);
+      
+      ALLOC2_INTERFACE_END(_param->_nb_ooo_engine,_param->_nb_spr_read);
+    }
+    
+    {
+      ALLOC2_INTERFACE_BEGIN("spr_read_status",IN,NORTH,_("Interface to read generalist register - from/to status"),_param->_nb_ooo_engine,_param->_nb_spr_read);
+      
+      ALLOC2_VALACK_OUT(out_SPR_READ_STATUS_VAL      ,VAL);
+      ALLOC2_VALACK_IN ( in_SPR_READ_STATUS_ACK      ,ACK);
+      ALLOC2_SIGNAL_IN ( in_SPR_READ_STATUS_DATA_VAL,"data_val",Tcontrol_t,1);
+      
+      ALLOC2_INTERFACE_END(_param->_nb_ooo_engine,_param->_nb_spr_read);
+    }
+
+    // ~~~~~[ Interface "gpr_write" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+    {
+      ALLOC1_INTERFACE_BEGIN("gpr_write",IN,NORTH,_("Interface to write generalist register"),_param->_nb_gpr_write);
+      
+      ALLOC1_VALACK_IN ( in_GPR_WRITE_VAL          ,VAL);
+      ALLOC1_VALACK_OUT(out_GPR_WRITE_ACK          ,ACK);
+      ALLOC1_SIGNAL_IN ( in_GPR_WRITE_OOO_ENGINE_ID,"ooo_engine_id",Tcontext_t, _param->_size_ooo_engine_id);
+
+      ALLOC1_INTERFACE_END(_param->_nb_gpr_write);
+    }
+    
+    {
+      ALLOC2_INTERFACE_BEGIN("gpr_write_registerfile",IN,NORTH,_("Interface to write generalist register - from/to registerfile"),_param->_nb_ooo_engine,_param->_nb_gpr_write);
+      
+      ALLOC2_VALACK_OUT(out_GPR_WRITE_REGISTERFILE_VAL,VAL);
+      ALLOC2_VALACK_IN ( in_GPR_WRITE_REGISTERFILE_ACK,ACK);
+
+      ALLOC2_INTERFACE_END(_param->_nb_ooo_engine,_param->_nb_gpr_write);
+    }
+    
+    {
+      ALLOC2_INTERFACE_BEGIN("gpr_write_status",IN,NORTH,_("Interface to write generalist register - from/to status"),_param->_nb_ooo_engine,_param->_nb_gpr_write);
+      
+      ALLOC2_VALACK_OUT(out_GPR_WRITE_STATUS_VAL,VAL);
+      ALLOC2_VALACK_IN ( in_GPR_WRITE_STATUS_ACK,ACK);
+
+      ALLOC2_INTERFACE_END(_param->_nb_ooo_engine,_param->_nb_gpr_write);
+    }
+
+    // ~~~~~[ Interface "spr_write" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+    {
+      ALLOC1_INTERFACE_BEGIN("spr_write",IN,NORTH,_("Interface to write generalist register"),_param->_nb_spr_write);
+      
+      ALLOC1_VALACK_IN ( in_SPR_WRITE_VAL          ,VAL);
+      ALLOC1_VALACK_OUT(out_SPR_WRITE_ACK          ,ACK);
+      ALLOC1_SIGNAL_IN ( in_SPR_WRITE_OOO_ENGINE_ID,"ooo_engine_id",Tcontext_t, _param->_size_ooo_engine_id);
+
+      ALLOC1_INTERFACE_END(_param->_nb_spr_write);
+    }
+    
+    {
+      ALLOC2_INTERFACE_BEGIN("spr_write_registerfile",IN,NORTH,_("Interface to write generalist register - from/to registerfile"),_param->_nb_ooo_engine,_param->_nb_spr_write);
+      
+      ALLOC2_VALACK_OUT(out_SPR_WRITE_REGISTERFILE_VAL,VAL);
+      ALLOC2_VALACK_IN ( in_SPR_WRITE_REGISTERFILE_ACK,ACK);
+
+      ALLOC2_INTERFACE_END(_param->_nb_ooo_engine,_param->_nb_spr_write);
+    }
+    
+    {
+      ALLOC2_INTERFACE_BEGIN("spr_write_status",IN,NORTH,_("Interface to write generalist register - from/to status"),_param->_nb_ooo_engine,_param->_nb_spr_write);
+      
+      ALLOC2_VALACK_OUT(out_SPR_WRITE_STATUS_VAL,VAL);
+      ALLOC2_VALACK_IN ( in_SPR_WRITE_STATUS_ACK,ACK);
+
+      ALLOC2_INTERFACE_END(_param->_nb_ooo_engine,_param->_nb_spr_write);
+    }
+
+    // ~~~~~[ Interface "insert_rob" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+    {
+      ALLOC2_INTERFACE_BEGIN("insert_rob",IN,WEST,_("Interface to update status (insert)"),_param->_nb_ooo_engine,_param->_nb_inst_insert_rob [it1]);
+      
+      _ALLOC2_VALACK_IN ( in_INSERT_ROB_VAL   ,VAL                   ,_param->_nb_ooo_engine,_param->_nb_inst_insert_rob [it1]);
+      _ALLOC2_VALACK_OUT(out_INSERT_ROB_ACK   ,ACK                   ,_param->_nb_ooo_engine,_param->_nb_inst_insert_rob [it1]);
+      _ALLOC2_SIGNAL_IN ( in_INSERT_ROB_RD_USE,"rd_use",Tcontrol_t, 1,_param->_nb_ooo_engine,_param->_nb_inst_insert_rob [it1]);
+      _ALLOC2_SIGNAL_IN ( in_INSERT_ROB_RE_USE,"re_use",Tcontrol_t, 1,_param->_nb_ooo_engine,_param->_nb_inst_insert_rob [it1]);
+
+      ALLOC2_INTERFACE_END(_param->_nb_ooo_engine,_param->_nb_inst_insert_rob [it1]);
+    }
+    
+    {
+      ALLOC2_INTERFACE_BEGIN("insert_rob_gpr_status",IN,WEST,_("Interface to update status (insert)"),_param->_nb_ooo_engine,_param->_nb_inst_insert_rob [it1]);
+      
+      _ALLOC2_VALACK_OUT(out_INSERT_ROB_GPR_STATUS_VAL,VAL,_param->_nb_ooo_engine,_param->_nb_inst_insert_rob [it1]);
+      _ALLOC2_VALACK_IN ( in_INSERT_ROB_GPR_STATUS_ACK,ACK,_param->_nb_ooo_engine,_param->_nb_inst_insert_rob [it1]);
+
+      ALLOC2_INTERFACE_END(_param->_nb_ooo_engine,_param->_nb_inst_insert_rob [it1]);
+    }
+    
+    {
+      ALLOC2_INTERFACE_BEGIN("insert_rob_spr_status",IN,WEST,_("Interface to update status (insert)"),_param->_nb_ooo_engine,_param->_nb_inst_insert_rob [it1]);
+      
+      _ALLOC2_VALACK_OUT(out_INSERT_ROB_SPR_STATUS_VAL,VAL,_param->_nb_ooo_engine,_param->_nb_inst_insert_rob [it1]);
+      _ALLOC2_VALACK_IN ( in_INSERT_ROB_SPR_STATUS_ACK,ACK,_param->_nb_ooo_engine,_param->_nb_inst_insert_rob [it1]);
+
+      ALLOC2_INTERFACE_END(_param->_nb_ooo_engine,_param->_nb_inst_insert_rob [it1]);
+    }
 
 //     // ~~~~~[ Interface "retire_rob" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/Register_unit_Glue/src/Register_unit_Glue_deallocation.cpp
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/Register_unit_Glue/src/Register_unit_Glue_deallocation.cpp	(revision 106)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/Register_unit_Glue/src/Register_unit_Glue_deallocation.cpp	(revision 112)
@@ -7,4 +7,5 @@
 
 #include "Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/Register_unit_Glue/include/Register_unit_Glue.h"
+#include "Behavioural/include/Allocation.h"
 
 namespace morpheo                    {
@@ -26,90 +27,69 @@
       {
 //#if defined(STATISTICS) or defined(VHDL_TESTBENCH)
-    delete    in_CLOCK ;
+    delete  in_CLOCK ;
 //#endif
-    delete    in_NRESET;
+    delete  in_NRESET;
+    delete out_CONST_0;
+    delete out_CONST_1;
 
-    // ~~~~~[ Interface "gpr_read" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-    delete []  in_GPR_READ_VAL               ;
-    delete [] out_GPR_READ_ACK               ;
-    if (_param->_have_port_ooo_engine_id == true)
-    delete []  in_GPR_READ_OOO_ENGINE_ID     ;
-    delete [] out_GPR_READ_DATA              ;
-    delete [] out_GPR_READ_DATA_VAL          ;
+    DELETE1_SIGNAL( in_GPR_READ_VAL           ,_param->_nb_gpr_read,1  );
+    DELETE1_SIGNAL(out_GPR_READ_ACK           ,_param->_nb_gpr_read,1  );
+    DELETE1_SIGNAL( in_GPR_READ_OOO_ENGINE_ID ,_param->_nb_gpr_read,_param->_size_ooo_engine_id);
+    DELETE1_SIGNAL(out_GPR_READ_DATA          ,_param->_nb_gpr_read,_param->_size_general_data);
+    DELETE1_SIGNAL(out_GPR_READ_DATA_VAL      ,_param->_nb_gpr_read,1);
+    
+    DELETE2_SIGNAL(out_GPR_READ_REGISTERFILE_VAL ,_param->_nb_ooo_engine,_param->_nb_gpr_read,1  );
+    DELETE2_SIGNAL( in_GPR_READ_REGISTERFILE_ACK ,_param->_nb_ooo_engine,_param->_nb_gpr_read,1  );
+    DELETE2_SIGNAL( in_GPR_READ_REGISTERFILE_DATA,_param->_nb_ooo_engine,_param->_nb_gpr_read,_param->_size_general_data);
 
-    delete [] out_GPR_READ_REGISTERFILE_VAL  ;
-    delete []  in_GPR_READ_REGISTERFILE_ACK  ;
-    delete []  in_GPR_READ_REGISTERFILE_DATA ;
+    DELETE2_SIGNAL(out_GPR_READ_STATUS_VAL     ,_param->_nb_ooo_engine,_param->_nb_gpr_read,1  );
+    DELETE2_SIGNAL( in_GPR_READ_STATUS_ACK     ,_param->_nb_ooo_engine,_param->_nb_gpr_read,1  );
+    DELETE2_SIGNAL( in_GPR_READ_STATUS_DATA_VAL,_param->_nb_ooo_engine,_param->_nb_gpr_read,1);
 
-    delete [] out_GPR_READ_STATUS_VAL        ;
-    delete []  in_GPR_READ_STATUS_ACK        ;
-    delete []  in_GPR_READ_STATUS_DATA_VAL   ;
+    DELETE1_SIGNAL( in_SPR_READ_VAL           ,_param->_nb_spr_read,1  );
+    DELETE1_SIGNAL(out_SPR_READ_ACK           ,_param->_nb_spr_read,1  );
+    DELETE1_SIGNAL( in_SPR_READ_OOO_ENGINE_ID ,_param->_nb_spr_read,_param->_size_ooo_engine_id);
+    DELETE1_SIGNAL(out_SPR_READ_DATA          ,_param->_nb_spr_read,_param->_size_special_data);
+    DELETE1_SIGNAL(out_SPR_READ_DATA_VAL      ,_param->_nb_spr_read,1);
+    
+    DELETE2_SIGNAL(out_SPR_READ_REGISTERFILE_VAL ,_param->_nb_ooo_engine,_param->_nb_spr_read,1  );
+    DELETE2_SIGNAL( in_SPR_READ_REGISTERFILE_ACK ,_param->_nb_ooo_engine,_param->_nb_spr_read,1  );
+    DELETE2_SIGNAL( in_SPR_READ_REGISTERFILE_DATA,_param->_nb_ooo_engine,_param->_nb_spr_read,_param->_size_special_data);
+    
+    DELETE2_SIGNAL(out_SPR_READ_STATUS_VAL     ,_param->_nb_ooo_engine,_param->_nb_spr_read,1  );
+    DELETE2_SIGNAL( in_SPR_READ_STATUS_ACK     ,_param->_nb_ooo_engine,_param->_nb_spr_read,1  );
+    DELETE2_SIGNAL( in_SPR_READ_STATUS_DATA_VAL,_param->_nb_ooo_engine,_param->_nb_spr_read,1);
+    
+    DELETE1_SIGNAL( in_GPR_WRITE_VAL          ,_param->_nb_gpr_write,1  );
+    DELETE1_SIGNAL(out_GPR_WRITE_ACK          ,_param->_nb_gpr_write,1  );
+    DELETE1_SIGNAL( in_GPR_WRITE_OOO_ENGINE_ID,_param->_nb_gpr_write,_param->_size_ooo_engine_id);
 
+    
+    DELETE2_SIGNAL(out_GPR_WRITE_REGISTERFILE_VAL,_param->_nb_ooo_engine,_param->_nb_gpr_write,1  );
+    DELETE2_SIGNAL( in_GPR_WRITE_REGISTERFILE_ACK,_param->_nb_ooo_engine,_param->_nb_gpr_write,1  );
 
-    // ~~~~~[ Interface "spr_read" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-    delete []  in_SPR_READ_VAL               ;
-    delete [] out_SPR_READ_ACK               ;
-    if (_param->_have_port_ooo_engine_id == true)
-    delete []  in_SPR_READ_OOO_ENGINE_ID     ;
-    delete [] out_SPR_READ_DATA              ;
-    delete [] out_SPR_READ_DATA_VAL          ;
+    DELETE2_SIGNAL(out_GPR_WRITE_STATUS_VAL,_param->_nb_ooo_engine,_param->_nb_gpr_write,1  );
+    DELETE2_SIGNAL( in_GPR_WRITE_STATUS_ACK,_param->_nb_ooo_engine,_param->_nb_gpr_write,1  );
 
-    delete [] out_SPR_READ_REGISTERFILE_VAL  ;
-    delete []  in_SPR_READ_REGISTERFILE_ACK  ;
-    delete []  in_SPR_READ_REGISTERFILE_DATA ;
+    DELETE1_SIGNAL( in_SPR_WRITE_VAL          ,_param->_nb_spr_write,1  );
+    DELETE1_SIGNAL(out_SPR_WRITE_ACK          ,_param->_nb_spr_write,1  );
+    DELETE1_SIGNAL( in_SPR_WRITE_OOO_ENGINE_ID,_param->_nb_spr_write,_param->_size_ooo_engine_id);
 
-    delete [] out_SPR_READ_STATUS_VAL        ;
-    delete []  in_SPR_READ_STATUS_ACK        ;
-    delete []  in_SPR_READ_STATUS_DATA_VAL   ;
+    DELETE2_SIGNAL(out_SPR_WRITE_REGISTERFILE_VAL,_param->_nb_ooo_engine,_param->_nb_spr_write,1  );
+    DELETE2_SIGNAL( in_SPR_WRITE_REGISTERFILE_ACK,_param->_nb_ooo_engine,_param->_nb_spr_write,1  );
 
-    // ~~~~~[ Interface "gpr_write" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-    delete []  in_GPR_WRITE_VAL               ;
-    delete [] out_GPR_WRITE_ACK               ;
-    if (_param->_have_port_ooo_engine_id == true)
-    delete []  in_GPR_WRITE_OOO_ENGINE_ID     ;
+    DELETE2_SIGNAL(out_SPR_WRITE_STATUS_VAL,_param->_nb_ooo_engine,_param->_nb_spr_write,1  );
+    DELETE2_SIGNAL( in_SPR_WRITE_STATUS_ACK,_param->_nb_ooo_engine,_param->_nb_spr_write,1  );
 
-    delete [] out_GPR_WRITE_REGISTERFILE_VAL  ;
-    delete []  in_GPR_WRITE_REGISTERFILE_ACK  ;
+    DELETE2_SIGNAL( in_INSERT_ROB_VAL   ,_param->_nb_ooo_engine,_param->_nb_inst_insert_rob [it1],1);
+    DELETE2_SIGNAL(out_INSERT_ROB_ACK   ,_param->_nb_ooo_engine,_param->_nb_inst_insert_rob [it1],1);
+    DELETE2_SIGNAL( in_INSERT_ROB_RD_USE,_param->_nb_ooo_engine,_param->_nb_inst_insert_rob [it1],1);
+    DELETE2_SIGNAL( in_INSERT_ROB_RE_USE,_param->_nb_ooo_engine,_param->_nb_inst_insert_rob [it1],1);
 
-    delete [] out_GPR_WRITE_STATUS_VAL        ;
-    delete []  in_GPR_WRITE_STATUS_ACK        ;
+    DELETE2_SIGNAL(out_INSERT_ROB_GPR_STATUS_VAL,_param->_nb_ooo_engine,_param->_nb_inst_insert_rob [it1],1);
+    DELETE2_SIGNAL( in_INSERT_ROB_GPR_STATUS_ACK,_param->_nb_ooo_engine,_param->_nb_inst_insert_rob [it1],1);
 
-    // ~~~~~[ Interface "spr_write" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-    delete []  in_SPR_WRITE_VAL               ;
-    delete [] out_SPR_WRITE_ACK               ;
-    if (_param->_have_port_ooo_engine_id == true)
-    delete []  in_SPR_WRITE_OOO_ENGINE_ID     ;
-
-    delete [] out_SPR_WRITE_REGISTERFILE_VAL  ;
-    delete []  in_SPR_WRITE_REGISTERFILE_ACK  ;
-
-    delete [] out_SPR_WRITE_STATUS_VAL        ;
-    delete []  in_SPR_WRITE_STATUS_ACK        ;
-
-    // ~~~~~[ Interface "insert_rob" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-    delete []  in_INSERT_ROB_VAL                  ;
-    delete [] out_INSERT_ROB_ACK                  ;
-    delete []  in_INSERT_ROB_RD_USE               ;
-    delete []  in_INSERT_ROB_RE_USE               ;
-    delete [] out_INSERT_ROB_GPR_STATUS_VAL       ;
-    delete []  in_INSERT_ROB_GPR_STATUS_ACK       ;
-    delete [] out_INSERT_ROB_SPR_STATUS_VAL       ;
-    delete []  in_INSERT_ROB_SPR_STATUS_ACK       ;
-
-//     // ~~~~~[ Interface "retire_rob" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-//     delete []  in_RETIRE_ROB_VAL                      ;
-//     delete [] out_RETIRE_ROB_ACK                      ;
-//     delete []  in_RETIRE_ROB_RD_OLD_USE               ;
-//     delete []  in_RETIRE_ROB_RD_NEW_USE               ;
-//     delete []  in_RETIRE_ROB_RE_OLD_USE               ;
-//     delete []  in_RETIRE_ROB_RE_NEW_USE               ;
-//     delete [] out_RETIRE_ROB_GPR_STATUS_OLD_VAL       ;
-//     delete [] out_RETIRE_ROB_GPR_STATUS_NEW_VAL       ;
-//     delete []  in_RETIRE_ROB_GPR_STATUS_OLD_ACK       ;
-//     delete []  in_RETIRE_ROB_GPR_STATUS_NEW_ACK       ;
-//     delete [] out_RETIRE_ROB_SPR_STATUS_OLD_VAL       ;
-//     delete [] out_RETIRE_ROB_SPR_STATUS_NEW_VAL       ;
-//     delete []  in_RETIRE_ROB_SPR_STATUS_OLD_ACK       ;
-//     delete []  in_RETIRE_ROB_SPR_STATUS_NEW_ACK       ;
+    DELETE2_SIGNAL(out_INSERT_ROB_SPR_STATUS_VAL,_param->_nb_ooo_engine,_param->_nb_inst_insert_rob [it1],1);
+    DELETE2_SIGNAL( in_INSERT_ROB_SPR_STATUS_ACK,_param->_nb_ooo_engine,_param->_nb_inst_insert_rob [it1],1);
       }
     // ~~~~~[ Component ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~    
