Index: trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_OOO_Engine/OOO_Engine/Rename_unit/Register_translation_unit/Stat_List_unit/src/Stat_List_unit_transition.cpp
===================================================================
--- trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_OOO_Engine/OOO_Engine/Rename_unit/Register_translation_unit/Stat_List_unit/src/Stat_List_unit_transition.cpp	(revision 81)
+++ trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_OOO_Engine/OOO_Engine/Rename_unit/Register_translation_unit/Stat_List_unit/src/Stat_List_unit_transition.cpp	(revision 88)
@@ -23,5 +23,6 @@
   void Stat_List_unit::transition (void)
   {
-    log_printf(FUNC,Stat_List_unit,FUNCTION,"Begin");
+    log_begin(Stat_List_unit,FUNCTION);
+    log_function(Stat_List_unit,FUNCTION,_name.c_str());
 
     if (PORT_READ(in_NRESET) == 0)
@@ -121,9 +122,10 @@
 	      if (PORT_READ(in_RETIRE_WRITE_RD [i]))
 		{
+                  Tcontrol_t restore_old = PORT_READ(in_RETIRE_RESTORE_RD_PHY_OLD [i]);
 		  {
 		    Tgeneral_address_t num_reg = PORT_READ(in_RETIRE_NUM_REG_RD_PHY_OLD [i]);
 		    uint32_t bank = num_reg >> _param->_shift_gpr;
 		    uint32_t reg  = num_reg  & _param->_mask_gpr ;
-		    gpr_stat_list [bank][reg].retire_write_old();
+		    gpr_stat_list [bank][reg].retire_write_old(restore_old);
 		  }
 		  {
@@ -131,5 +133,5 @@
 		    uint32_t bank = num_reg >> _param->_shift_gpr;
 		    uint32_t reg  = num_reg  & _param->_mask_gpr ;
-		    gpr_stat_list [bank][reg].retire_write_new();
+		    gpr_stat_list [bank][reg].retire_write_new(restore_old);
 		  }
 		}
@@ -137,9 +139,10 @@
 	      if (PORT_READ(in_RETIRE_WRITE_RE [i]))
 		{
+                  Tcontrol_t restore_old = PORT_READ(in_RETIRE_RESTORE_RE_PHY_OLD [i]);
 		  {
 		    Tgeneral_address_t num_reg = PORT_READ(in_RETIRE_NUM_REG_RE_PHY_OLD [i]);
 		    uint32_t bank = num_reg >> _param->_shift_spr;
 		    uint32_t reg  = num_reg  & _param->_mask_spr ;
-		    spr_stat_list [bank][reg].retire_write_old();
+		    spr_stat_list [bank][reg].retire_write_old(restore_old);
 		  }
 		  {
@@ -147,5 +150,5 @@
 		    uint32_t bank = num_reg >> _param->_shift_spr;
 		    uint32_t reg  = num_reg  & _param->_mask_spr ;
-		    spr_stat_list [bank][reg].retire_write_new();
+		    spr_stat_list [bank][reg].retire_write_new(restore_old);
 		  }
 		}
@@ -171,28 +174,29 @@
 	internal_SPR_PTR_FREE = ((internal_SPR_PTR_FREE==0)?_param->_nb_special_register_by_bank:internal_SPR_PTR_FREE)-1;
       }
-    
-//     log_printf(TRACE,Stat_List_unit,FUNCTION,"Print gpr_stat_list :");
-//     for (uint32_t i=0; i<_param->_nb_bank; i++)
-//       {
-// 	log_printf(TRACE,Stat_List_unit,FUNCTION," * Bank : %d",i);
-// 	for (uint32_t j=0; j<_param->_nb_general_register_by_bank; j++)
-// 	  {
-// 	    std::ostringstream str;
-// 	    str << gpr_stat_list [i][j];
-// 	    log_printf(TRACE,Stat_List_unit,FUNCTION,"   [%d] %s",j,str.str().c_str());
-
-// 	  }
-//       }
-//     log_printf(TRACE,Stat_List_unit,FUNCTION,"Print spr_stat_list :");
-//     for (uint32_t i=0; i<_param->_nb_bank; i++)
-//       {
-// 	log_printf(TRACE,Stat_List_unit,FUNCTION," * Bank : %d",i);
-// 	for (uint32_t j=0; j<_param->_nb_special_register_by_bank; j++)
-// 	  {
-// 	    std::ostringstream str;
-// 	    str << spr_stat_list [i][j];
-// 	    log_printf(TRACE,Stat_List_unit,FUNCTION,"   [%d] %s",j,str.str().c_str());
-// 	  }
-//       }
+
+
+#if (DEBUG >= DEBUG_TRACE)
+    log_printf(TRACE,Stat_List_unit,FUNCTION,"  * Dump Stat List");
+    for (uint32_t i=0; i<_param->_nb_bank; i++)
+      for (uint32_t j=0; j<_param->_nb_general_register_by_bank; j++)
+        log_printf(TRACE,Stat_List_unit,FUNCTION,"    * GPR[%.4d][%.5d] (%.5d) - free %.1d, link %.1d, valid %.1d, counter %.4d",
+                   i,
+                   j,
+                   (i<<_param->_shift_gpr)|j,
+                   gpr_stat_list[i][j]._is_free,
+                   gpr_stat_list[i][j]._is_link,
+                   gpr_stat_list[i][j]._is_valid,
+                   gpr_stat_list[i][j]._counter);
+    for (uint32_t i=0; i<_param->_nb_bank; i++)
+      for (uint32_t j=0; j<_param->_nb_special_register_by_bank; j++)
+        log_printf(TRACE,Stat_List_unit,FUNCTION,"    * SPR[%.4d][%.5d] (%.5d) - free %.1d, link %.1d, valid %.1d, counter %.4d",
+                   i,
+                   j,
+                   (i<<_param->_shift_spr)|j,
+                   spr_stat_list[i][j]._is_free,
+                   spr_stat_list[i][j]._is_link,
+                   spr_stat_list[i][j]._is_valid,
+                   spr_stat_list[i][j]._counter);
+#endif
 
 #if defined(STATISTICS) or defined(VHDL_TESTBENCH)
@@ -200,5 +204,5 @@
 #endif
 
-    log_printf(FUNC,Stat_List_unit,FUNCTION,"End");
+    log_end(Stat_List_unit,FUNCTION);
   };
 
