Ignore:
Timestamp:
Jul 9, 2007, 11:04:26 AM (17 years ago)
Author:
rosiere
Message:

Modif mineur : ajout d'info de débug

Release non stable

Location:
trunk/IPs/systemC/processor/Morpheo/Behavioural/Stage_1_Ifetch/Predictor/Meta_Predictor/Two_Level_Branch_Predictor
Files:
3 added
7 deleted
11 edited
2 moved

Legend:

Unmodified
Added
Removed
  • trunk/IPs/systemC/processor/Morpheo/Behavioural/Stage_1_Ifetch/Predictor/Meta_Predictor/Two_Level_Branch_Predictor/Branch_History_Table/include/Branch_History_Table.h

    r42 r43  
    119119#if VHDL                                       
    120120  public  : void     vhdl                      (void);
    121   private : void     vhdl_port                 (Vhdl * & vhdl);
    122   private : void     vhdl_type                 (Vhdl * & vhdl);
    123   private : void     vhdl_signal               (Vhdl * & vhdl);
     121  private : void     vhdl_declaration          (Vhdl * & vhdl);
    124122  private : void     vhdl_body                 (Vhdl * & vhdl);
    125123#endif                                         
  • trunk/IPs/systemC/processor/Morpheo/Behavioural/Stage_1_Ifetch/Predictor/Meta_Predictor/Two_Level_Branch_Predictor/Branch_History_Table/src/Branch_History_Table_vhdl.cpp

    r42 r43  
    2323    Vhdl * vhdl = new Vhdl (_name);
    2424
    25     vhdl->set_library_work (_name + "_Pack");
    26     vhdl->set_library_work (_name + "_RegisterFile_Pack");
    27     vhdl->set_library_work (_name + "_Shifter_Pack");
     25    _interfaces->set_port     (vhdl);
     26    _component ->vhdl_instance(vhdl);
    2827
    29     vhdl_port   (vhdl);
    30     vhdl_type   (vhdl);
    31     vhdl_signal (vhdl);
    32     vhdl_body   (vhdl);
     28    vhdl_declaration (vhdl);
     29    vhdl_body        (vhdl);
    3330
    3431    vhdl->generate_file();
  • trunk/IPs/systemC/processor/Morpheo/Behavioural/Stage_1_Ifetch/Predictor/Meta_Predictor/Two_Level_Branch_Predictor/Pattern_History_Table/SelfTest/configuration.cfg

    r42 r43  
    11Pattern_History_Table
    2 8       8       *2      # size_counter         
    3 64      64      *4      # nb_counter       
    4 2       2       +1      # nb_prediction     
    5 2       2       +1      # nb_branch_complete
     22       8       *2      # size_counter         
     32       64      *4      # nb_counter       
     41       2       +1      # nb_prediction     
     51       2       +1      # nb_branch_complete
  • trunk/IPs/systemC/processor/Morpheo/Behavioural/Stage_1_Ifetch/Predictor/Meta_Predictor/Two_Level_Branch_Predictor/Pattern_History_Table/src/Pattern_History_Table_vhdl.cpp

    r42 r43  
    2222  {
    2323    log_printf(FUNC,Pattern_History_Table,"vhdl","Begin");
     24
    2425    Vhdl * vhdl = new Vhdl (_name);
    2526
    26     _interfaces->set_port(vhdl);
    27     _component->vhdl_instance(vhdl);
     27    _interfaces->set_port     (vhdl);
     28    _component ->vhdl_instance(vhdl);
    2829
    2930    vhdl_declaration (vhdl);
  • trunk/IPs/systemC/processor/Morpheo/Behavioural/Stage_1_Ifetch/Predictor/Meta_Predictor/Two_Level_Branch_Predictor/SelfTest/config0.cfg

    r5 r43  
    221       1       +1      # have_bht           
    338       8       +1      # bht_size_shifter   
    4 512     512     *2      # bht_nb_shifter     
     432      32      *2      # bht_nb_shifter     
    551       1       +1      # have_pht           
    668       8       +1      # pht_size_counter   
    7 512     512     *2      # pht_nb_counter     
     732      32      *2      # pht_nb_counter     
    882       2       +1      # pht_size_address_share
    9916      16      +1      # size_address     
  • trunk/IPs/systemC/processor/Morpheo/Behavioural/Stage_1_Ifetch/Predictor/Meta_Predictor/Two_Level_Branch_Predictor/SelfTest/src/test.cpp

    r15 r43  
    137137    BRANCH_COMPLETE_VAL          [i]->write(0);
    138138
    139   _Two_Level_Branch_Predictor->vhdl_testbench_label("Initialisation");
    140139  cout << "{"+toString(static_cast<uint32_t>(sc_simulation_time()))+"} Initialisation" << endl;
    141140
     
    157156      uint32_t nb_reg_by_group = (1<<(param._pht_size_address-size_address_shift));
    158157
    159       _Two_Level_Branch_Predictor->vhdl_testbench_label("Init pht");
    160158      cout << "{"+toString(static_cast<uint32_t>(sc_simulation_time()))+"} Init pht" << endl;
    161159     
     
    186184      BRANCH_COMPLETE_BHT_HISTORY  [num_port_branch_complete]->write(0);
    187185     
    188       _Two_Level_Branch_Predictor->vhdl_testbench_label("Init bht");
    189186      cout << "{"+toString(static_cast<uint32_t>(sc_simulation_time()))+"} Init bht" << endl;
    190187     
     
    206203  BRANCH_COMPLETE_ADDRESS      [num_port_branch_complete]->write(address);
    207204
    208   _Two_Level_Branch_Predictor->vhdl_testbench_label("Loop of Test");
    209205  cout << "{"+toString(static_cast<uint32_t>(sc_simulation_time()))+"} Loop of Test" << endl
    210206       << " * predict_address : " << hex << address << dec << endl;
     
    219215  for (uint32_t iteration=0; iteration<NB_ITERATION; iteration ++)
    220216    {
    221       _Two_Level_Branch_Predictor->vhdl_testbench_label("Iteration "+toString(iteration));
    222 
    223217      cout << "{"+toString(static_cast<uint32_t>(sc_simulation_time()))+"} Predict          : bht_history " << bht_history << " - pht_history " << pht_history[bht_history] << endl;
    224218
  • trunk/IPs/systemC/processor/Morpheo/Behavioural/Stage_1_Ifetch/Predictor/Meta_Predictor/Two_Level_Branch_Predictor/Two_Level_Branch_Predictor_Glue/include/Two_Level_Branch_Predictor_Glue.h

    r42 r43  
    129129#if VHDL                                       
    130130  public  : void     vhdl                      (void);
    131   private : void     vhdl_port                 (Vhdl * & vhdl);
    132131  private : void     vhdl_declaration          (Vhdl * & vhdl);
    133132  private : void     vhdl_body                 (Vhdl * & vhdl);
  • trunk/IPs/systemC/processor/Morpheo/Behavioural/Stage_1_Ifetch/Predictor/Meta_Predictor/Two_Level_Branch_Predictor/Two_Level_Branch_Predictor_Glue/src/Two_Level_Branch_Predictor_Glue_vhdl.cpp

    r42 r43  
    2525    Vhdl * vhdl = new Vhdl (_name);
    2626
    27     vhdl->set_library_work (_name + "_Pack");
     27    _interfaces->set_port     (vhdl);
     28    _component ->vhdl_instance(vhdl);
    2829
    29     vhdl_port        (vhdl);
    3030    vhdl_declaration (vhdl);
    3131    vhdl_body        (vhdl);
  • trunk/IPs/systemC/processor/Morpheo/Behavioural/Stage_1_Ifetch/Predictor/Meta_Predictor/Two_Level_Branch_Predictor/include/Two_Level_Branch_Predictor.h

    r42 r43  
    135135#if VHDL                                       
    136136  public  : void     vhdl                      (void);
    137   private : void     vhdl_port                 (Vhdl * & vhdl);
    138137  private : void     vhdl_declaration          (Vhdl * & vhdl);
    139138  private : void     vhdl_body                 (Vhdl * & vhdl);
  • trunk/IPs/systemC/processor/Morpheo/Behavioural/Stage_1_Ifetch/Predictor/Meta_Predictor/Two_Level_Branch_Predictor/src/Two_Level_Branch_Predictor_allocation.cpp

    r42 r43  
    8989    for (uint32_t i=0; i<_param._nb_branch_complete; i++)
    9090      {
    91          in_BRANCH_COMPLETE_VAL         [i] = new interface->set_signal_valack_in            ("val"        , VAL);                 
    92         out_BRANCH_COMPLETE_ACK         [i] = new interface->set_signal_valack_out           ("ack"        , ACK);                 
    93          in_BRANCH_COMPLETE_ADDRESS     [i] = new interface->set_signal_in  <Taddress_t    > ("address"    , _param._size_address);
     91        Interface_fifo * interface = _interfaces->set_interface("branch_complete_"+toString(i)
     92#ifdef POSITION
     93                                                                , IN 
     94                                                                , EAST
     95                                                                , "Interface branch complete"
     96#endif
     97                                                                );
     98
     99         in_BRANCH_COMPLETE_VAL         [i] = interface->set_signal_valack_in            ("val"        , VAL);             
     100        out_BRANCH_COMPLETE_ACK         [i] = interface->set_signal_valack_out           ("ack"        , ACK);             
     101         in_BRANCH_COMPLETE_ADDRESS     [i] = interface->set_signal_in  <Taddress_t    > ("address"    , _param._size_address);
    94102        if (_param._have_bht)
    95          in_BRANCH_COMPLETE_BHT_HISTORY [i] = new interface->set_signal_in  <Tbht_history_t> ("bht_history", _param._bht_size_shifter);
     103         in_BRANCH_COMPLETE_BHT_HISTORY [i] = interface->set_signal_in  <Tbht_history_t> ("bht_history", _param._bht_size_shifter);
    96104        if (_param._have_pht)
    97          in_BRANCH_COMPLETE_PHT_HISTORY [i] = new interface->set_signal_in  <Tpht_history_t> ("pht_history", _param._pht_size_counter);
    98          in_BRANCH_COMPLETE_DIRECTION   [i] = new interface->set_signal_in  <Tcontrol_t    > ("direction"  , 1);
     105         in_BRANCH_COMPLETE_PHT_HISTORY [i] = interface->set_signal_in  <Tpht_history_t> ("pht_history", _param._pht_size_counter);
     106         in_BRANCH_COMPLETE_DIRECTION   [i] = interface->set_signal_in  <Tcontrol_t    > ("direction"  , 1);
    99107      }
    100108
     
    111119                                                                                                                                                                                       ,_param_statistics
    112120#endif
    113                                                                                                                                                                                        ,*(_param._param_counter));
     121                                                                                                                                                                                       ,*(_param._param_branch_history_table));
    114122       
    115123        _component->set_component (component_Branch_History_Table->_component
     
    132140                                                                                                                                                                                          ,_param_statistics
    133141#endif
    134                                                                                                                                                                                           ,*(_param._param_counter));
     142                                                                                                                                                                                          ,*(_param._param_pattern_history_table));
    135143       
    136144        _component->set_component (component_Pattern_History_Table->_component
     
    152160                                                                                                                                                                                                                   ,_param_statistics
    153161#endif
    154                                                                                                                                                                                                                    ,*(_param._param_counter));
    155    
    156     _component->set_component (component_Pattern_History_Table->_component
     162                                                                                                                                                                                                                   ,*(_param._param_two_level_branch_predictor_glue));
     163   
     164    _component->set_component (component_Two_Level_Branch_Predictor_Glue->_component
    157165#ifdef POSITION
    158166                               , 50
     
    164172   
    165173    // ~~~~~[ Component - Instanciation ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    166    
     174
    167175    // =====[ component_Branch_History_Table - Instanciation ]============
    168176    if (_param._have_bht)
    169177      {
     178        cout << "GEU 1" << endl;
    170179#ifdef POSITION
    171180        _component->interface_map (_name+"_Branch_History_Table","",
     
    205214    if (_param._have_pht)
    206215      {
     216        cout << "GEU 2" << endl;
    207217#ifdef POSITION
    208218        _component->interface_map (_name+"_Pattern_History_Table","",
     
    224234            _component->port_map(_name+"_Pattern_History_Table","out_PREDICT_"+toString(i)+"_HISTORY", _name                                   ,"out_PREDICT_"+toString(i)+"_PHT_HISTORY");
    225235          }
    226        
     236
    227237        for (uint32_t i=0; i<_param._nb_branch_complete; i++)
    228238          {
     
    240250
    241251    // =====[ component_Two_Level_Branch_Predictor_Glue - Instanciation ]=
     252    cout << "GEU 3" << endl;
    242253#ifdef POSITION
    243254        _component->interface_map (_name+"_Two_Level_Branch_Predictor_Glue","",
     
    247258        _component->port_map(_name+"_Two_Level_Branch_Predictor_Glue", "in_NRESET", _name,"in_NRESET");
    248259
     260        cout << "GEU 3.1" << endl;
    249261        for (uint32_t i=0; i<_param._nb_prediction; i++)
    250262          {
     263            cout << "GEU 3.1.1" << endl;
    251264        if (_param._have_bht)
    252265          {
    253         _component->port_map(_name+"_Two_Level_Branch_Predictor_Glue",  "in_PREDICT_"+toString(i)+"_BHT_ACK"    , _name+"_Branch_History_Table" , "out_PREDICT_"+toString(i)+"_BHT_ACK"    );
    254         _component->port_map(_name+"_Two_Level_Branch_Predictor_Glue", "out_PREDICT_"+toString(i)+"_BHT_ADDRESS", _name+"_Branch_History_Table" ,  "in_PREDICT_"+toString(i)+"_BHT_ADDRESS");
    255           }
     266        _component->port_map(_name+"_Two_Level_Branch_Predictor_Glue",  "in_PREDICT_"+toString(i)+"_BHT_ACK"    , _name+"_Branch_History_Table" , "out_PREDICT_"+toString(i)+"_ACK"    );
     267        _component->port_map(_name+"_Two_Level_Branch_Predictor_Glue", "out_PREDICT_"+toString(i)+"_BHT_ADDRESS", _name+"_Branch_History_Table" ,  "in_PREDICT_"+toString(i)+"_ADDRESS");
     268          }
     269        cout << "GEU 3.1.2" << endl;
    256270        if (_param._have_pht)
    257271          {
    258         _component->port_map(_name+"_Two_Level_Branch_Predictor_Glue",  "in_PREDICT_"+toString(i)+"_PHT_ACK"    , _name+"_Pattern_History_Table", "out_PREDICT_"+toString(i)+"_PHT_ACK"    );
    259         _component->port_map(_name+"_Two_Level_Branch_Predictor_Glue", "out_PREDICT_"+toString(i)+"_PHT_ADDRESS", _name+"_Pattern_History_Table",  "in_PREDICT_"+toString(i)+"_PHT_ADDRESS");
    260           }
     272        _component->port_map(_name+"_Two_Level_Branch_Predictor_Glue",  "in_PREDICT_"+toString(i)+"_PHT_ACK"    , _name+"_Pattern_History_Table", "out_PREDICT_"+toString(i)+"_ACK"    );
     273        _component->port_map(_name+"_Two_Level_Branch_Predictor_Glue", "out_PREDICT_"+toString(i)+"_PHT_ADDRESS", _name+"_Pattern_History_Table",  "in_PREDICT_"+toString(i)+"_ADDRESS");
     274          }
     275        cout << "GEU 3.1.3" << endl;
    261276        if (_param._have_bht and _param._have_pht)
    262         _component->port_map(_name+"_Two_Level_Branch_Predictor_Glue", "in_PREDICT_"+toString(i)+"_BHT_HISTORY" , _name                         , "in_PREDICT_"+toString(i)+"_BHT_HISTORY");
     277        _component->port_map(_name+"_Two_Level_Branch_Predictor_Glue", "in_PREDICT_"+toString(i)+"_BHT_HISTORY" , _name                         ,"out_PREDICT_"+toString(i)+"_BHT_HISTORY");
     278        cout << "GEU 3.1.4.1" << endl;
    263279        _component->port_map(_name+"_Two_Level_Branch_Predictor_Glue","out_PREDICT_"+toString(i)+"_ACK"         , _name                         ,"out_PREDICT_"+toString(i)+"_ACK");
    264280        _component->port_map(_name+"_Two_Level_Branch_Predictor_Glue", "in_PREDICT_"+toString(i)+"_ADDRESS"     , _name                         , "in_PREDICT_"+toString(i)+"_ADDRESS");
    265281          }
    266282   
     283        cout << "GEU 3.2" << endl;
    267284    for (uint32_t i=0; i<_param._nb_branch_complete; i++)
    268285      {
    269286        if (_param._have_bht)
    270287          {
    271         _component->port_map(_name+"_Two_Level_Branch_Predictor_Glue",  "in_BRANCH_COMPLETE_"+toString(i)+"_BHT_ACK"    , _name+"_Branch_History_Table" , "out_BRANCH_COMPLETE_"+toString(i)+"_BHT_ACK"    );
    272         _component->port_map(_name+"_Two_Level_Branch_Predictor_Glue", "out_BRANCH_COMPLETE_"+toString(i)+"_BHT_ADDRESS", _name+"_Branch_History_Table" ,  "in_BRANCH_COMPLETE_"+toString(i)+"_BHT_ADDRESS");
     288        _component->port_map(_name+"_Two_Level_Branch_Predictor_Glue",  "in_BRANCH_COMPLETE_"+toString(i)+"_BHT_ACK"    , _name+"_Branch_History_Table" , "out_BRANCH_COMPLETE_"+toString(i)+"_ACK"    );
     289        _component->port_map(_name+"_Two_Level_Branch_Predictor_Glue", "out_BRANCH_COMPLETE_"+toString(i)+"_BHT_ADDRESS", _name+"_Branch_History_Table" ,  "in_BRANCH_COMPLETE_"+toString(i)+"_ADDRESS");
    273290          }
    274291        if (_param._have_pht)
    275292          {
    276         _component->port_map(_name+"_Two_Level_Branch_Predictor_Glue",  "in_BRANCH_COMPLETE_"+toString(i)+"_PHT_ACK"    , _name+"_Pattern_History_Table", "out_BRANCH_COMPLETE_"+toString(i)+"_PHT_ACK"    );
    277         _component->port_map(_name+"_Two_Level_Branch_Predictor_Glue", "out_BRANCH_COMPLETE_"+toString(i)+"_PHT_ADDRESS", _name+"_Pattern_History_Table",  "in_BRANCH_COMPLETE_"+toString(i)+"_PHT_ADDRESS");
     293        _component->port_map(_name+"_Two_Level_Branch_Predictor_Glue",  "in_BRANCH_COMPLETE_"+toString(i)+"_PHT_ACK"    , _name+"_Pattern_History_Table", "out_BRANCH_COMPLETE_"+toString(i)+"_ACK"    );
     294        _component->port_map(_name+"_Two_Level_Branch_Predictor_Glue", "out_BRANCH_COMPLETE_"+toString(i)+"_PHT_ADDRESS", _name+"_Pattern_History_Table",  "in_BRANCH_COMPLETE_"+toString(i)+"_ADDRESS");
    278295          }
    279296        if (_param._have_bht and _param._have_pht)
     
    282299        _component->port_map(_name+"_Two_Level_Branch_Predictor_Glue", "in_BRANCH_COMPLETE_"+toString(i)+"_ADDRESS"     , _name                         , "in_BRANCH_COMPLETE_"+toString(i)+"_ADDRESS");
    283300      }
    284  
     301    cout << "GEU 4" << endl; 
    285302#ifdef POSITION
    286303    _component->generate_file();
  • trunk/IPs/systemC/processor/Morpheo/Behavioural/Stage_1_Ifetch/Predictor/Meta_Predictor/Two_Level_Branch_Predictor/src/Two_Level_Branch_Predictor_vhdl.cpp

    r42 r43  
    2121  {
    2222    log_printf(FUNC,Two_Level_Branch_Predictor,"vhdl","Begin");
     23
    2324    Vhdl * vhdl = new Vhdl (_name);
    2425
    25     vhdl->set_library_work (_name + "_Pack");
    26     if (_param._have_bht)
    27     vhdl->set_library_work (_name + "_Branch_History_Table_Pack");
    28     if (_param._have_pht)
    29     vhdl->set_library_work (_name + "_Pattern_History_Table_Pack");
    30     vhdl->set_library_work (_name + "_Two_Level_Branch_Predictor_Glue_Pack");
    31    
    32     vhdl_port        (vhdl);
     26    _interfaces->set_port     (vhdl);
     27    _component ->vhdl_instance(vhdl);
     28
    3329    vhdl_declaration (vhdl);
    3430    vhdl_body        (vhdl);
  • trunk/IPs/systemC/processor/Morpheo/Behavioural/Stage_1_Ifetch/Predictor/Meta_Predictor/Two_Level_Branch_Predictor/src/Two_Level_Branch_Predictor_vhdl_body.cpp

    r42 r43  
    2121    log_printf(FUNC,Two_Level_Branch_Predictor,"vhdl_body","Begin");
    2222
    23     list<string> list_port_map;
     23//     list<string> list_port_map;
    2424
    25     if (_param._have_bht)
    26       {
    27         list_port_map.clear();
     25//     if (_param._have_bht)
     26//       {
     27//      list_port_map.clear();
    2828
    29         vhdl.set_body_component_port_map (list_port_map,"in_CLOCK ","in_CLOCK ");
    30         vhdl.set_body_component_port_map (list_port_map,"in_NRESET","in_NRESET");
     29//      vhdl.set_body_component_port_map (list_port_map,"in_CLOCK ","in_CLOCK ");
     30//      vhdl.set_body_component_port_map (list_port_map,"in_NRESET","in_NRESET");
    3131
    32         for (uint32_t i=0; i<_param._nb_prediction; i++)
    33           {
    34             vhdl.set_body_component_port_map (list_port_map," in_PREDICT_VAL_"+toString(i)+"              ","    in_PREDICT_VAL_"+toString(i));
    35             vhdl.set_body_component_port_map (list_port_map,"out_PREDICT_ACK_"+toString(i)+"              ","signal_PREDICT_BHT_ACK_"+toString(i));
    36             vhdl.set_body_component_port_map (list_port_map," in_PREDICT_ADDRESS_"+toString(i)+"          ","signal_PREDICT_BHT_ADDRESS_"+toString(i));
    37             vhdl.set_body_component_port_map (list_port_map,"out_PREDICT_HISTORY_"+toString(i)+"          ","signal_PREDICT_BHT_HISTORY_"+toString(i));
    38           }
     32//      for (uint32_t i=0; i<_param._nb_prediction; i++)
     33//        {
     34//          vhdl.set_body_component_port_map (list_port_map," in_PREDICT_VAL_"+toString(i)+"              ","    in_PREDICT_VAL_"+toString(i));
     35//          vhdl.set_body_component_port_map (list_port_map,"out_PREDICT_ACK_"+toString(i)+"              ","signal_PREDICT_BHT_ACK_"+toString(i));
     36//          vhdl.set_body_component_port_map (list_port_map," in_PREDICT_ADDRESS_"+toString(i)+"          ","signal_PREDICT_BHT_ADDRESS_"+toString(i));
     37//          vhdl.set_body_component_port_map (list_port_map,"out_PREDICT_HISTORY_"+toString(i)+"          ","signal_PREDICT_BHT_HISTORY_"+toString(i));
     38//        }
    3939       
    40         for (uint32_t i=0; i<_param._nb_branch_complete; i++)
    41           {
    42             vhdl.set_body_component_port_map (list_port_map," in_BRANCH_COMPLETE_VAL_"+toString(i)+"      ","    in_BRANCH_COMPLETE_VAL_"+toString(i));
    43             vhdl.set_body_component_port_map (list_port_map,"out_BRANCH_COMPLETE_ACK_"+toString(i)+"      ","signal_BRANCH_COMPLETE_BHT_ACK_"+toString(i));
    44             vhdl.set_body_component_port_map (list_port_map," in_BRANCH_COMPLETE_ADDRESS_"+toString(i)+"  ","signal_BRANCH_COMPLETE_BHT_ADDRESS_"+toString(i));
    45             vhdl.set_body_component_port_map (list_port_map," in_BRANCH_COMPLETE_HISTORY_"+toString(i)+"  ","    in_BRANCH_COMPLETE_BHT_HISTORY_"+toString(i));
    46             vhdl.set_body_component_port_map (list_port_map," in_BRANCH_COMPLETE_DIRECTION_"+toString(i)+"","    in_BRANCH_COMPLETE_DIRECTION_"+toString(i));
    47           }
     40//      for (uint32_t i=0; i<_param._nb_branch_complete; i++)
     41//        {
     42//          vhdl.set_body_component_port_map (list_port_map," in_BRANCH_COMPLETE_VAL_"+toString(i)+"      ","    in_BRANCH_COMPLETE_VAL_"+toString(i));
     43//          vhdl.set_body_component_port_map (list_port_map,"out_BRANCH_COMPLETE_ACK_"+toString(i)+"      ","signal_BRANCH_COMPLETE_BHT_ACK_"+toString(i));
     44//          vhdl.set_body_component_port_map (list_port_map," in_BRANCH_COMPLETE_ADDRESS_"+toString(i)+"  ","signal_BRANCH_COMPLETE_BHT_ADDRESS_"+toString(i));
     45//          vhdl.set_body_component_port_map (list_port_map," in_BRANCH_COMPLETE_HISTORY_"+toString(i)+"  ","    in_BRANCH_COMPLETE_BHT_HISTORY_"+toString(i));
     46//          vhdl.set_body_component_port_map (list_port_map," in_BRANCH_COMPLETE_DIRECTION_"+toString(i)+"","    in_BRANCH_COMPLETE_DIRECTION_"+toString(i));
     47//        }
    4848       
    49         vhdl.set_body_component ("component_Branch_History_Table",_name+"_Branch_History_Table",list_port_map);
    50       }
     49//      vhdl.set_body_component ("component_Branch_History_Table",_name+"_Branch_History_Table",list_port_map);
     50//       }
    5151
    52     if (_param._have_pht)
    53       {
    54         list_port_map.clear();
     52//     if (_param._have_pht)
     53//       {
     54//      list_port_map.clear();
    5555
    56         vhdl.set_body_component_port_map (list_port_map,"in_CLOCK ","in_CLOCK ");
    57         vhdl.set_body_component_port_map (list_port_map,"in_NRESET","in_NRESET");
     56//      vhdl.set_body_component_port_map (list_port_map,"in_CLOCK ","in_CLOCK ");
     57//      vhdl.set_body_component_port_map (list_port_map,"in_NRESET","in_NRESET");
    5858
    59         for (uint32_t i=0; i<_param._nb_prediction; i++)
    60           {
    61             vhdl.set_body_component_port_map (list_port_map," in_PREDICT_VAL_"+toString(i)+"              ","    in_PREDICT_VAL_"+toString(i));
    62             vhdl.set_body_component_port_map (list_port_map,"out_PREDICT_ACK_"+toString(i)+"              ","signal_PREDICT_PHT_ACK_"+toString(i));
    63             vhdl.set_body_component_port_map (list_port_map," in_PREDICT_ADDRESS_"+toString(i)+"          ","signal_PREDICT_PHT_ADDRESS_"+toString(i));
    64             vhdl.set_body_component_port_map (list_port_map,"out_PREDICT_HISTORY_"+toString(i)+"          ","   out_PREDICT_PHT_HISTORY_"+toString(i));
    65           }
     59//      for (uint32_t i=0; i<_param._nb_prediction; i++)
     60//        {
     61//          vhdl.set_body_component_port_map (list_port_map," in_PREDICT_VAL_"+toString(i)+"              ","    in_PREDICT_VAL_"+toString(i));
     62//          vhdl.set_body_component_port_map (list_port_map,"out_PREDICT_ACK_"+toString(i)+"              ","signal_PREDICT_PHT_ACK_"+toString(i));
     63//          vhdl.set_body_component_port_map (list_port_map," in_PREDICT_ADDRESS_"+toString(i)+"          ","signal_PREDICT_PHT_ADDRESS_"+toString(i));
     64//          vhdl.set_body_component_port_map (list_port_map,"out_PREDICT_HISTORY_"+toString(i)+"          ","   out_PREDICT_PHT_HISTORY_"+toString(i));
     65//        }
    6666       
    67         for (uint32_t i=0; i<_param._nb_branch_complete; i++)
    68           {
    69             vhdl.set_body_component_port_map (list_port_map," in_BRANCH_COMPLETE_VAL_"+toString(i)+"      ","    in_BRANCH_COMPLETE_VAL_"+toString(i));
    70             vhdl.set_body_component_port_map (list_port_map,"out_BRANCH_COMPLETE_ACK_"+toString(i)+"      ","signal_BRANCH_COMPLETE_PHT_ACK_"+toString(i));
    71             vhdl.set_body_component_port_map (list_port_map," in_BRANCH_COMPLETE_ADDRESS_"+toString(i)+"  ","signal_BRANCH_COMPLETE_PHT_ADDRESS_"+toString(i));
    72             vhdl.set_body_component_port_map (list_port_map," in_BRANCH_COMPLETE_HISTORY_"+toString(i)+"  ","    in_BRANCH_COMPLETE_PHT_HISTORY_"+toString(i));
    73             vhdl.set_body_component_port_map (list_port_map," in_BRANCH_COMPLETE_DIRECTION_"+toString(i)+"","    in_BRANCH_COMPLETE_DIRECTION_"+toString(i));
    74           }
     67//      for (uint32_t i=0; i<_param._nb_branch_complete; i++)
     68//        {
     69//          vhdl.set_body_component_port_map (list_port_map," in_BRANCH_COMPLETE_VAL_"+toString(i)+"      ","    in_BRANCH_COMPLETE_VAL_"+toString(i));
     70//          vhdl.set_body_component_port_map (list_port_map,"out_BRANCH_COMPLETE_ACK_"+toString(i)+"      ","signal_BRANCH_COMPLETE_PHT_ACK_"+toString(i));
     71//          vhdl.set_body_component_port_map (list_port_map," in_BRANCH_COMPLETE_ADDRESS_"+toString(i)+"  ","signal_BRANCH_COMPLETE_PHT_ADDRESS_"+toString(i));
     72//          vhdl.set_body_component_port_map (list_port_map," in_BRANCH_COMPLETE_HISTORY_"+toString(i)+"  ","    in_BRANCH_COMPLETE_PHT_HISTORY_"+toString(i));
     73//          vhdl.set_body_component_port_map (list_port_map," in_BRANCH_COMPLETE_DIRECTION_"+toString(i)+"","    in_BRANCH_COMPLETE_DIRECTION_"+toString(i));
     74//        }
    7575       
    76         vhdl.set_body_component ("component_Pattern_History_Table",_name+"_Pattern_History_Table",list_port_map);
    77       }
     76//      vhdl.set_body_component ("component_Pattern_History_Table",_name+"_Pattern_History_Table",list_port_map);
     77//       }
    7878
    79     list_port_map.clear();
     79//     list_port_map.clear();
    8080   
    81     for (uint32_t i=0; i<_param._nb_prediction; i++)
    82       {
    83         if (_param._have_bht)
    84           {
    85         vhdl.set_body_component_port_map (list_port_map," in_PREDICT_BHT_ACK_"+toString(i)+"            ","signal_PREDICT_BHT_ACK_"+toString(i));
    86         vhdl.set_body_component_port_map (list_port_map,"out_PREDICT_BHT_ADDRESS_"+toString(i)+"        ","signal_PREDICT_BHT_ADDRESS_"+toString(i));
    87           }                                                                                                                                                                       
    88         if (_param._have_pht)                                                                                                                     
    89           {                                                                                                                                                                       
    90         vhdl.set_body_component_port_map (list_port_map," in_PREDICT_PHT_ACK_"+toString(i)+"            ","signal_PREDICT_PHT_ACK_"+toString(i));
    91         vhdl.set_body_component_port_map (list_port_map,"out_PREDICT_PHT_ADDRESS_"+toString(i)+"        ","signal_PREDICT_PHT_ADDRESS_"+toString(i));
    92           }                                                                                                                                                                       
    93         if (_param._have_bht and _param._have_pht)                                                                                       
    94           {                                                                                                                                                                       
    95         vhdl.set_body_component_port_map (list_port_map," in_PREDICT_BHT_HISTORY_"+toString(i)+"        ","signal_PREDICT_BHT_HISTORY_"+toString(i));
    96           }                                                                                                                                                                       
    97         vhdl.set_body_component_port_map (list_port_map,"out_PREDICT_ACK_"+toString(i)+"                ","   out_PREDICT_ACK_"+toString(i));
    98         vhdl.set_body_component_port_map (list_port_map," in_PREDICT_ADDRESS_"+toString(i)+"            ","    in_PREDICT_ADDRESS_"+toString(i));
    99       }
     81//     for (uint32_t i=0; i<_param._nb_prediction; i++)
     82//       {
     83//      if (_param._have_bht)
     84//        {
     85//      vhdl.set_body_component_port_map (list_port_map," in_PREDICT_BHT_ACK_"+toString(i)+"            ","signal_PREDICT_BHT_ACK_"+toString(i));
     86//      vhdl.set_body_component_port_map (list_port_map,"out_PREDICT_BHT_ADDRESS_"+toString(i)+"        ","signal_PREDICT_BHT_ADDRESS_"+toString(i));
     87//        }                                                                                                                                                                       
     88//      if (_param._have_pht)                                                                                                                     
     89//        {                                                                                                                                                                       
     90//      vhdl.set_body_component_port_map (list_port_map," in_PREDICT_PHT_ACK_"+toString(i)+"            ","signal_PREDICT_PHT_ACK_"+toString(i));
     91//      vhdl.set_body_component_port_map (list_port_map,"out_PREDICT_PHT_ADDRESS_"+toString(i)+"        ","signal_PREDICT_PHT_ADDRESS_"+toString(i));
     92//        }                                                                                                                                                                       
     93//      if (_param._have_bht and _param._have_pht)                                                                                       
     94//        {                                                                                                                                                                       
     95//      vhdl.set_body_component_port_map (list_port_map," in_PREDICT_BHT_HISTORY_"+toString(i)+"        ","signal_PREDICT_BHT_HISTORY_"+toString(i));
     96//        }                                                                                                                                                                       
     97//      vhdl.set_body_component_port_map (list_port_map,"out_PREDICT_ACK_"+toString(i)+"                ","   out_PREDICT_ACK_"+toString(i));
     98//      vhdl.set_body_component_port_map (list_port_map," in_PREDICT_ADDRESS_"+toString(i)+"            ","    in_PREDICT_ADDRESS_"+toString(i));
     99//       }
    100100   
    101     for (uint32_t i=0; i<_param._nb_branch_complete; i++)
    102       {
    103         if (_param._have_bht)
    104           {
    105         vhdl.set_body_component_port_map (list_port_map," in_BRANCH_COMPLETE_BHT_ACK_"+toString(i)+"    ","signal_BRANCH_COMPLETE_BHT_ACK_"+toString(i));
    106         vhdl.set_body_component_port_map (list_port_map,"out_BRANCH_COMPLETE_BHT_ADDRESS_"+toString(i)+"","signal_BRANCH_COMPLETE_BHT_ADDRESS_"+toString(i));
    107           }                                                                                                                                                       
    108         if (_param._have_pht)
    109           {
    110         vhdl.set_body_component_port_map (list_port_map," in_BRANCH_COMPLETE_PHT_ACK_"+toString(i)+"    ","signal_BRANCH_COMPLETE_PHT_ACK_"+toString(i));
    111         vhdl.set_body_component_port_map (list_port_map,"out_BRANCH_COMPLETE_PHT_ADDRESS_"+toString(i)+"","signal_BRANCH_COMPLETE_PHT_ADDRESS_"+toString(i));
    112           }                                                                                                                                                       
    113         if (_param._have_bht and _param._have_pht)
    114           {
    115         vhdl.set_body_component_port_map (list_port_map," in_BRANCH_COMPLETE_BHT_HISTORY_"+toString(i)+"","    in_BRANCH_COMPLETE_BHT_HISTORY_"+toString(i));
    116           }                                                                                                                                                       
    117         vhdl.set_body_component_port_map (list_port_map,"out_BRANCH_COMPLETE_ACK_"+toString(i)+"        ","   out_BRANCH_COMPLETE_ACK_"+toString(i));
    118         vhdl.set_body_component_port_map (list_port_map," in_BRANCH_COMPLETE_ADDRESS_"+toString(i)+"    ","    in_BRANCH_COMPLETE_ADDRESS_"+toString(i));
    119       }
     101//     for (uint32_t i=0; i<_param._nb_branch_complete; i++)
     102//       {
     103//      if (_param._have_bht)
     104//        {
     105//      vhdl.set_body_component_port_map (list_port_map," in_BRANCH_COMPLETE_BHT_ACK_"+toString(i)+"    ","signal_BRANCH_COMPLETE_BHT_ACK_"+toString(i));
     106//      vhdl.set_body_component_port_map (list_port_map,"out_BRANCH_COMPLETE_BHT_ADDRESS_"+toString(i)+"","signal_BRANCH_COMPLETE_BHT_ADDRESS_"+toString(i));
     107//        }                                                                                                                                                       
     108//      if (_param._have_pht)
     109//        {
     110//      vhdl.set_body_component_port_map (list_port_map," in_BRANCH_COMPLETE_PHT_ACK_"+toString(i)+"    ","signal_BRANCH_COMPLETE_PHT_ACK_"+toString(i));
     111//      vhdl.set_body_component_port_map (list_port_map,"out_BRANCH_COMPLETE_PHT_ADDRESS_"+toString(i)+"","signal_BRANCH_COMPLETE_PHT_ADDRESS_"+toString(i));
     112//        }                                                                                                                                                       
     113//      if (_param._have_bht and _param._have_pht)
     114//        {
     115//         vhdl.set_body_component_port_map (list_port_map," in_BRANCH_COMPLETE_BHT_HISTORY_"+toString(i)+"","    in_BRANCH_COMPLETE_BHT_HISTORY_"+toString(i));
     116//        }                                                                                                                                                       
     117//      vhdl.set_body_component_port_map (list_port_map,"out_BRANCH_COMPLETE_ACK_"+toString(i)+"        ","   out_BRANCH_COMPLETE_ACK_"+toString(i));
     118//      vhdl.set_body_component_port_map (list_port_map," in_BRANCH_COMPLETE_ADDRESS_"+toString(i)+"    ","    in_BRANCH_COMPLETE_ADDRESS_"+toString(i));
     119//       }
    120120
    121     vhdl.set_body_component ("component_Two_Level_Branch_Predictor_Glue",_name+"_Two_Level_Branch_Predictor_Glue",list_port_map);
     121//     vhdl.set_body_component ("component_Two_Level_Branch_Predictor_Glue",_name+"_Two_Level_Branch_Predictor_Glue",list_port_map);
    122122
    123     if (_param._have_bht)
    124       for (uint32_t i=0; i<_param._nb_prediction; i++)
    125         vhdl.set_body("out_PREDICT_BHT_HISTORY_"+toString(i)+" <= signal_PREDICT_BHT_HISTORY_"+toString(i)+";");
     123//     if (_param._have_bht)
     124//       for (uint32_t i=0; i<_param._nb_prediction; i++)
     125//      vhdl.set_body("out_PREDICT_BHT_HISTORY_"+toString(i)+" <= signal_PREDICT_BHT_HISTORY_"+toString(i)+";");
    126126   
    127127    log_printf(FUNC,Two_Level_Branch_Predictor,"vhdl_body","End");
Note: See TracChangeset for help on using the changeset viewer.