Changeset 112 for trunk/IPs/systemC/processor/Morpheo/Behavioural/include
- Timestamp:
- Mar 18, 2009, 11:36:26 PM (16 years ago)
- Location:
- trunk/IPs/systemC/processor/Morpheo/Behavioural/include
- Files:
-
- 1 added
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/IPs/systemC/processor/Morpheo/Behavioural/include/Allocation.h
r111 r112 14 14 // =====[ ALLOCATION / DELETE of ARRAY ]================================= 15 15 // ====================================================================== 16 #define ALLOC0(var,type) \ 17 var = new type 18 16 19 #define ALLOC1(var,type,s1) \ 17 20 var = new type [s1] … … 103 106 // ---------------------------------------------------------------------- 104 107 105 #define __ALLOC_SIGNAL(sig, name, type) \ 108 109 #define __ALLOC0_SIGNAL(sig, name, type) \ 106 110 { \ 107 111 sig = new type (name); \ … … 109 113 110 114 #ifdef POSITION 111 #define ALLOC _INTERFACE( name, direction, localisation, str) \115 #define ALLOC0_INTERFACE_BEGIN( name, direction, localisation, str) \ 112 116 INTERFACE_PRINT(name); \ 113 117 morpheo::behavioural::Interface_fifo * interface = _interfaces->set_interface( name, direction, localisation, str); 114 118 #else 115 #define ALLOC _INTERFACE( name, direction, localisation, str) \119 #define ALLOC0_INTERFACE_BEGIN( name, direction, localisation, str) \ 116 120 INTERFACE_PRINT(name); \ 117 121 morpheo::behavioural::Interface_fifo * interface = _interfaces->set_interface( name); 118 122 #endif 119 123 120 #define ALLOC_VAL_ACK_IN( sig, name, type) \ 124 #define ALLOC0_INTERFACE_END() 125 126 #define ALLOC0_VAL_ACK_IN( sig, name, type) \ 121 127 { \ 122 128 sig = interface->set_signal_valack_in (name, type); \ 123 129 } 124 #define ALLOC _VAL_ACK_OUT( sig, name, type) \130 #define ALLOC0_VAL_ACK_OUT( sig, name, type) \ 125 131 { \ 126 132 sig = interface->set_signal_valack_out(name, type); \ 127 133 } 128 #define ALLOC _VALACK_IN( sig, type) \134 #define ALLOC0_VALACK_IN( sig, type) \ 129 135 { \ 130 136 sig = interface->set_signal_valack_in (type); \ 131 137 } 132 #define ALLOC _VALACK_OUT( sig, type) \138 #define ALLOC0_VALACK_OUT( sig, type) \ 133 139 { \ 134 140 sig = interface->set_signal_valack_out(type); \ 135 141 } 136 #define ALLOC _SIGNAL_IN( sig, name, type, size) \142 #define ALLOC0_SIGNAL_IN( sig, name, type, size) \ 137 143 if (size > 0) \ 138 144 { \ … … 144 150 } 145 151 146 #define ALLOC _SIGNAL_OUT( sig, name, type, size) \152 #define ALLOC0_SIGNAL_OUT( sig, name, type, size) \ 147 153 if (size > 0) \ 148 154 { \ … … 154 160 } 155 161 156 #define DELETE _SIGNAL( sig, size) \162 #define DELETE0_SIGNAL( sig, size) \ 157 163 if (size > 0) \ 158 164 { \ … … 160 166 } 161 167 162 #define ALLOC _SC_SIGNAL( sig, name, type) \168 #define ALLOC0_SC_SIGNAL( sig, name, type) \ 163 169 sc_signal<type> * sig = new sc_signal<type> (name); \ 164 170 PRINT_SIGNAL_ADDRESS(name,sig); 165 171 166 #define INSTANCE _SC_SIGNAL(component, sig) \172 #define INSTANCE0_SC_SIGNAL(component, sig) \ 167 173 { \ 168 174 TEST_SIGNAL(component->sig->name(),component->sig); \ … … 171 177 } 172 178 173 #define _INSTANCE _SC_SIGNAL(component, sig1,sig2) \179 #define _INSTANCE0_SC_SIGNAL(component, sig1,sig2) \ 174 180 { \ 175 181 TEST_SIGNAL(component->sig1->name(),component->sig1); \ … … 178 184 } 179 185 180 #define DELETE _SC_SIGNAL( sig) \186 #define DELETE0_SC_SIGNAL( sig) \ 181 187 { \ 182 188 delete sig; \ 183 189 } 184 185 186 #define __ALLOC0_SIGNAL(sig, name, type) __ALLOC_SIGNAL(sig, name, type)187 188 #define ALLOC0_INTERFACE( name, direction, localisation, str) ALLOC_INTERFACE( name, direction, localisation, str)189 190 #define ALLOC0_VAL_ACK_IN( sig, name, type) ALLOC_VAL_ACK_IN( sig, name, type)191 #define ALLOC0_VAL_ACK_OUT( sig, name, type) ALLOC_VAL_ACK_OUT( sig, name, type)192 #define ALLOC0_VALACK_IN( sig, type) ALLOC_VALACK_IN( sig, type)193 #define ALLOC0_VALACK_OUT( sig, type) ALLOC_VALACK_OUT( sig, type)194 #define ALLOC0_SIGNAL_IN( sig, name, type, size) ALLOC_SIGNAL_IN( sig, name, type, size)195 #define ALLOC0_SIGNAL_OUT( sig, name, type, size) ALLOC_SIGNAL_OUT( sig, name, type, size)196 #define DELETE0_SIGNAL( sig, size) DELETE_SIGNAL( sig, size)197 198 #define ALLOC0_SC_SIGNAL( sig, name, type) ALLOC_SC_SIGNAL( sig, name, type)199 #define INSTANCE0_SC_SIGNAL(component, sig) INSTANCE_SC_SIGNAL(component, sig)200 #define _INSTANCE0_SC_SIGNAL(component, sig) _INSTANCE_SC_SIGNAL(component, sig)201 #define DELETE0_SC_SIGNAL( sig) DELETE_SC_SIGNAL( sig)202 190 203 191 // ---------------------------------------------------------------------- … … 205 193 // ---------------------------------------------------------------------- 206 194 207 #define __ALLOC1_INTERFACE (name, x1) \195 #define __ALLOC1_INTERFACE_BEGIN(name, x1) \ 208 196 INTERFACE_PRINT(name); \ 209 197 const std::string interface_name = name; \ 210 198 const uint32_t iterator_1 = x1; 211 199 200 #define __ALLOC1_INTERFACE_END(x1) 201 212 202 #define __ALLOC1_SIGNAL_IN( sig, name, type) \ 213 203 { \ … … 233 223 234 224 #ifdef POSITION 235 #define ALLOC1_INTERFACE ( name, direction, localisation, str, x1) \225 #define ALLOC1_INTERFACE_BEGIN( name, direction, localisation, str, x1) \ 236 226 INTERFACE_PRINT(name); \ 237 227 const uint32_t iterator_1 = x1; \ … … 245 235 } 246 236 #else 247 #define ALLOC1_INTERFACE ( name, direction, localisation, str, x1) \237 #define ALLOC1_INTERFACE_BEGIN( name, direction, localisation, str, x1) \ 248 238 INTERFACE_PRINT(name); \ 249 239 const uint32_t iterator_1 = x1; \ … … 257 247 } 258 248 #endif 249 250 #define ALLOC1_INTERFACE_END(x1) 259 251 260 252 #define ALLOC1_VAL_ACK_IN( sig, name, type) \ … … 377 369 378 370 #ifdef POSITION 379 #define ALLOC2_INTERFACE ( name, direction, localisation, str, x1, x2) \371 #define ALLOC2_INTERFACE_BEGIN( name, direction, localisation, str, x1, x2) \ 380 372 INTERFACE_PRINT(name); \ 381 373 uint32_t iterator_1 = 0; \ … … 397 389 } 398 390 #else 399 #define ALLOC2_INTERFACE ( name, direction, localisation, str, x1, x2) \391 #define ALLOC2_INTERFACE_BEGIN( name, direction, localisation, str, x1, x2) \ 400 392 INTERFACE_PRINT(name); \ 401 393 uint32_t iterator_1 = 0; \ … … 417 409 } 418 410 #endif 411 412 #define ALLOC2_INTERFACE_END(x1, x2) \ 413 for (uint32_t it1=0; it1<x1; it1++) \ 414 delete interface [it1]; \ 415 delete [] interface; 419 416 420 417 #define _ALLOC2_VAL_ACK_IN( sig, name, type, x1, x2) \ … … 586 583 587 584 #ifdef POSITION 588 #define ALLOC3_INTERFACE ( name, direction, localisation, str, x1, x2, x3) \585 #define ALLOC3_INTERFACE_BEGIN( name, direction, localisation, str, x1, x2, x3) \ 589 586 INTERFACE_PRINT(name); \ 590 587 uint32_t iterator_1 = 0; \ … … 612 609 } 613 610 #else 614 #define ALLOC3_INTERFACE ( name, direction, localisation, str, x1, x2, x3) \611 #define ALLOC3_INTERFACE_BEGIN( name, direction, localisation, str, x1, x2, x3) \ 615 612 INTERFACE_PRINT(name); \ 616 613 uint32_t iterator_1 = 0; \ … … 638 635 } 639 636 #endif 637 638 #define ALLOC3_INTERFACE_END(x1, x2, x3) \ 639 for (uint32_t it1=0; it1<x1; it1++) \ 640 { \ 641 for (uint32_t it2=0; it2<x2; it2++) \ 642 delete interface [it1][it2]; \ 643 delete [] interface [it1]; \ 644 } \ 645 delete [] interface; 640 646 641 647 // #define _ALLOC3_VAL_ACK_IN( sig, name, type, x1, x2, x3) -
trunk/IPs/systemC/processor/Morpheo/Behavioural/include/Debug_component.h
r88 r112 11 11 # define DEBUG_Configuration true 12 12 # define DEBUG_Generic true 13 # define DEBUG_Comparator true 13 14 # define DEBUG_Counter true 15 # define DEBUG_Divider true 16 # define DEBUG_Multiplier true 14 17 # define DEBUG_Priority true 15 18 # define DEBUG_Queue true -
trunk/IPs/systemC/processor/Morpheo/Behavioural/include/SPR_access_mode.h
r88 r112 32 32 public : ~SPR_access_mode(); 33 33 34 public : spr_address_t translate_address (Tgeneral_data_t address);34 public : spr_address_t translate_address (Tgeneral_data_t address); 35 35 36 public : bool valid (uint32_t num_group, uint32_t num_reg); 37 public : bool valid (spr_address_t address); 38 public : bool exist (uint32_t num_group, uint32_t num_reg); 39 public : bool exist (spr_address_t address); 40 public : bool read (spr_address_t address, Tcontrol_t SM, Tcontrol_t SUMRA); 41 public : bool write (spr_address_t address, Tcontrol_t SM, Tcontrol_t SUMRA); 42 43 public : void implement_group (uint32_t num_group, uint32_t nb_reg); 44 public : uint32_t implement_group (uint32_t num_group); 45 public : void change_mode (uint32_t num_group, uint32_t num_reg, spr_access_mode_t new_mode); 46 public : void invalid_register(uint32_t num_group, uint32_t num_reg); 47 36 public : bool valid (uint32_t num_group, uint32_t num_reg); 37 public : bool valid (spr_address_t address); 38 public : bool exist (uint32_t num_group, uint32_t num_reg); 39 public : bool exist (spr_address_t address); 40 public : bool read (spr_address_t address, Tcontrol_t SM, Tcontrol_t SUMRA); 41 public : bool write (spr_address_t address, Tcontrol_t SM, Tcontrol_t SUMRA); 42 public : spr_access_mode_t get_mode (uint32_t num_group, uint32_t num_reg); 43 public : spr_access_mode_t get_mode (spr_address_t address); 44 45 public : void implement_group (uint32_t num_group, uint32_t nb_reg); 46 public : uint32_t implement_group (uint32_t num_group); 47 public : void change_mode (uint32_t num_group, uint32_t num_reg, spr_access_mode_t new_mode); 48 public : void invalid_register(uint32_t num_group, uint32_t num_reg); 48 49 }; 49 50 -
trunk/IPs/systemC/processor/Morpheo/Behavioural/include/Simulation.h
r110 r112 11 11 12 12 #include "Common/include/Debug.h" 13 13 #include "Behavioural/include/Model.h" 14 14 #include <stdint.h> 15 15 #include <systemc.h> … … 22 22 extern double _simulation_nb_instruction; 23 23 extern std::vector<double> _simulation_nb_instruction_commited; 24 extern Model _model; 24 25 25 26 bool simulation_test_end (void); -
trunk/IPs/systemC/processor/Morpheo/Behavioural/include/Version.h
r111 r112 10 10 #define MORPHEO_MAJOR_VERSION "0" 11 11 #define MORPHEO_MINOR_VERSION "2" 12 #define MORPHEO_REVISION "11 1"12 #define MORPHEO_REVISION "112" 13 13 #define MORPHEO_CODENAME "Castor" 14 14 15 #define MORPHEO_DATE_DAY " 27"16 #define MORPHEO_DATE_MONTH "0 2"15 #define MORPHEO_DATE_DAY "18" 16 #define MORPHEO_DATE_MONTH "03" 17 17 #define MORPHEO_DATE_YEAR "2009" 18 18
Note: See TracChangeset
for help on using the changeset viewer.