Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_OOO_Engine/OOO_Engine/Special_Register_unit/SelfTest/src/main.cpp
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_OOO_Engine/OOO_Engine/Special_Register_unit/SelfTest/src/main.cpp	(revision 115)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_OOO_Engine/OOO_Engine/Special_Register_unit/SelfTest/src/main.cpp	(revision 117)
@@ -61,4 +61,13 @@
     }
 
+  uint32_t    num_thread = 0;
+  uint32_t ** _translate_num_context_to_num_thread       = new uint32_t * [_nb_front_end];
+  for (uint32_t i=0; i<_nb_front_end; i++)
+    {
+      _translate_num_context_to_num_thread [i] = new uint32_t [_nb_context[i]];
+      for (uint32_t j=0; j<_nb_context[i]; j++)
+        _translate_num_context_to_num_thread [i][j] = num_thread ++;
+    }
+
   int _return = EXIT_SUCCESS;
   try 
@@ -70,4 +79,5 @@
 	 _nb_inst_reexecute ,
 	 _implement_group   ,
+         _translate_num_context_to_num_thread,
          true //is_toplevel
         );
@@ -100,4 +110,11 @@
   for (uint32_t i=0; i<_nb_front_end; i++)
     {
+      delete [] _translate_num_context_to_num_thread [i];
+    }
+  delete [] _translate_num_context_to_num_thread;
+
+
+  for (uint32_t i=0; i<_nb_front_end; i++)
+    {
       for (uint32_t j=0; j<_nb_context[i]; j++)
 	delete [] _implement_group [i][j];
Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_OOO_Engine/OOO_Engine/Special_Register_unit/include/Parameters.h
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_OOO_Engine/OOO_Engine/Special_Register_unit/include/Parameters.h	(revision 115)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_OOO_Engine/OOO_Engine/Special_Register_unit/include/Parameters.h	(revision 117)
@@ -27,4 +27,5 @@
   public : uint32_t     _nb_inst_reexecute     ;
   public : bool     *** _implement_group       ;//[nb_front_end][nb_context][NB_GROUP]
+  public : uint32_t  ** _translate_num_context_to_num_thread; //[nb_front_end][nb_context]
 
   public : uint32_t     _max_nb_context        ;
@@ -41,4 +42,5 @@
 			uint32_t     nb_inst_reexecute     ,
 			bool     *** implement_group       ,
+                        uint32_t  ** translate_num_context_to_num_thread, //[nb_front_end][nb_context]
                         bool         is_toplevel=false
 			);
Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_OOO_Engine/OOO_Engine/Special_Register_unit/include/SPR.h
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_OOO_Engine/OOO_Engine/Special_Register_unit/include/SPR.h	(revision 115)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_OOO_Engine/OOO_Engine/Special_Register_unit/include/SPR.h	(revision 117)
@@ -545,19 +545,50 @@
   // [0][21] CID
   //----------------------------------------------------------
-  class CID : public GENERIC 
-  {
-  public : CID (uint32_t num_front_end=0, uint32_t num_context=0,const Parameters * param=NULL) : GENERIC (num_front_end,num_context,param) {};
-  };
-
-  //----------------------------------------------------------
-  // [0][22] TID
-  //----------------------------------------------------------
-  class TID : public GENERIC 
-  {
-  public : TID (uint32_t num_front_end=0, uint32_t num_context=0,const Parameters * param=NULL) : GENERIC (num_front_end,num_context,param) {};
-  };
-
-  //----------------------------------------------------------
-  // [0][23] TSR
+  class CID : public morpheo::behavioural::SPR
+  {
+  private: const Tspr_t _cpu_id : 32; // cpu_id reset value
+  public :       Tspr_t  cpu_id : 32;
+
+  public :        CID (uint32_t num_front_end=0, uint32_t num_context=0,const Parameters * param=NULL): 
+    _cpu_id ((param==NULL)?0:param->_translate_num_context_to_num_thread[num_front_end][num_context])
+    {};
+  public : void   reset (void  ) 
+    {
+      cpu_id = _cpu_id;
+    };
+  public : Tspr_t read  (void  )
+    {
+      return ((cpu_id << 0));
+    };
+  public : void   write (Tspr_t x) 
+    {
+      cpu_id = x >> 0;
+    };
+  };
+
+  //----------------------------------------------------------
+  // [0][22] TID - Thread Id
+  //----------------------------------------------------------
+  class TID : public morpheo::behavioural::SPR
+  {
+  public :       Tspr_t  thread_id : 32;
+
+  public :        TID (uint32_t num_front_end=0, uint32_t num_context=0,const Parameters * param=NULL)
+    {};
+  public : void   reset (void  ) 
+    {
+    };
+  public : Tspr_t read  (void  )
+    {
+      return ((thread_id << 0));
+    };
+  public : void   write (Tspr_t x) 
+    {
+      thread_id = x >> 0;
+    };
+  };
+
+  //----------------------------------------------------------
+  // [0][23] TSR - Thread Status Register
   //----------------------------------------------------------
   class TSR : public GENERIC 
Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_OOO_Engine/OOO_Engine/Special_Register_unit/src/Parameters.cpp
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_OOO_Engine/OOO_Engine/Special_Register_unit/src/Parameters.cpp	(revision 115)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_OOO_Engine/OOO_Engine/Special_Register_unit/src/Parameters.cpp	(revision 117)
@@ -23,4 +23,5 @@
 			  uint32_t     nb_inst_reexecute     ,
 			  bool     *** implement_group       ,
+                          uint32_t  ** translate_num_context_to_num_thread, //[nb_front_end][nb_context]
                           bool         is_toplevel
 			  )
@@ -32,4 +33,5 @@
     _nb_inst_reexecute      = nb_inst_reexecute;
     _implement_group        = implement_group  ;
+    _translate_num_context_to_num_thread = translate_num_context_to_num_thread;
 
     _max_nb_context         = max<uint32_t>(_nb_context,_nb_front_end);
Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_OOO_Engine/OOO_Engine/Special_Register_unit/src/Special_Register_unit_allocation.cpp
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_OOO_Engine/OOO_Engine/Special_Register_unit/src/Special_Register_unit_allocation.cpp	(revision 115)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_OOO_Engine/OOO_Engine/Special_Register_unit/src/Special_Register_unit_allocation.cpp	(revision 117)
@@ -236,6 +236,7 @@
       for (uint32_t j=0; j<_param->_nb_context[i]; j++)
 	for (uint32_t k=0; k<NB_GROUP; k++)
-	  if (_param->_implement_group [i][j][k])
+          if (_param->_implement_group [i][j][k])
             {
+              
               for (uint32_t l=0; l<NB_REG_GROUP[k]; l++)
                 if (_spr [i][j][k][l] == NULL)
