- Timestamp:
- May 1, 2008, 6:48:45 PM (16 years ago)
- Location:
- trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Victim
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Victim/SelfTest/src/test.cpp
r81 r82 7 7 */ 8 8 9 #define NB_ITERATION 10 10 #define CYCLE_MAX (128*NB_ITERATION) 11 9 12 #include "Behavioural/Generic/Victim/SelfTest/include/test.h" 10 13 #include "Common/include/Test.h" 11 14 #include "Behavioural/include/Allocation.h" 12 13 #define NB_ITERATION 1014 #define CYCLE_MAX (128*NB_ITERATION)15 16 #define LABEL(str...) \17 { \18 msg (_("{%d} "),static_cast<uint32_t>(sc_simulation_time())); \19 msg (str); \20 msg (_("\n")); \21 } while(0)22 23 #define SC_START(cycle_offset) \24 do \25 { \26 /*cout << "SC_START (begin)" << endl;*/ \27 \28 uint32_t cycle_current = static_cast<uint32_t>(sc_simulation_time()); \29 if (cycle_offset != 0) \30 { \31 cout << "##########[ cycle "<< cycle_current+cycle_offset << " ]" << endl; \32 } \33 \34 if (cycle_current > CYCLE_MAX) \35 { \36 TEST_KO("Maximal cycles Reached"); \37 } \38 \39 sc_start(cycle_offset); \40 \41 /*cout << "SC_START (end )" << endl;*/ \42 } while(0)43 15 44 16 void test (string name, … … 53 25 Victim * _Victim = new Victim (name.c_str(), 54 26 #ifdef STATISTICS 55 27 _parameters_statistics, 56 28 #endif 57 _param); 29 _param, 30 USE_ALL); 58 31 59 32 #ifdef SYSTEMC -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Victim/Victim_Pseudo_LRU/SelfTest/src/test.cpp
r81 r82 7 7 */ 8 8 9 #define NB_ITERATION 1 10 #define CYCLE_MAX (128*NB_ITERATION) 11 9 12 #include "Behavioural/Generic/Victim/Victim_Pseudo_LRU/SelfTest/include/test.h" 10 13 #include "Common/include/Test.h" … … 39 42 param_stat, 40 43 #endif 41 ¶m); 44 ¶m, 45 USE_ALL); 42 46 43 47 #ifdef SYSTEMC -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Victim/Victim_Pseudo_LRU/include/Victim_Pseudo_LRU.h
r81 r82 41 41 #endif 42 42 #include "Behavioural/include/Component.h" 43 #include "Behavioural/include/Usage.h" 43 44 44 45 namespace morpheo { … … 55 56 // -----[ fields ]---------------------------------------------------- 56 57 // Parameters 57 protected : const std::string _name; 58 protected : const std::string _name; 59 protected : const Parameters * _param; 60 private : const Tusage_t _usage; 58 61 59 protected : const Parameters * _param;60 62 #ifdef STATISTICS 61 63 public : Stat * _stat; … … 104 106 morpheo::behavioural::Parameters_Statistics * param_statistics, 105 107 #endif 106 Parameters * param ); 108 Parameters * param , 109 morpheo::behavioural::Tusage_t usage); 107 110 108 111 public : Victim_Pseudo_LRU (Parameters param ); -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Victim/Victim_Pseudo_LRU/src/Victim_Pseudo_LRU.cpp
r81 r82 14 14 namespace victim_pseudo_lru { 15 15 16 Victim_Pseudo_LRU::Victim_Pseudo_LRU 17 ( 16 18 #ifdef SYSTEMC 17 Victim_Pseudo_LRU::Victim_Pseudo_LRU (sc_module_name name,19 sc_module_name name, 18 20 #else 19 Victim_Pseudo_LRU::Victim_Pseudo_LRU (std::string name,21 std::string name, 20 22 #endif 21 23 #ifdef STATISTICS 22 24 morpheo::behavioural::Parameters_Statistics * param_statistics, 23 25 #endif 24 morpheo::behavioural::generic::victim::victim_pseudo_lru::Parameters * param ): 25 _name (name) 26 ,_param (param) 26 morpheo::behavioural::generic::victim::victim_pseudo_lru::Parameters * param , 27 morpheo::behavioural::Tusage_t usage): 28 _name (name) 29 ,_param (param) 30 ,_usage (usage) 27 31 { 28 32 log_printf(FUNC,Victim_Pseudo_LRU,"Victim_Pseudo_LRU","Begin"); -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Victim/Victim_Pseudo_LRU/src/Victim_Pseudo_LRU_allocation.cpp
r81 r82 18 18 void Victim_Pseudo_LRU::allocation (void) 19 19 { 20 _component = new Component ( );20 _component = new Component (_usage); 21 21 22 22 Entity * entity = _component->set_entity (_name -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Victim/include/Types.h
r81 r82 16 16 namespace victim { 17 17 18 typedef uint32_t Taddress_t;18 // typedef uint32_t Taddress_t; 19 19 typedef uint32_t Tentity_t; 20 20 -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Victim/include/Victim.h
r81 r82 102 102 #endif 103 103 Parameters * param, 104 morpheo::behavioural::Tusage_t usage =USE_ALL104 morpheo::behavioural::Tusage_t usage 105 105 ); 106 106 public : ~Victim (void); -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Victim/src/Victim_allocation.cpp
r81 r82 65 65 ,param_statistics 66 66 #endif 67 ,_param->_param_victim_pseudo_lru); 67 ,_param->_param_victim_pseudo_lru 68 ,_usage); 68 69 break; 69 70 }
Note: See TracChangeset
for help on using the changeset viewer.