Ignore:
Timestamp:
Oct 13, 2010, 8:15:51 PM (14 years ago)
Author:
rosiere
Message:

1) add test with SPECINT2K
2) new config of Selftest
3) modif RAT to support multiple depth_save ... but not finish (need fix Update Prediction Table)
4) add Function_pointer but need fix

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_OOO_Engine/OOO_Engine/Rename_unit/Register_translation_unit/Register_Address_Translation_unit/src/Register_Address_Translation_unit_function_one_save_transition.cpp

    r139 r145  
    3434          for (uint32_t j=0; j<_param->_nb_context[i]; j++)
    3535            {
    36               rat_gpr_not_speculative   [i][j][0] = 0;
    37               rat_gpr_speculative_valid [i][j][0] = false;
    38               rat_gpr_speculative       [i][j][0] = 0    ; // not necessary
     36              RAT_GPR_NOT_SPECULATIVE   [i][j][0]    = 0;
     37              RAT_GPR_SPECULATIVE_VALID [i][j][0][0] = false;
     38              RAT_GPR_SPECULATIVE       [i][j][0][0] = 0    ; // not necessary
    3939
    4040              for (uint32_t k=1; k<_param->_nb_general_register_logic; k++)
    4141                {
    42                   rat_gpr_not_speculative    [i][j][k] = gpr++;
    43                   rat_gpr_speculative_valid  [i][j][k] = false;
    44                   rat_gpr_speculative        [i][j][k] = 0    ; // not necessary
     42                  RAT_GPR_NOT_SPECULATIVE    [i][j][k]    = gpr++;
     43                  RAT_GPR_SPECULATIVE_VALID  [i][j][0][k] = false;
     44                  RAT_GPR_SPECULATIVE        [i][j][0][k] = 0    ; // not necessary
    4545                }
    4646              for (uint32_t k=0; k<_param->_nb_special_register_logic; k++)
    4747                {
    48                   rat_spr_not_speculative    [i][j][k] = spr++;
    49                   rat_spr_speculative_valid  [i][j][k] = false;
    50                   rat_spr_speculative        [i][j][k] = 0    ; // not necessary
     48                  RAT_SPR_NOT_SPECULATIVE    [i][j][k]    = spr++;
     49                  RAT_SPR_SPECULATIVE_VALID  [i][j][0][k] = false;
     50                  RAT_SPR_SPECULATIVE        [i][j][0][k] = 0    ; // not necessary
    5151                }
    5252            }
     
    6969                  // Reset validity table
    7070                  for (uint32_t k=0; k<_param->_nb_general_register_logic; k++)
    71                     rat_gpr_speculative_valid [i][j][k] = false;
     71                    RAT_GPR_SPECULATIVE_VALID [i][j][0][k] = false;
    7272                  for (uint32_t k=0; k<_param->_nb_special_register_logic; k++)
    73                     rat_spr_speculative_valid [i][j][k] = false;
     73                    RAT_SPR_SPECULATIVE_VALID [i][j][0][k] = false;
    7474                }
    7575
     
    103103                  log_printf(TRACE,Register_Address_Translation_unit,FUNCTION,"    * num_reg_rd_phy     : %d",num_reg_rd_phy);
    104104
    105                   rat_gpr_speculative       [front_end_id][context_id][num_reg_rd_log] = num_reg_rd_phy;
    106                   rat_gpr_speculative_valid [front_end_id][context_id][num_reg_rd_log] = true;
     105                  RAT_GPR_SPECULATIVE       [front_end_id][context_id][0][num_reg_rd_log] = num_reg_rd_phy;
     106                  RAT_GPR_SPECULATIVE_VALID [front_end_id][context_id][0][num_reg_rd_log] = true;
    107107                }
    108108
     
    116116                  log_printf(TRACE,Register_Address_Translation_unit,FUNCTION,"    * num_reg_re_phy     : %d",num_reg_re_phy);
    117117
    118                   rat_spr_speculative       [front_end_id][context_id][num_reg_re_log] = num_reg_re_phy;
    119                   rat_spr_speculative_valid [front_end_id][context_id][num_reg_re_log] = true;
     118                  RAT_SPR_SPECULATIVE       [front_end_id][context_id][0][num_reg_re_log] = num_reg_re_phy;
     119                  RAT_SPR_SPECULATIVE_VALID [front_end_id][context_id][0][num_reg_re_log] = true;
    120120                }
    121121            }
     
    160160                  log_printf(TRACE,Register_Address_Translation_unit,FUNCTION,"    * num_reg_rd_phy_new : %d",num_reg_rd_phy_new);
    161161
    162                   rat_gpr_not_speculative [front_end_id][context_id][num_reg_rd_log] = num_reg_rd_phy_new;
     162                  RAT_GPR_NOT_SPECULATIVE [front_end_id][context_id][num_reg_rd_log] = num_reg_rd_phy_new;
    163163                    }
    164164                }
     
    177177                  log_printf(TRACE,Register_Address_Translation_unit,FUNCTION,"    * num_reg_re_phy_new : %d",num_reg_re_phy_new);
    178178
    179                   rat_spr_not_speculative [front_end_id][context_id][num_reg_re_log] = num_reg_re_phy_new;
     179                  RAT_SPR_NOT_SPECULATIVE [front_end_id][context_id][num_reg_re_log] = num_reg_re_phy_new;
    180180                    }
    181181                }
     
    203203                      break;
    204204                    else
    205                       str+=toString("GPR[%.4d] - %.1d %.5d (%.5d) | ",index,rat_gpr_speculative_valid [i][j][index],rat_gpr_speculative [i][j][index],rat_gpr_not_speculative [i][j][index]);
     205                      str+=toString("GPR[%.4d] - %.1d %.5d (%.5d) | ",index,RAT_GPR_SPECULATIVE_VALID [i][j][0][index],RAT_GPR_SPECULATIVE [i][j][0][index],RAT_GPR_NOT_SPECULATIVE [i][j][index]);
    206206                  }
    207207                log_printf(TRACE,Register_Address_Translation_unit,FUNCTION,"      * %s",str.c_str());
     
    218218                      break;
    219219                    else
    220                       str+=toString("SPR[%.4d] - %.1d %.5d (%.5d) | ",index,rat_spr_speculative_valid [i][j][index],rat_spr_speculative [i][j][index],rat_spr_not_speculative [i][j][index]);
     220                      str+=toString("SPR[%.4d] - %.1d %.5d (%.5d) | ",index,RAT_SPR_SPECULATIVE_VALID [i][j][0][index],RAT_SPR_SPECULATIVE [i][j][0][index],RAT_SPR_NOT_SPECULATIVE [i][j][index]);
    221221                  }
    222222                log_printf(TRACE,Register_Address_Translation_unit,FUNCTION,"      * %s",str.c_str());
     
    235235              for (uint32_t y=x+1; y<_param->_nb_general_register_logic; ++y)
    236236                {
    237                   if (rat_gpr_speculative_valid [i][j][x] and
    238                       rat_gpr_speculative_valid [i][j][y] and
    239                       (rat_gpr_speculative[i][j][x] == rat_gpr_speculative[i][j][y]))
    240                     throw ERRORMORPHEO (FUNCTION,toString(_("In RAT, rat_gpr_speculative[%d][%d][%d] == rat_gpr_speculative[%d][%d][%d] == %d"),i,j,x,i,j,y,rat_gpr_speculative[i][j][x]));
    241                   if (rat_gpr_not_speculative[i][j][x] == rat_gpr_not_speculative[i][j][y])
    242                     throw ERRORMORPHEO (FUNCTION,toString(_("In RAT, rat_gpr_not_speculative[%d][%d][%d] == rat_gpr_not_speculative[%d][%d][%d] == %d"),i,j,x,i,j,y,rat_gpr_not_speculative[i][j][x]));
     237                  if (RAT_GPR_SPECULATIVE_VALID [i][j][0][x] and
     238                      RAT_GPR_SPECULATIVE_VALID [i][j][0][y] and
     239                      (RAT_GPR_SPECULATIVE[i][j][0][x] == RAT_GPR_SPECULATIVE[i][j][0][y]))
     240                    throw ERRORMORPHEO (FUNCTION,toString(_("In RAT, RAT_GPR_SPECULATIVE[%d][%d][0][%d] == RAT_GPR_SPECULATIVE[%d][%d][0][%d] == %d"),i,j,x,i,j,y,RAT_GPR_SPECULATIVE[i][j][0][x]));
     241                  if (RAT_GPR_NOT_SPECULATIVE[i][j][x] == RAT_GPR_NOT_SPECULATIVE[i][j][y])
     242                    throw ERRORMORPHEO (FUNCTION,toString(_("In RAT, RAT_GPR_NOT_SPECULATIVE[%d][%d][%d] == RAT_GPR_NOT_SPECULATIVE[%d][%d][%d] == %d"),i,j,x,i,j,y,RAT_GPR_NOT_SPECULATIVE[i][j][x]));
    243243                 
    244244                }
     
    246246              for (uint32_t y=x+1; y<_param->_nb_special_register_logic; ++y)
    247247                {
    248                   if(rat_spr_speculative_valid [i][j][x] and
    249                      rat_spr_speculative_valid [i][j][y] and
    250                      (rat_spr_speculative[i][j][x] == rat_spr_speculative[i][j][y]))
    251                     throw ERRORMORPHEO (FUNCTION,toString(_("In RAT, rat_spr_speculative[%d][%d][%d] == rat_spr_speculative[%d][%d][%d] == %d"),i,j,x,i,j,y,rat_spr_speculative[i][j][x]));
    252                   if (rat_spr_not_speculative[i][j][x] == rat_spr_not_speculative[i][j][y])
    253                     throw ERRORMORPHEO (FUNCTION,toString(_("In RAT, rat_spr_not_speculative[%d][%d][%d] == rat_spr_not_speculative[%d][%d][%d] == %d"),i,j,x,i,j,y,rat_spr_not_speculative[i][j][x]));
     248                  if(RAT_SPR_SPECULATIVE_VALID [i][j][0][x] and
     249                     RAT_SPR_SPECULATIVE_VALID [i][j][0][y] and
     250                     (RAT_SPR_SPECULATIVE[i][j][0][x] == RAT_SPR_SPECULATIVE[i][j][0][y]))
     251                    throw ERRORMORPHEO (FUNCTION,toString(_("In RAT, RAT_SPR_SPECULATIVE[%d][%d][0][%d] == RAT_SPR_SPECULATIVE[%d][%d][0][%d] == %d"),i,j,x,i,j,y,RAT_SPR_SPECULATIVE[i][j][0][x]));
     252                  if (RAT_SPR_NOT_SPECULATIVE[i][j][x] == RAT_SPR_NOT_SPECULATIVE[i][j][y])
     253                    throw ERRORMORPHEO (FUNCTION,toString(_("In RAT, RAT_SPR_NOT_SPECULATIVE[%d][%d][%d] == RAT_SPR_NOT_SPECULATIVE[%d][%d][%d] == %d"),i,j,x,i,j,y,RAT_SPR_NOT_SPECULATIVE[i][j][x]));
    254254                 
    255255                }
Note: See TracChangeset for help on using the changeset viewer.