Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/Makefile.deps
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/Makefile.deps	(revision 98)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/Makefile.deps	(revision 100)
@@ -26,19 +26,17 @@
 					$(Behavioural_DIR_LIBRARY)
 
-Queue_DEPENDENCIES		=	Queue_Control_library	\
-					Behavioural_library
-
-Queue_CLEAN        		=	Queue_Control_library_clean	\
-					Behavioural_library_clean
-
 #-----[ Rules ]--------------------------------------------
 
 #.NOTPARALLEL			: Queue_library Queue_library_clean
 
-Queue_library			: $(Queue_DEPENDENCIES)
+Queue_library			:
 				@\
+				$(MAKE) Behavioural_library;\
+				$(MAKE) Queue_Control_library;\
 				$(MAKE) --directory=$(DIR_MORPHEO)/Behavioural/Generic/Queue --makefile=Makefile;
 
-Queue_library_clean		: $(Queue_CLEAN)
+Queue_library_clean		:
 				@\
+				$(MAKE) Behavioural_library_clean;\
+				$(MAKE) Queue_Control_library_clean;\
 				$(MAKE) --directory=$(DIR_MORPHEO)/Behavioural/Generic/Queue --makefile=Makefile clean;
Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/SelfTest/config_min.cfg
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/SelfTest/config_min.cfg	(revision 100)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/SelfTest/config_min.cfg	(revision 100)
@@ -0,0 +1,4 @@
+Queue
+1	1 	*2	#_size_queue	
+1	1	*2	#_size_data 
+0  	1  	+1	#_nb_port_slot
Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/SelfTest/config_size_queue_log2.cfg
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/SelfTest/config_size_queue_log2.cfg	(revision 98)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/SelfTest/config_size_queue_log2.cfg	(revision 100)
@@ -2,2 +2,3 @@
 1	32 	*2	#_size_queue	
 32	32	*2	#_size_data 
+0  	0  	*2	#_nb_port_slot
Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/SelfTest/config_size_queue_no_log2.cfg
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/SelfTest/config_size_queue_no_log2.cfg	(revision 98)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/SelfTest/config_size_queue_no_log2.cfg	(revision 100)
@@ -2,2 +2,3 @@
 3	256	*4	#_size_queue	
 32	32	*2	#_size_data 
+0  	0  	*2	#_nb_port_slot
Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/SelfTest/config_slot_out_size_queue_log2.cfg
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/SelfTest/config_slot_out_size_queue_log2.cfg	(revision 100)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/SelfTest/config_slot_out_size_queue_log2.cfg	(revision 100)
@@ -0,0 +1,4 @@
+Queue
+8	8 	*2	#_size_queue	
+32	32	*2	#_size_data 
+1  	8  	*2	#_nb_port_slot
Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/SelfTest/config_slot_out_size_queue_no_log2.cfg
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/SelfTest/config_slot_out_size_queue_no_log2.cfg	(revision 100)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/SelfTest/config_slot_out_size_queue_no_log2.cfg	(revision 100)
@@ -0,0 +1,4 @@
+Queue
+11	11	*4	#_size_queue	
+32	32	*2	#_size_data 
+1  	8  	*2	#_nb_port_slot
Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/SelfTest/include/test.h
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/SelfTest/include/test.h	(revision 98)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/SelfTest/include/test.h	(revision 100)
@@ -16,4 +16,5 @@
 
 #include "Behavioural/Generic/Queue/include/Queue.h"
+#include "Common/include/Time.h"
 
 using namespace std;
@@ -26,34 +27,2 @@
 void test    (string name,
 	      morpheo::behavioural::generic::queue::Parameters * param);
-
-class Time 
-{
-private : timeval time_begin;
-// private : timeval time_end;
-  
-public  : Time ()
-  {
-    gettimeofday(&time_begin     ,NULL);
-  };
-
-public  : ~Time ()
-  {
-    cout << *this;
-  };
-
-public  : friend ostream& operator<< (ostream& output_stream,
-				      const Time & x)
-  {
-    timeval time_end;
-    
-    gettimeofday(&time_end       ,NULL);
-    
-    uint32_t nb_cycles = static_cast<uint32_t>(sc_simulation_time());
-
-    double average = static_cast<double>(nb_cycles) / static_cast<double>(time_end.tv_sec-x.time_begin.tv_sec);
-    
-    output_stream << nb_cycles << "\t(" << average << " cycles / seconds )" << endl;
-
-    return output_stream;
-  }
-};
Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/SelfTest/src/main.cpp
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/SelfTest/src/main.cpp	(revision 98)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/SelfTest/src/main.cpp	(revision 100)
@@ -8,5 +8,5 @@
 #include "Behavioural/Generic/Queue/SelfTest/include/test.h"
 
-#define NB_PARAMS 2
+#define NB_PARAMS 3
 
 void usage (int argc, char * argv[])
@@ -14,6 +14,7 @@
   cerr << "<Usage> " << argv[0] << " name_instance list_params" << endl
        << "list_params is :" << endl
-       << " - size_queue (uint32_t)" << endl
-       << " - size_data  (uint32_t)" << endl
+       << " - size_queue   (uint32_t)" << endl
+       << " - size_data    (uint32_t)" << endl
+       << " - nb_port_slot (uint32_t)" << endl
        << "" << endl;
 
@@ -36,7 +37,8 @@
   uint32_t       x = 1;
   
-  const string   name       =      argv[x++];
-  const uint32_t size_queue = atoi(argv[x++]);
-  const uint32_t size_data  = atoi(argv[x++]);
+  const string   name         =      argv[x++];
+  const uint32_t size_queue   = atoi(argv[x++]);
+  const uint32_t size_data    = atoi(argv[x++]);
+  const uint32_t nb_port_slot = atoi(argv[x++]);
 
   try 
@@ -44,5 +46,6 @@
       morpheo::behavioural::generic::queue::Parameters * param = new morpheo::behavioural::generic::queue::Parameters
 	(size_queue,
-	 size_data
+	 size_data ,
+         nb_port_slot
         );
       
Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/SelfTest/src/test.cpp
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/SelfTest/src/test.cpp	(revision 98)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/SelfTest/src/test.cpp	(revision 100)
@@ -11,4 +11,5 @@
 
 #include "Behavioural/Generic/Queue/SelfTest/include/test.h"
+#include "Behavioural/include/Allocation.h"
 #include "Common/include/Test.h"
 
@@ -48,10 +49,13 @@
   sc_clock              *  in_CLOCK  = new sc_clock ("clock", 1.0, 0.5);	 
   sc_signal<Tcontrol_t> *  in_NRESET = new sc_signal<Tcontrol_t> ("NRESET");
-  sc_signal<Tcontrol_t> *  in_INSERT_VAL  = new sc_signal<Tcontrol_t> ( "in_INSERT_VAL" );
-  sc_signal<Tcontrol_t> * out_INSERT_ACK  = new sc_signal<Tcontrol_t> ("out_INSERT_ACK" );
-  sc_signal<Tdata_t   > *  in_INSERT_DATA = new sc_signal<Tdata_t   > ( "in_INSERT_DATA");
-  sc_signal<Tcontrol_t> * out_RETIRE_VAL  = new sc_signal<Tcontrol_t> ("out_RETIRE_VAL" );
-  sc_signal<Tcontrol_t> *  in_RETIRE_ACK  = new sc_signal<Tcontrol_t> ( "in_RETIRE_ACK" );
-  sc_signal<Tdata_t   > * out_RETIRE_DATA = new sc_signal<Tdata_t   > ("out_RETIRE_DATA");
+
+  ALLOC0_SC_SIGNAL( in_INSERT_VAL , "in_INSERT_VAL" ,Tcontrol_t);
+  ALLOC0_SC_SIGNAL(out_INSERT_ACK ,"out_INSERT_ACK" ,Tcontrol_t);
+  ALLOC0_SC_SIGNAL( in_INSERT_DATA, "in_INSERT_DATA",Tdata_t   );
+  ALLOC0_SC_SIGNAL(out_RETIRE_VAL ,"out_RETIRE_VAL" ,Tcontrol_t);
+  ALLOC0_SC_SIGNAL( in_RETIRE_ACK , "in_RETIRE_ACK" ,Tcontrol_t);
+  ALLOC0_SC_SIGNAL(out_RETIRE_DATA,"out_RETIRE_DATA",Tdata_t   );
+  ALLOC1_SC_SIGNAL(out_SLOT_VAL   ,"out_SLOT_VAL"   ,Tcontrol_t,_param->_nb_port_slot);
+  ALLOC1_SC_SIGNAL(out_SLOT_DATA  ,"out_SLOT_DATA"  ,Tdata_t   ,_param->_nb_port_slot);
   
   /********************************************************
@@ -64,10 +68,12 @@
   (*(_Queue->in_NRESET))       (*(in_NRESET));
 
-  (*(_Queue-> in_INSERT_VAL )) (*( in_INSERT_VAL ));
-  (*(_Queue->out_INSERT_ACK )) (*(out_INSERT_ACK ));
-  (*(_Queue-> in_INSERT_DATA)) (*( in_INSERT_DATA));
-  (*(_Queue->out_RETIRE_VAL )) (*(out_RETIRE_VAL ));
-  (*(_Queue-> in_RETIRE_ACK )) (*( in_RETIRE_ACK ));
-  (*(_Queue->out_RETIRE_DATA)) (*(out_RETIRE_DATA));
+  INSTANCE0_SC_SIGNAL(_Queue, in_INSERT_VAL );
+  INSTANCE0_SC_SIGNAL(_Queue,out_INSERT_ACK );
+  INSTANCE0_SC_SIGNAL(_Queue, in_INSERT_DATA);
+  INSTANCE0_SC_SIGNAL(_Queue,out_RETIRE_VAL );
+  INSTANCE0_SC_SIGNAL(_Queue, in_RETIRE_ACK );
+  INSTANCE0_SC_SIGNAL(_Queue,out_RETIRE_DATA);
+  INSTANCE1_SC_SIGNAL(_Queue,out_SLOT_VAL   ,_param->_nb_port_slot);
+  INSTANCE1_SC_SIGNAL(_Queue,out_SLOT_DATA  ,_param->_nb_port_slot);
 
   cout << "<" << name << "> Start Simulation ............" << endl;
@@ -103,4 +109,5 @@
   uint32_t data_in  = 0;
   uint32_t data_out = 0;
+  uint32_t nb_elt   = 0;
 
   for (uint32_t iteration=0; iteration<NB_ITERATION; iteration ++)
@@ -116,8 +123,17 @@
 	  SC_START(0); // genMoore
 
+          for (uint32_t i=0; i<_param->_nb_port_slot; ++i)
+            {
+              TEST(Tcontrol_t, out_SLOT_VAL [i]->read(), (i<nb_elt));
+              if (i<nb_elt)
+              TEST(Tdata_t   , out_SLOT_DATA[i]->read(), data_out+i);
+                
+            }
+
 	  if ( in_INSERT_VAL->read() and out_INSERT_ACK->read())
 	    {
 	      LABEL ("Transaction with interface : INSERT");
 	      data_in ++;
+              nb_elt ++;
 	    }
 	  if (out_RETIRE_VAL->read() and  in_RETIRE_ACK->read())
@@ -126,4 +142,5 @@
 	      TEST(Tdata_t, out_RETIRE_DATA->read(), data_out);
 	      data_out++;
+              nb_elt --;
 	    }
 
@@ -142,4 +159,14 @@
   delete in_CLOCK;
   delete in_NRESET;
+
+  DELETE0_SC_SIGNAL( in_INSERT_VAL );
+  DELETE0_SC_SIGNAL(out_INSERT_ACK );
+  DELETE0_SC_SIGNAL( in_INSERT_DATA);
+  DELETE0_SC_SIGNAL(out_RETIRE_VAL );
+  DELETE0_SC_SIGNAL( in_RETIRE_ACK );
+  DELETE0_SC_SIGNAL(out_RETIRE_DATA);
+  DELETE1_SC_SIGNAL(out_SLOT_VAL   ,_param->_nb_port_slot);
+  DELETE1_SC_SIGNAL(out_SLOT_DATA  ,_param->_nb_port_slot);
+
 #endif
 
Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/include/Parameters.h
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/include/Parameters.h	(revision 98)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/include/Parameters.h	(revision 100)
@@ -22,11 +22,13 @@
   {
     //-----[ fields ]------------------------------------------------------------
-  public : const uint32_t _size_queue;
-  public : const uint32_t _size_data ;
-    
+  public : const uint32_t _size_queue  ;
+  public : const uint32_t _size_data   ;
+  public : const uint32_t _nb_port_slot;
 
     //-----[ methods ]-----------------------------------------------------------
   public : Parameters  (uint32_t size_queue,
-			uint32_t size_data );
+			uint32_t size_data ,
+                        uint32_t nb_port_slot);
+
 //   public : Parameters  (Parameters & param) ;
   public : ~Parameters () ;
Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/include/Queue.h
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/include/Queue.h	(revision 98)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/include/Queue.h	(revision 100)
@@ -74,4 +74,8 @@
   public    : SC_OUT(Tdata_t   )            * out_RETIRE_DATA;
 
+    // ~~~~~[ Interface "slot" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+  public    : SC_OUT(Tcontrol_t)           ** out_SLOT_VAL ;
+  public    : SC_OUT(Tdata_t   )           ** out_SLOT_DATA;
+
     // ~~~~~[ Component ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~    
   protected : morpheo::behavioural::generic::queue_control::Queue_Control * _queue_control;
Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/src/Parameters.cpp
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/src/Parameters.cpp	(revision 98)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/src/Parameters.cpp	(revision 100)
@@ -17,7 +17,9 @@
 #define FUNCTION "Queue::Parameters"
   Parameters::Parameters (uint32_t size_queue,
-			  uint32_t size_data ):
-    _size_queue (size_queue),
-    _size_data  (size_data )
+			  uint32_t size_data ,
+                          uint32_t nb_port_slot):
+    _size_queue   (size_queue),
+    _size_data    (size_data ),
+    _nb_port_slot (nb_port_slot)
   {
     log_printf(FUNC,Queue,FUNCTION,"Begin");
Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/src/Parameters_msg_error.cpp
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/src/Parameters_msg_error.cpp	(revision 98)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/src/Parameters_msg_error.cpp	(revision 100)
@@ -23,4 +23,7 @@
     Parameters_test test("Queue");
 
+    if (_nb_port_slot > _size_queue)
+      test.error(_("nb_port_slot must be <= size_queue\n"));
+
     log_printf(FUNC,Queue,FUNCTION,"End");
 
@@ -30,5 +33,4 @@
 }; // end namespace queue
 }; // end namespace generic
-
 }; // end namespace behavioural
 }; // end namespace morpheo              
Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/src/Queue_allocation.cpp
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/src/Queue_allocation.cpp	(revision 98)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/src/Queue_allocation.cpp	(revision 100)
@@ -7,4 +7,5 @@
 
 #include "Behavioural/Generic/Queue/include/Queue.h"
+#include "Behavioural/include/Allocation.h"
 
 namespace morpheo                    {
@@ -38,5 +39,5 @@
 							 ,IN
 							 ,SOUTH,
-							 "Generalist interface"
+							 _("Generalist interface")
 #endif
 							 );
@@ -48,29 +49,26 @@
     // ~~~~~[ Interface "insert" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
     {
-      Interface_fifo * interface = _interfaces->set_interface("insert"
-#ifdef POSITION
-							 ,IN
-							 ,WEST
-							 ,"Insertion of data"
-#endif
-							 );
+      ALLOC0_INTERFACE("insert", IN, WEST, _("Interface of data write."));
       
-       in_INSERT_VAL  = interface->set_signal_valack_in (VAL);
-      out_INSERT_ACK  = interface->set_signal_valack_out(ACK);
-       in_INSERT_DATA = interface->set_signal_in  <Tdata_t> ("data", _param->_size_data);
+      ALLOC0_VALACK_IN ( in_INSERT_VAL  ,VAL);
+      ALLOC0_VALACK_OUT(out_INSERT_ACK  ,ACK);
+      ALLOC0_SIGNAL_IN ( in_INSERT_DATA ,"data",Tdata_t,_param->_size_data);
     }
+
     // ~~~~~[ Interface "retire" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
     {
-      Interface_fifo * interface = _interfaces->set_interface("retire"
-#ifdef POSITION
-							      ,IN
-							      ,EAST
-							      ,"Retire of data"
-#endif
-							      );
+      ALLOC0_INTERFACE("retire", OUT, EAST, _("Interface of data read."));
       
-      out_RETIRE_VAL  = interface->set_signal_valack_out(VAL);
-       in_RETIRE_ACK  = interface->set_signal_valack_in (ACK);
-      out_RETIRE_DATA = interface->set_signal_out <Tdata_t> ("data", _param->_size_data);
+      ALLOC0_VALACK_OUT(out_RETIRE_VAL  ,VAL);
+      ALLOC0_VALACK_IN ( in_RETIRE_ACK  ,ACK);
+      ALLOC0_SIGNAL_OUT(out_RETIRE_DATA ,"data",Tdata_t,_param->_size_data);
+    }
+
+    // ~~~~~[ Interface "slot" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+    {
+      ALLOC1_INTERFACE("slot", OUT, EAST, _("Internal slot."),_param->_nb_port_slot);
+      
+      ALLOC1_VALACK_OUT(out_SLOT_VAL  ,VAL);
+      ALLOC1_SIGNAL_OUT(out_SLOT_DATA ,"data",Tdata_t,_param->_size_data);
     }
      
Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/src/Queue_deallocation.cpp
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/src/Queue_deallocation.cpp	(revision 98)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/src/Queue_deallocation.cpp	(revision 100)
@@ -7,4 +7,5 @@
 
 #include "Behavioural/Generic/Queue/include/Queue.h"
+#include "Behavioural/include/Allocation.h"
 
 namespace morpheo                    {
@@ -24,12 +25,15 @@
 	delete    in_CLOCK ;
 	delete    in_NRESET;
-	
-	delete    in_INSERT_VAL ;
-	delete   out_INSERT_ACK ;
-	delete    in_INSERT_DATA;
-	
-	delete   out_RETIRE_VAL ;
-	delete    in_RETIRE_ACK ;
-	delete   out_RETIRE_DATA;
+
+        DELETE0_SIGNAL( in_INSERT_VAL                        ,1);
+        DELETE0_SIGNAL(out_INSERT_ACK                        ,1);
+        DELETE0_SIGNAL( in_INSERT_DATA                       ,_param->_size_data);
+
+        DELETE0_SIGNAL(out_RETIRE_VAL                        ,1);
+        DELETE0_SIGNAL( in_RETIRE_ACK                        ,1);
+        DELETE0_SIGNAL(out_RETIRE_DATA                       ,_param->_size_data);
+
+        DELETE1_SIGNAL(out_SLOT_VAL    ,_param->_nb_port_slot,1);
+        DELETE1_SIGNAL(out_SLOT_DATA   ,_param->_nb_port_slot,_param->_size_data);
 	
         // ~~~~~[ Component ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~    
Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/src/Queue_genMoore.cpp
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/src/Queue_genMoore.cpp	(revision 98)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/src/Queue_genMoore.cpp	(revision 100)
@@ -19,5 +19,6 @@
   {
     log_printf(FUNC,Queue,FUNCTION,"Begin");
-    
+
+    // Output
     internal_INSERT_ACK = not _queue_control->full();
     internal_RETIRE_VAL = not _queue_control->empty();
@@ -26,4 +27,14 @@
     PORT_WRITE(out_RETIRE_VAL , internal_RETIRE_VAL);
     PORT_WRITE(out_RETIRE_DATA,_queue_data[(*_queue_control)[0]]);
+
+    // Slot
+    // Note : Slot 0 is the same slot as retire interface.
+    uint32_t nb_elt = _queue_control->nb_elt();
+
+    for (uint32_t i=0; i<_param->_nb_port_slot; ++i)
+      {
+        PORT_WRITE(out_SLOT_VAL  [i], i<nb_elt);
+        PORT_WRITE(out_SLOT_DATA [i],_queue_data[(*_queue_control)[i]]);
+      }
 
     log_printf(FUNC,Queue,FUNCTION,"End");
Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/src/Queue_vhdl_body.cpp
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/src/Queue_vhdl_body.cpp	(revision 98)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/src/Queue_vhdl_body.cpp	(revision 100)
@@ -20,102 +20,199 @@
   {
     log_printf(FUNC,Queue,FUNCTION,"Begin");
-    vhdl->set_body ("-----------------------------------------------------------------------------");
-    vhdl->set_body ("-- Output");
-    vhdl->set_body ("-----------------------------------------------------------------------------");
-    vhdl->set_body ("out_INSERT_ACK        <= not reg_FULL;");
-    vhdl->set_body ("out_RETIRE_VAL        <= not reg_EMPTY;");
-	
-    if (_param->_size_queue > 1)
-      vhdl->set_body ("out_RETIRE_DATA       <= reg_DATA(conv_integer(reg_PTR_READ));");
-    else
-      vhdl->set_body ("out_RETIRE_DATA       <= reg_DATA(0);");
-
-    vhdl->set_body ("");
-    vhdl->set_body ("-----------------------------------------------------------------------------");
-    vhdl->set_body ("-- Signal");
-    vhdl->set_body ("-----------------------------------------------------------------------------");
-    vhdl->set_body ("");
-    vhdl->set_body ("signal_PTR_EQUAL      <=");
-    if (_param->_size_queue > 1)
-      {
-	vhdl->set_body ("\t'1' when signal_NEXT_PTR_READ = signal_NEXT_PTR_WRITE else");
-	vhdl->set_body ("\t'0';");
-      }
-    else
-      vhdl->set_body ("\t'1';");
-    vhdl->set_body ("signal_NEXT_FULL      <=");
-    vhdl->set_body ("\t'1' when signal_WRITE='1' and signal_PTR_EQUAL='1' else");
-    vhdl->set_body ("\t'0' when signal_READ ='1'                          else");
-    vhdl->set_body ("\treg_FULL ;");
-    vhdl->set_body ("signal_NEXT_EMPTY     <=");
-    vhdl->set_body ("\t'1' when signal_READ ='1' and signal_PTR_EQUAL='1' else");
-    vhdl->set_body ("\t'0' when signal_WRITE='1'                          else");
-    vhdl->set_body ("\treg_EMPTY;");
-    vhdl->set_body ("");
-    vhdl->set_body ("-- read");
-    vhdl->set_body ("signal_READ           <= (not reg_EMPTY) and in_RETIRE_ACK;");
-
+    vhdl->set_comment(0,"---------------------------------------------------------------------------");
+    vhdl->set_comment(0," Output");
+    vhdl->set_comment(0,"---------------------------------------------------------------------------");
+    vhdl->set_body   (0,"out_INSERT_ACK        <= not signal_FULL;");
+    vhdl->set_body   (0,"out_RETIRE_VAL        <= not signal_EMPTY;");
+        
+    if (_param->_size_queue > 1)
+    vhdl->set_body   (0,"out_RETIRE_DATA       <= reg_DATA(conv_integer(signal_PTR_READ));");
+    else
+    vhdl->set_body   (0,"out_RETIRE_DATA       <= reg_DATA(0);");
+
+    vhdl->set_body   (0,"");
+    vhdl->set_comment(0,"---------------------------------------------------------------------------");
+    vhdl->set_comment(0," Slot");
+    vhdl->set_comment(0,"---------------------------------------------------------------------------");
+    vhdl->set_body   (0,"");
+    if (_param->_nb_port_slot > 1)
+      for (uint32_t i=0; i<_param->_nb_port_slot; ++i)
+        if (i==0)
+          vhdl->set_body   (0,"signal_SLOT_0           <= signal_PTR_READ;");
+        else
+          {
+            if (is_power2(_param->_size_queue))
+              vhdl->set_body   (0,"signal_SLOT_"+toString(i)+"           <= signal_PTR_READ+"+std_logic_cst(log2(_param->_size_queue),i)+";");
+            else
+              vhdl->set_body   (0,"signal_SLOT_"+toString(i)+"           <= const_PTR_INIT when signal_SLOT_"+toString(i-1)+" = const_PTR_MAX else signal_SLOT_"+toString(i-1)+"+'1';");
+          }
+        
+    for (uint32_t i=0; i<_param->_nb_port_slot; ++i)
+      {
+        if (_param->_nb_port_slot > 1)
+          vhdl->set_body   (0,"out_SLOT_"+toString(i)+"_VAL        <= '1' when reg_NB_ELT > "+std_logic_cst(log2(_param->_size_queue+1),i)+" else '0';");
+        else
+          vhdl->set_body   (0,"out_SLOT_"+toString(i)+"_VAL        <= not signal_EMPTY;");
+        
+        if (_param->_nb_port_slot > 1)
+          vhdl->set_body   (0,"out_SLOT_"+toString(i)+"_DATA       <= reg_DATA(conv_integer(signal_SLOT_"+toString(i)+"));");
+        else
+          if (_param->_size_queue > 1)
+            vhdl->set_body   (0,"out_SLOT_"+toString(i)+"_DATA       <= reg_DATA(conv_integer(signal_PTR_READ));");
+          else
+            vhdl->set_body   (0,"out_SLOT_"+toString(i)+"_DATA       <= reg_DATA(conv_integer(0));");
+      }
+
+    vhdl->set_body   (0,"");
+    vhdl->set_comment(0,"---------------------------------------------------------------------------");
+    vhdl->set_comment(0," Signal");
+    vhdl->set_comment(0,"---------------------------------------------------------------------------");
+    vhdl->set_body   (0,"");
+    vhdl->set_body   (0,"signal_READ           <= (not signal_EMPTY) and in_RETIRE_ACK;");
+    vhdl->set_body   (0,"signal_WRITE          <= (not signal_FULL ) and in_INSERT_VAL;");
+    vhdl->set_body   (0,"");
+    if (_param->_nb_port_slot>1)
+      {
+        vhdl->set_body   (0,"signal_EMPTY          <= '1' when reg_NB_ELT = "+std_logic_cst(log2(_param->_size_queue+1),0)+" else '0';");
+    if (is_power2(_param->_size_queue))
+    vhdl->set_body   (0,"signal_FULL           <= reg_NB_ELT "+std_logic_range(log2(_param->_size_queue),log2(_param->_size_queue))+";");
+    else
+      vhdl->set_body   (0,"signal_FULL           <= '1' when reg_NB_ELT = "+std_logic_cst(log2(_param->_size_queue+1),_param->_size_queue)+" else '0';");
+      }
+    else
+      {
+    vhdl->set_body   (0,"signal_EMPTY          <= reg_EMPTY;");
+    vhdl->set_body   (0,"signal_FULL           <= reg_FULL ;");
+      }
+    vhdl->set_body   (0,"");
+    if (_param->_size_queue > 1)
+      {
+    vhdl->set_body   (0,"signal_PTR_READ       <= reg_PTR_READ;");
+    if (_param->_nb_port_slot>1)
+      {
+        if (is_power2(_param->_size_queue))
+          vhdl->set_body   (0,"signal_PTR_WRITE      <= reg_PTR_READ + reg_NB_ELT"+std_logic_range(log2(_param->_size_queue))+";");
+        else
+          vhdl->set_body   (0,"signal_PTR_WRITE      <= reg_PTR_READ + reg_NB_ELT"+std_logic_range(log2(_param->_size_queue))+" when reg_PTR_READ + reg_NB_ELT"+std_logic_range(log2(_param->_size_queue)) +" <= const_PTR_MAX else reg_PTR_READ + reg_NB_ELT"+std_logic_range(log2(_param->_size_queue))+" - const_PTR_MAX-'1';");
+      }
+    else
+    vhdl->set_body   (0,"signal_PTR_WRITE      <= reg_PTR_WRITE;");
+      }
+    vhdl->set_body   (0,"");
+
+    if (_param->_nb_port_slot>1)
+      {
+    vhdl->set_body   (0,"");
+    vhdl->set_comment(0," nb_elt");
     if (_param->_size_queue > 1)
       {  
-	vhdl->set_body ("signal_NEXT_PTR_READ  <= ");
-	vhdl->set_body ("\treg_PTR_READ   when signal_READ='0' else");
-	if (is_log2(_param->_size_queue) == false)
-	  vhdl->set_body ("\tconst_PTR_INIT when reg_PTR_READ  = const_PTR_MAX else");
-
-	if (_param->_size_queue > 2)
-	  vhdl->set_body ("\treg_PTR_READ +'1';");
-	else
-	  vhdl->set_body ("\tnot reg_PTR_READ;");
-      }
-    vhdl->set_body ("");
-    vhdl->set_body ("-- write");
-    vhdl->set_body ("signal_WRITE          <= (not reg_FULL ) and in_INSERT_VAL;");
-    if (_param->_size_queue > 1)
-      {
-	vhdl->set_body ("signal_NEXT_PTR_WRITE <= ");
-	vhdl->set_body ("\treg_PTR_WRITE  when signal_WRITE='0' else");
-	if (is_log2(_param->_size_queue) == false)
-	  vhdl->set_body ("\tconst_PTR_INIT when reg_PTR_WRITE = const_PTR_MAX else");
-	if (_param->_size_queue > 2)
-	  vhdl->set_body ("\treg_PTR_WRITE+'1';");
-	else
-	  vhdl->set_body ("\tnot reg_PTR_WRITE;");
-      }
-    vhdl->set_body ("");
-    vhdl->set_body ("-----------------------------------------------------------------------------");
-    vhdl->set_body ("-- Registers");
-    vhdl->set_body ("-----------------------------------------------------------------------------");
-    vhdl->set_body ("");
-    vhdl->set_body ("queue_write: process (in_CLOCK)");
-    vhdl->set_body ("begin  -- process queue_write");
-    vhdl->set_body ("\tif in_CLOCK'event and in_CLOCK = '1' then");
-    vhdl->set_body ("");
-    vhdl->set_body ("\t\tif (in_NRESET = '0') then");    
-    if (_param->_size_queue > 1)
-      {
-	vhdl->set_body ("\t\t\treg_PTR_READ  <= const_PTR_INIT;");
-	vhdl->set_body ("\t\t\treg_PTR_WRITE <= const_PTR_INIT;");
-      }
-    vhdl->set_body ("\t\t\treg_FULL      <= '0';");
-    vhdl->set_body ("\t\t\treg_EMPTY     <= '1';");
-    vhdl->set_body ("\t\telse");
-    if (_param->_size_queue > 1)
-      {
-	vhdl->set_body ("\t\t\treg_PTR_READ  <= signal_NEXT_PTR_READ ;");
-	vhdl->set_body ("\t\t\treg_PTR_WRITE <= signal_NEXT_PTR_WRITE;");
-      }
-    vhdl->set_body ("\t\t\treg_FULL      <= signal_NEXT_FULL ;");
-    vhdl->set_body ("\t\t\treg_EMPTY     <= signal_NEXT_EMPTY;");
-    vhdl->set_body ("");
-    vhdl->set_body ("\t\t\tif (signal_WRITE = '1') then");    
-    if (_param->_size_queue > 1)
-      vhdl->set_body ("\t\t\t\treg_DATA(conv_integer(reg_PTR_WRITE)) <= in_INSERT_DATA;");
-    else
-      vhdl->set_body ("\t\t\t\treg_DATA(0) <= in_INSERT_DATA;");
-    vhdl->set_body ("\t\t\tend if;");
-    vhdl->set_body ("\t\tend if;");
-    vhdl->set_body ("");
-    vhdl->set_body ("\tend if;");
-    vhdl->set_body ("end process queue_write;");
+    vhdl->set_body   (0,"signal_NEXT_NB_ELT  <= ");
+    vhdl->set_body   (1,"reg_NB_ELT   when (signal_READ xor signal_WRITE) = '0' else");
+    if (_param->_size_queue > 2)
+      {
+    vhdl->set_body   (1,"reg_NB_ELT +'1' when signal_WRITE='1' else");
+    vhdl->set_body   (1,"reg_NB_ELT -'1';");
+      }
+    else
+    vhdl->set_body   (1,"not reg_NB_ELT;");
+      }
+      }
+    else
+      {
+    vhdl->set_body   (0,"signal_PTR_EQUAL      <=");
+    if (_param->_size_queue > 1)
+      {
+    vhdl->set_body   (1,"'1' when signal_NEXT_PTR_READ = signal_NEXT_PTR_WRITE else");
+    vhdl->set_body   (1,"'0';");
+      }
+    else
+    vhdl->set_body   (1,"'1';");
+    vhdl->set_body   (0,"signal_NEXT_FULL      <=");
+    vhdl->set_body   (1,"'1' when signal_WRITE='1' and signal_PTR_EQUAL='1' else");
+    vhdl->set_body   (1,"'0' when signal_READ ='1'                          else");
+    vhdl->set_body   (1,"reg_FULL ;");
+    vhdl->set_body   (0,"signal_NEXT_EMPTY     <=");
+    vhdl->set_body   (1,"'1' when signal_READ ='1' and signal_PTR_EQUAL='1' else");
+    vhdl->set_body   (1,"'0' when signal_WRITE='1'                          else");
+    vhdl->set_body   (1,"reg_EMPTY;");
+    vhdl->set_body   (0,"");
+
+    vhdl->set_comment(0," write");
+    if (_param->_size_queue > 1)
+      {
+    vhdl->set_body   (0,"signal_NEXT_PTR_WRITE <= ");
+    vhdl->set_body   (1,"reg_PTR_WRITE  when signal_WRITE='0' else");
+    if (is_log2(_param->_size_queue) == false)
+    vhdl->set_body   (1,"const_PTR_INIT when reg_PTR_WRITE = const_PTR_MAX else");
+    if (_param->_size_queue > 2)
+    vhdl->set_body   (1,"reg_PTR_WRITE+'1';");
+    else
+    vhdl->set_body   (1,"not reg_PTR_WRITE;");
+      }
+      }
+
+    vhdl->set_body   (0,"");
+    vhdl->set_comment(0," read");
+    if (_param->_size_queue > 1)
+      {  
+    vhdl->set_body   (0,"signal_NEXT_PTR_READ  <= ");
+    vhdl->set_body   (1,"reg_PTR_READ   when signal_READ='0' else");
+    if (is_log2(_param->_size_queue) == false)
+    vhdl->set_body   (1,"const_PTR_INIT when reg_PTR_READ  = const_PTR_MAX else");
+
+    if (_param->_size_queue > 2)
+    vhdl->set_body   (1,"reg_PTR_READ +'1';");
+    else
+    vhdl->set_body   (1,"not reg_PTR_READ;");
+      }
+    vhdl->set_body   (0,"");
+
+    vhdl->set_comment(0,"---------------------------------------------------------------------------");
+    vhdl->set_comment(0," Registers");
+    vhdl->set_comment(0,"---------------------------------------------------------------------------");
+    vhdl->set_body   (0,"");
+    vhdl->set_body   (0,"queue_write: process (in_CLOCK)");
+    vhdl->set_body   (0,"begin  -- process queue_write");
+    vhdl->set_body   (1,"if in_CLOCK'event and in_CLOCK = '1' then");
+    vhdl->set_body   (0,"");
+    vhdl->set_body   (2,"if (in_NRESET = '0') then");    
+    if (_param->_size_queue > 1)
+      {
+        vhdl->set_body   (3,"reg_PTR_READ  <= const_PTR_INIT;");
+        if (_param->_nb_port_slot>1)
+        vhdl->set_body   (3,"reg_NB_ELT    <= "+std_logic_cst(log2(_param->_size_queue+1),0)+";");
+        else
+        vhdl->set_body   (3,"reg_PTR_WRITE <= const_PTR_INIT;");
+      }
+    if (_param->_nb_port_slot<=1)
+      {
+    vhdl->set_body   (3,"reg_FULL      <= '0';");
+    vhdl->set_body   (3,"reg_EMPTY     <= '1';");
+      }
+    vhdl->set_body   (2,"else");
+    if (_param->_size_queue > 1)
+      {
+        vhdl->set_body   (3,"reg_PTR_READ  <= signal_NEXT_PTR_READ ;");
+        if (_param->_nb_port_slot>1)
+        vhdl->set_body   (3,"reg_NB_ELT    <= signal_NEXT_NB_ELT   ;");
+        else
+        vhdl->set_body   (3,"reg_PTR_WRITE <= signal_NEXT_PTR_WRITE;");
+      }
+    if (_param->_nb_port_slot<=1)
+      {
+    vhdl->set_body   (3,"reg_FULL      <= signal_NEXT_FULL ;");
+    vhdl->set_body   (3,"reg_EMPTY     <= signal_NEXT_EMPTY;");
+      }
+    vhdl->set_body   (0,"");
+    vhdl->set_body   (3,"if (signal_WRITE = '1') then");    
+    if (_param->_size_queue > 1)
+      vhdl->set_body   (3,"\treg_DATA(conv_integer(signal_PTR_WRITE)) <= in_INSERT_DATA;");
+    else
+      vhdl->set_body   (3,"\treg_DATA(0) <= in_INSERT_DATA;");
+    vhdl->set_body   (3,"end if;");
+    vhdl->set_body   (2,"end if;");
+    vhdl->set_body   (0,"");
+    vhdl->set_body   (1,"end if;");
+    vhdl->set_body   (0,"end process queue_write;");
 
     log_printf(FUNC,Queue,FUNCTION,"End");
Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/src/Queue_vhdl_declaration.cpp
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/src/Queue_vhdl_declaration.cpp	(revision 98)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Queue/src/Queue_vhdl_declaration.cpp	(revision 100)
@@ -24,24 +24,39 @@
     
     vhdl->set_signal  ("reg_DATA             ", "Tqueue");
-    vhdl->set_signal  ("reg_FULL             ", 1);
-    vhdl->set_signal  ("reg_EMPTY            ", 1);
-    if (_param->_size_queue > 1)
-      {
-	vhdl->set_signal  ("reg_PTR_READ         ", log2(_param->_size_queue));
-	vhdl->set_signal  ("reg_PTR_WRITE        ", log2(_param->_size_queue));
-      }
+
     vhdl->set_signal  ("signal_READ          ", 1);
     vhdl->set_signal  ("signal_WRITE         ", 1);
-    vhdl->set_signal  ("signal_PTR_EQUAL     ", 1);
+    vhdl->set_signal  ("signal_EMPTY         ", 1);
+    vhdl->set_signal  ("signal_FULL          ", 1);
 
     if (_param->_size_queue > 1)
       {
-	vhdl->set_signal  ("signal_NEXT_PTR_READ ", log2(_param->_size_queue));
-	vhdl->set_signal  ("signal_NEXT_PTR_WRITE", log2(_param->_size_queue));
+    vhdl->set_signal  ("reg_PTR_READ         ", log2(_param->_size_queue));
+    vhdl->set_signal  ("signal_NEXT_PTR_READ ", log2(_param->_size_queue));
+    vhdl->set_signal  ("signal_PTR_READ      ", log2(_param->_size_queue));
+    vhdl->set_signal  ("signal_PTR_WRITE     ", log2(_param->_size_queue));
       }
 
+    if (_param->_nb_port_slot>1)
+      {
+    vhdl->set_signal  ("reg_NB_ELT           ", log2(_param->_size_queue+1));
+    vhdl->set_signal  ("signal_NEXT_NB_ELT   ", log2(_param->_size_queue+1));
+    for (uint32_t i=0; i<_param->_nb_port_slot; ++i)
+    vhdl->set_signal  ("signal_SLOT_"+toString(i), log2(_param->_size_queue));
+      }
+    else
+      {
+    if (_param->_size_queue > 1)
+      {
+    vhdl->set_signal  ("reg_PTR_WRITE        ", log2(_param->_size_queue));
+    vhdl->set_signal  ("signal_NEXT_PTR_WRITE", log2(_param->_size_queue));
+      }
+    vhdl->set_signal  ("reg_FULL             ", 1);
+    vhdl->set_signal  ("reg_EMPTY            ", 1);
     vhdl->set_signal  ("signal_NEXT_FULL     ", 1);
     vhdl->set_signal  ("signal_NEXT_EMPTY    ", 1);
-    
+    vhdl->set_signal  ("signal_PTR_EQUAL     ", 1);
+      }
+
     if (_param->_size_queue > 1)
       {
