Ignore:
Timestamp:
Jun 26, 2009, 10:43:23 AM (15 years ago)
Author:
rosiere
Message:

1) Correct bug in link two signal
2) Fix error detected with valgrind
3) modif distexe script

Location:
trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/src
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/src/Core_deallocation.cpp

    r123 r128  
    6161    delete _component;
    6262
    63 //     delete    _component_glue;
    64 //     delete    _component_dcache_access;
    65 //     delete    _component_icache_access;
    66 //     for (uint32_t i=0; i<_param->_nb_execute_loop; ++i)
    67 //     delete    _component_execute_loop [i];
    68 //     delete [] _component_execute_loop;
    69 //     for (uint32_t i=0; i<_param->_nb_ooo_engine; ++i)
    70 //     delete    _component_ooo_engine [i];
    71 //     delete [] _component_ooo_engine;
    72 //     for (uint32_t i=0; i<_param->_nb_front_end; ++i)
    73 //     delete    _component_front_end [i];
    74 //     delete [] _component_front_end;
     63    delete    _component_glue;
     64    delete    _component_dcache_access;
     65    delete    _component_icache_access;
     66    for (uint32_t i=0; i<_param->_nb_execute_loop; ++i)
     67    delete    _component_execute_loop [i];
     68    delete [] _component_execute_loop;
     69    for (uint32_t i=0; i<_param->_nb_ooo_engine; ++i)
     70    delete    _component_ooo_engine [i];
     71    delete [] _component_ooo_engine;
     72    for (uint32_t i=0; i<_param->_nb_front_end; ++i)
     73    delete    _component_front_end [i];
     74    delete [] _component_front_end;
    7575
    7676    log_end(Core,FUNCTION);
  • trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/src/Parameters.cpp

    r123 r128  
    394394        _link_thread_with_context [x.first][x.second] = i;
    395395      }
     396
     397//     log_printf(TRACE,Core,FUNCTION,_("  * _link_decod_unit_with_decod_bloc"));
    396398    for (uint32_t i=0; i<_nb_decod_bloc; ++i)
    397399      {
    398400        pair_dual x = _link_decod_unit_with_decod_bloc[i];
    399401        _link_decod_bloc_with_decod_unit [x.first][x.second] = i;
     402//         log_printf(TRACE,Core,FUNCTION,_("    [%d][%d] -> %d"),x.first,x.second,i);
    400403      }
     404
    401405    for (uint32_t i=0; i<_nb_rename_bloc; ++i)
    402406      {
     
    803807    ALLOC2(_front_end_context_select_load_balancing       ,Tload_balancing_t,_nb_front_end,_nb_decod_unit[it1]);
    804808
     809    log_printf(TRACE,Core,FUNCTION,_("  * decod_unit"));
     810
    805811    for (uint32_t i=0; i<_nb_front_end; ++i)
    806812      {
     
    813819          {
    814820            uint32_t num_decod_bloc=_link_decod_bloc_with_decod_unit[i][j];
    815            
     821           
     822            log_printf(TRACE,Core,FUNCTION,_("  [%d][%d] -> %d"),i,j,num_decod_bloc);
     823 
    816824            _front_end_size_decod_queue              [i][j] = _size_decod_queue              [num_decod_bloc];
    817825            _front_end_decod_queue_scheme            [i][j] = _decod_queue_scheme            [num_decod_bloc];
     
    18271835          uint32_t num_load_store_unit = _list_load_store_unit_with_execute_unit [i][j];
    18281836         
    1829           uint32_t num_thread;
    1830           for (num_thread = 0; num_thread<_nb_thread; ++num_thread)
    1831             if (_link_load_store_unit_with_thread [num_thread] == num_load_store_unit)
    1832               break;
    1833          
     1837          {
     1838            uint32_t num_thread;
     1839            for (num_thread = 0; num_thread<_nb_thread; ++num_thread)
     1840              if (_link_load_store_unit_with_thread [num_thread] == num_load_store_unit)
     1841                break;
    18341842#ifdef DEBUG_TEST
    1835           if (num_thread == _nb_thread)
    1836             throw ERRORMORPHEO(FUNCTION,toString(_("Load_store_unit [%d] is not link with a thread.\n"),num_load_store_unit));
     1843            if (num_thread == _nb_thread)
     1844              throw ERRORMORPHEO(FUNCTION,toString(_("Load_store_unit [%d] is not link with a thread.\n"),num_load_store_unit));
    18371845#endif
     1846          }
     1847
    18381848          // init with an invalid thread_id
    18391849          for (uint32_t k=0; k<_dcache_access_nb_context [i]; ++k)
     
    18581868                      uint32_t num_thread = _link_thread_with_context [num_front_end][num_context];
    18591869                     
    1860                       uint32_t index = ((num_ooo_engine<<(_size_context_id + _size_front_end_id )) |
    1861                                         (num_front_end <<(_size_context_id)) |
    1862                                         (num_context));
    1863                      
    1864                       _dcache_access_translate_load_store_unit_to_thread [i][j][index] = num_thread;
     1870                      if (_link_load_store_unit_with_thread [num_thread] == num_load_store_unit)
     1871                        {
     1872                          uint32_t index = ((num_ooo_engine<<(_size_context_id + _size_front_end_id )) |
     1873                                            (num_front_end <<(_size_context_id)) |
     1874                                            (num_context));
     1875                         
     1876                          _dcache_access_translate_load_store_unit_to_thread [i][j][index] = num_thread;
     1877                        }
    18651878                    }
    18661879                }
     
    19601973        _nb_thread                                 ,
    19611974        _link_thread_with_context               [i]
    1962         );
     1975         );
    19631976
    19641977    ALLOC1(_nb_inst_issue_queue,uint32_t,_nb_ooo_engine);
     
    21812194    log_begin(Core,FUNCTION);
    21822195
    2183 //     for (uint32_t i=0; i<_nb_front_end; ++i)
    2184 //     delete    _param_front_end [i];
    2185 //     delete [] _param_front_end;
    2186 //     for (uint32_t i=0; i<_nb_ooo_engine; ++i)
    2187 //     delete    _param_ooo_engine [i];
    2188 //     delete [] _param_ooo_engine;
    2189 //     for (uint32_t i=0; i<_nb_execute_loop; ++i)
    2190 //     delete    _param_execute_loop [i];
    2191 //     delete [] _param_execute_loop;
    2192 //     delete    _param_icache_access;
    2193 //     delete    _param_dcache_access;
    2194 //     delete    _param_glue;
    2195 
     2196    for (uint32_t i=0; i<_nb_front_end; ++i)
     2197    delete    _param_front_end [i];
     2198    delete [] _param_front_end;
     2199    for (uint32_t i=0; i<_nb_ooo_engine; ++i)
     2200    delete    _param_ooo_engine [i];
     2201    delete [] _param_ooo_engine;
     2202    for (uint32_t i=0; i<_nb_execute_loop; ++i)
     2203    delete    _param_execute_loop [i];
     2204    delete [] _param_execute_loop;
     2205    delete    _param_icache_access;
     2206    delete    _param_dcache_access;
     2207    delete    _param_glue;
     2208
     2209    DELETE1(_nb_inst_issue_queue                                    ,_nb_ooo_engine);
     2210    DELETE1(_issue_queue_in_order                                   ,_nb_ooo_engine);
    21962211    DELETE3(_dcache_access_translate_load_store_unit_to_thread      ,_nb_execute_loop,_execute_loop_nb_load_store_unit[it1],_dcache_access_nb_context[it1]);
    21972212    DELETE1(_dcache_access_nb_context                               ,_nb_execute_loop);
  • trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/src/Parameters_msg_error.cpp

    r117 r128  
    5959      // set link
    6060      for (uint32_t i=0; i<_nb_decod_bloc; ++i)
    61         nb_link_decod_unit[_link_decod_unit_with_decod_bloc[i].first][_link_decod_unit_with_decod_bloc[i].second] ++;
    62 
     61        {
     62          uint32_t num_front_end  = _link_decod_unit_with_decod_bloc[i].first;
     63          uint32_t num_decod_unit = _link_decod_unit_with_decod_bloc[i].second;
     64
     65          bool error = false;
     66
     67          if (num_front_end >= _nb_front_end)
     68            {
     69              error = true;
     70              test.error(toString(_("Decod_bloc [%d] is connected with an invalid front_end (%d).\n"),i,num_front_end));
     71            }
     72
     73          if (num_decod_unit >= _nb_decod_unit[num_front_end])
     74            {
     75              error = true;
     76              test.error(toString(_("Decod_bloc [%d] is connected with an invalid decod_unit (%d.%d).\n"),i,num_front_end,num_decod_unit));
     77            }
     78
     79          if (not error)
     80            nb_link_decod_unit[num_front_end][num_decod_unit] ++;
     81        }
    6382      // test
    6483      for (uint32_t i=0; i<_nb_front_end; ++i)
Note: See TracChangeset for help on using the changeset viewer.