Ignore:
Timestamp:
Dec 10, 2008, 7:31:39 PM (16 years ago)
Author:
rosiere
Message:

Almost complete design
with Test and test platform

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Multi_Execute_unit/Execute_unit/Load_store_unit/src/Load_store_unit.cpp

    r82 r88  
    3939    log_printf(FUNC,Load_store_unit,FUNCTION,"Begin");
    4040
     41#if DEBUG_Load_store_unit == true
     42    log_printf(INFO,Load_store_unit,FUNCTION,_("<%s> Parameters"),_name.c_str());
     43
     44    std::cout << *param << std::endl;
     45#endif   
     46
    4147#ifdef SYSTEMC
    4248    log_printf(INFO,Load_store_unit,FUNCTION,"Allocation");
     
    4652
    4753#ifdef STATISTICS
    48     log_printf(INFO,Load_store_unit,FUNCTION,"Allocation of statistics");
    49 
    50     statistics_declaration(param_statistics);
     54    if (usage_is_set(_usage,USE_STATISTICS))
     55      {
     56        log_printf(INFO,Load_store_unit,FUNCTION,"Allocation of statistics");
     57       
     58        statistics_declaration(param_statistics);
     59      }
    5160#endif
    5261
    5362#ifdef VHDL
    54     // generate the vhdl
    55     log_printf(INFO,Load_store_unit,FUNCTION,"Generate the vhdl");
    56 
    57     vhdl();
    58 #endif
    59 
    60 #ifdef SYSTEMC
     63    if (usage_is_set(_usage,USE_VHDL))
     64      {
     65        // generate the vhdl
     66        log_printf(INFO,Load_store_unit,FUNCTION,"Generate the vhdl");
     67       
     68        vhdl();
     69      }
     70#endif
     71
     72#ifdef SYSTEMC
     73    if (usage_is_set(_usage,USE_SYSTEMC))
     74      {
    6175    // Function pointer
    6276
     
    8498
    8599    internal_DCACHE_RSP_ACK = 1;
    86     PORT_WRITE(out_DCACHE_RSP_ACK, 1);
     100    PORT_WRITE(out_DCACHE_RSP_ACK [0], internal_DCACHE_RSP_ACK);
     101    for (uint32_t i=1; i<_param->_nb_cache_port; ++i)
     102      {
     103        PORT_WRITE(out_DCACHE_RSP_ACK [i], 0);
     104        PORT_WRITE(out_DCACHE_REQ_VAL [i], 0);
     105      }
     106
     107    for (uint32_t i=1; i<_param->_nb_inst_memory; i++)
     108      {
     109        PORT_WRITE(out_MEMORY_OUT_VAL [i], 0);
     110      }
    87111
    88112    log_printf(INFO,Load_store_unit,FUNCTION,"Method - transition");
     
    111135    dont_initialize ();
    112136    sensitive_neg << *(in_CLOCK);
    113     sensitive     << *(in_MEMORY_IN_OPERATION);
    114 
    115 #ifdef SYSTEMCASS_SPECIFIC
    116     // List dependency information
    117     (*(out_MEMORY_IN_ACK)) (*(in_MEMORY_IN_OPERATION));
     137    for (uint32_t i=0; i<_param->_nb_inst_memory; i++)
     138      sensitive << (*(in_MEMORY_IN_VAL       [i]))
     139                << (*(in_MEMORY_IN_OPERATION [i]));
     140
     141#ifdef SYSTEMCASS_SPECIFIC
     142    // List dependency information
     143    for (uint32_t i=0; i<_param->_nb_inst_memory; i++)
     144//       for (uint32_t x=0; x<_param->_nb_inst_memory; x++)
     145        {
     146          (*(out_MEMORY_IN_ACK [i])) (*(in_MEMORY_IN_VAL       [i]));
     147          (*(out_MEMORY_IN_ACK [i])) (*(in_MEMORY_IN_OPERATION [i]));
     148        }
    118149#endif   
    119150
     
    137168    // List dependency information
    138169#endif   
    139 
     170      }
    140171#endif
    141172    log_printf(FUNC,Load_store_unit,FUNCTION,"End");
     
    149180
    150181#ifdef STATISTICS
    151     log_printf(INFO,Load_store_unit,FUNCTION,"Generate Statistics file");
    152 
    153     delete _stat;
     182    if (usage_is_set(_usage,USE_STATISTICS))
     183      {
     184        log_printf(INFO,Load_store_unit,FUNCTION,"Generate Statistics file");
     185       
     186        delete _stat;
     187      }
    154188#endif
    155189
Note: See TracChangeset for help on using the changeset viewer.