Changeset 75 for trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit
- Timestamp:
- Jan 31, 2008, 6:46:41 PM (16 years ago)
- Location:
- trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit
- Files:
-
- 12 deleted
- 15 edited
- 4 moved
Legend:
- Unmodified
- Added
- Removed
-
trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/Makefile.deps
r74 r75 42 42 #-----[ Rules ]-------------------------------------------- 43 43 44 #.NOTPARALLEL : Register_unit_library Register_unit_library_clean44 .NOTPARALLEL : Register_unit_library Register_unit_library_clean 45 45 46 46 Register_unit_library : $(Register_unit_DEPENDENCIES) -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/Register_unit_Glue/include/Parameters.h
r60 r75 50 50 public : ~Parameters () ; 51 51 52 public : string msg_error(void);52 public : std::string msg_error (void); 53 53 54 public : st ring print (uint32_t depth);55 public : friend ostream& operator<< (ostream& output_stream,56 54 public : std::string print (uint32_t depth); 55 public : friend std::ostream& operator<< (std::ostream& output_stream, 56 morpheo::behavioural::core::multi_execute_loop::execute_loop::register_unit::register_unit_glue::Parameters & x); 57 57 }; 58 58 -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/Register_unit_Glue/include/Register_unit_Glue.h
r61 r75 20 20 #include "Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/Register_unit_Glue/include/Parameters.h" 21 21 #ifdef STATISTICS 22 #include "Behavioural/ Core/Multi_Execute_loop/Execute_loop/Register_unit/Register_unit_Glue/include/Statistics.h"22 #include "Behavioural/include/Stat.h" 23 23 #endif 24 24 #include "Behavioural/include/Component.h" … … 27 27 #endif 28 28 #include "Behavioural/include/Usage.h" 29 30 using namespace std;31 29 32 30 namespace morpheo { … … 47 45 // -----[ fields ]---------------------------------------------------- 48 46 // Parameters 49 protected : const st ring _name;47 protected : const std::string _name; 50 48 protected : const Parameters * _param; 51 49 private : const Tusage_t _usage; 52 50 53 //#ifdef STATISTICS 54 // protected : const morpheo::behavioural::Parameters_Statistics * _param_statistics; 55 //#endif 56 57 #ifdef STATISTICS 58 private : Statistics * _stat; 51 #ifdef STATISTICS 52 public : Stat * _stat; 59 53 #endif 60 54 … … 169 163 sc_module_name name, 170 164 #else 171 st ring name,165 std::string name, 172 166 #endif 173 167 #ifdef STATISTICS … … 183 177 184 178 #ifdef SYSTEMC 185 //#if defined(STATISTICS) or defined(VHDL_TESTBENCH)186 179 public : void transition (void); 187 180 public : void genMealy_gpr_read (void); … … 199 192 public : void genMealy_insert (void); 200 193 public : void genMealy_retire (void); 201 202 //#endif203 194 #endif 204 #ifdef STATISTICS 205 public : string statistics (uint32_t depth); 195 196 #ifdef STATISTICS 197 public : void statistics_declaration (morpheo::behavioural::Parameters_Statistics * param_statistics); 206 198 #endif 207 199 … … 212 204 #endif 213 205 214 #if def VHDL_TESTBENCH215 private : void vhdl_testbench_transition(void);206 #if defined(STATISTICS) or defined(VHDL_TESTBENCH) 207 private : void end_cycle (void); 216 208 #endif 217 209 }; -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/Register_unit_Glue/src/Parameters_msg_error.cpp
r60 r75 9 9 #include "Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/Register_unit_Glue/include/Parameters.h" 10 10 #include <sstream> 11 using namespace std;12 11 13 12 namespace morpheo { … … 22 21 #undef FUNCTION 23 22 #define FUNCTION "Register_unit_Glue::msg_error" 24 st ring Parameters::msg_error(void)23 std::string Parameters::msg_error(void) 25 24 { 26 25 log_printf(FUNC,Register_unit_Glue,FUNCTION,"Begin"); 27 26 28 st ring msg = "";27 std::string msg = ""; 29 28 30 29 return msg; -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/Register_unit_Glue/src/Parameters_print.cpp
r60 r75 8 8 #include "Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/Register_unit_Glue/include/Parameters.h" 9 9 #include "Behavioural/include/XML.h" 10 using namespace std;11 10 12 11 namespace morpheo { … … 21 20 #undef FUNCTION 22 21 #define FUNCTION "Register_unit_Glue::print" 23 st ring Parameters::print (uint32_t depth)22 std::string Parameters::print (uint32_t depth) 24 23 { 25 24 log_printf(FUNC,Register_unit_Glue,FUNCTION,"Begin"); … … 56 55 #undef FUNCTION 57 56 #define FUNCTION "Register_unit_Glue::operator<<" 58 ostream& operator<< (ostream& output_stream ,59 57 std::ostream& operator<< (std::ostream& output_stream , 58 morpheo::behavioural::core::multi_execute_loop::execute_loop::register_unit::register_unit_glue::Parameters & x) 60 59 { 61 60 log_printf(FUNC,Register_unit_Glue,FUNCTION,"Begin"); -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/Register_unit_Glue/src/Register_unit_Glue.cpp
r61 r75 24 24 sc_module_name name, 25 25 #else 26 st ring name,26 std::string name, 27 27 #endif 28 28 #ifdef STATISTICS … … 35 35 ,_param (param) 36 36 ,_usage (usage) 37 // #ifdef STATISTICS38 // ,_param_statistics (param_statistics)39 // #endif40 37 { 41 38 log_printf(FUNC,Register_unit_Glue,FUNCTION,"Begin"); … … 48 45 49 46 // Allocation of statistics 50 _stat = new Statistics (static_cast<string>(_name), 51 param_statistics , 52 param); 47 statistics_declaration(param_statistics); 53 48 #endif 54 49 … … 549 544 log_printf(INFO,Register_unit_Glue,FUNCTION,"Generate Statistics file"); 550 545 551 _stat->generate_file(statistics(0));552 546 delete _stat; 553 547 #endif -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/Register_unit_Glue/src/Register_unit_Glue_allocation.cpp
r60 r75 22 22 void Register_unit_Glue::allocation (void) 23 23 { 24 string rename;25 26 24 log_printf(FUNC,Register_unit_Glue,FUNCTION,"Begin"); 27 25 -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/Register_unit_Glue/src/Register_unit_Glue_end_cycle.cpp
r60 r75 1 #if def VHDL_TESTBENCH1 #if defined(STATISTICS) or defined(VHDL_TESTBENCH) 2 2 /* 3 3 * $Id$ … … 17 17 namespace register_unit_glue { 18 18 19 20 19 #undef FUNCTION 21 #define FUNCTION "Register_unit_Glue:: vhdl_testbench_transition"22 void Register_unit_Glue::vhdl_testbench_transition()20 #define FUNCTION "Register_unit_Glue::end_cycle" 21 void Register_unit_Glue::end_cycle () 23 22 { 24 23 log_printf(FUNC,Register_unit_Glue,FUNCTION,"Begin"); 25 24 25 #ifdef STATISTICS 26 _stat->end_cycle(); 27 #endif 28 29 #ifdef VHDL_TESTBENCH 26 30 // Evaluation before read the ouput signal 27 // sc_start(0); 28 31 // sc_start(0); 29 32 _interfaces->testbench(); 33 #endif 30 34 31 35 log_printf(FUNC,Register_unit_Glue,FUNCTION,"End"); -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/Register_unit_Glue/src/Register_unit_Glue_statistics_declaration.cpp
r60 r75 17 17 namespace register_unit_glue { 18 18 19 20 19 #undef FUNCTION 21 #define FUNCTION "Register_unit_Glue::statistics "22 string Register_unit_Glue::statistics (uint32_t depth)20 #define FUNCTION "Register_unit_Glue::statistics_declaration" 21 void Register_unit_Glue::statistics_declaration (morpheo::behavioural::Parameters_Statistics * param_statistics) 23 22 { 24 23 log_printf(FUNC,Register_unit_Glue,FUNCTION,"Begin"); 25 24 26 string txt = _stat->print(depth); 25 _stat = new Stat (static_cast<std::string>(_name), 26 "Register_unit_Glue", 27 param_statistics); 27 28 28 29 log_printf(FUNC,Register_unit_Glue,FUNCTION,"End"); 29 30 return txt;31 30 }; 32 31 -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/Register_unit_Glue/src/Register_unit_Glue_transition.cpp
r60 r75 1 1 #ifdef SYSTEMC 2 //#if defined(STATISTICS) or defined(VHDL_TESTBENCH)3 2 /* 4 3 * $Id$ … … 25 24 log_printf(FUNC,Register_unit_Glue,FUNCTION,"Begin"); 26 25 27 #ifdef STATISTICS 28 _stat->add(); 29 #endif 30 31 #ifdef VHDL_TESTBENCH 32 vhdl_testbench_transition (); 26 #if defined(STATISTICS) or defined(VHDL_TESTBENCH) 27 end_cycle(); 33 28 #endif 34 29 … … 45 40 }; // end namespace morpheo 46 41 #endif 47 //#endif -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/include/Parameters.h
r60 r75 79 79 public : ~Parameters () ; 80 80 81 public : string msg_error (void); 82 83 public : string print (uint32_t depth); 84 public : friend ostream& operator<< (ostream& output_stream, 85 morpheo::behavioural::core::multi_execute_loop::execute_loop::register_unit::Parameters & x); 81 public : std::string msg_error (void); 82 public : std::string print (uint32_t depth); 83 public : friend std::ostream& operator<< (std::ostream& output_stream, 84 morpheo::behavioural::core::multi_execute_loop::execute_loop::register_unit::Parameters & x); 86 85 }; 87 86 -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/include/Register_unit.h
r60 r75 24 24 #include "Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/include/Parameters.h" 25 25 #ifdef STATISTICS 26 #include "Behavioural/ Core/Multi_Execute_loop/Execute_loop/Register_unit/include/Statistics.h"26 #include "Behavioural/include/Stat.h" 27 27 #endif 28 28 #include "Behavioural/include/Component.h" … … 32 32 #include "Behavioural/include/Usage.h" 33 33 34 using namespace std;35 36 34 namespace morpheo { 37 35 namespace behavioural { 38 39 36 namespace core { 40 37 namespace multi_execute_loop { … … 50 47 // -----[ fields ]---------------------------------------------------- 51 48 // Parameters 52 protected : const st ring _name;49 protected : const std::string _name; 53 50 protected : const Parameters * _param; 54 51 private : const Tusage_t _usage; 55 52 56 53 #ifdef STATISTICS 57 protected : morpheo::behavioural::Parameters_Statistics * _param_statistics; 58 #endif 59 60 #ifdef STATISTICS 61 private : Statistics * _stat; 54 public : Stat * _stat; 62 55 #endif 63 56 … … 143 136 sc_module_name name, 144 137 #else 145 st ring name,138 std::string name, 146 139 #endif 147 140 #ifdef STATISTICS … … 153 146 public : ~Register_unit (void); 154 147 155 private : void allocation (void); 148 private : void allocation ( 149 #ifdef STATISTICS 150 morpheo::behavioural::Parameters_Statistics * param_statistics 151 #else 152 void 153 #endif 154 ); 156 155 private : void deallocation (void); 157 156 … … 161 160 //#endif 162 161 #endif 163 #ifdef STATISTICS164 public : string statistics (uint32_t depth);165 #endif166 162 167 163 #if VHDL … … 171 167 #endif 172 168 173 #ifdef VHDL_TESTBENCH 174 private : void vhdl_testbench_transition (void); 169 #ifdef STATISTICS 170 public : void statistics_declaration (morpheo::behavioural::Parameters_Statistics * param_statistics); 171 #endif 172 #if defined(STATISTICS) or defined(VHDL_TESTBENCH) 173 private : void end_cycle (void); 175 174 #endif 176 175 }; 176 177 177 178 178 }; // end namespace register_unit -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/src/Parameters_msg_error.cpp
r60 r75 6 6 */ 7 7 8 #include "Behavioural/include/Types.h"9 8 #include "Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/include/Parameters.h" 10 #include <sstream>11 using namespace std;12 9 13 10 namespace morpheo { … … 21 18 #undef FUNCTION 22 19 #define FUNCTION "Register_unit::msg_error" 23 st ring Parameters::msg_error(void)20 std::string Parameters::msg_error(void) 24 21 { 25 22 log_printf(FUNC,Register_unit,FUNCTION,"Begin"); 26 23 27 st ring msg = "";24 std::string msg = ""; 28 25 29 26 return msg; -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/src/Parameters_print.cpp
r60 r75 8 8 #include "Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/include/Parameters.h" 9 9 #include "Behavioural/include/XML.h" 10 using namespace std;11 10 12 11 namespace morpheo { … … 20 19 #undef FUNCTION 21 20 #define FUNCTION "Register_unit::print" 22 st ring Parameters::print (uint32_t depth)21 std::string Parameters::print (uint32_t depth) 23 22 { 24 23 log_printf(FUNC,Register_unit,FUNCTION,"Begin"); … … 73 72 #undef FUNCTION 74 73 #define FUNCTION "Register_unit::operator<<" 75 ostream& operator<< (ostream& output_stream ,76 74 std::ostream& operator<< (std::ostream& output_stream , 75 morpheo::behavioural::core::multi_execute_loop::execute_loop::register_unit::Parameters & x) 77 76 { 78 77 log_printf(FUNC,Register_unit,FUNCTION,"Begin"); -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/src/Register_unit.cpp
r60 r75 34 34 ,_param (param) 35 35 ,_usage (usage) 36 #ifdef STATISTICS37 ,_param_statistics (param_statistics)38 #endif39 36 { 40 37 log_printf(FUNC,Register_unit,FUNCTION,"Begin"); 41 38 42 39 log_printf(INFO,Register_unit,FUNCTION,"Allocation"); 43 allocation (); 40 allocation ( 41 #ifdef STATISTICS 42 param_statistics 43 #endif 44 ); 44 45 45 46 #ifdef STATISTICS … … 47 48 48 49 // Allocation of statistics 49 _stat = new Statistics (static_cast<string>(_name), 50 param_statistics , 51 param); 50 statistics_declaration(param_statistics); 52 51 #endif 53 52 … … 84 83 #ifdef STATISTICS 85 84 log_printf(INFO,Register_unit,FUNCTION,"Generate Statistics file"); 86 87 _stat->generate_file(statistics(0));88 85 delete _stat; 89 86 #endif -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/src/Register_unit_allocation.cpp
r65 r75 19 19 #undef FUNCTION 20 20 #define FUNCTION "Register_unit::allocation" 21 void Register_unit::allocation (void) 21 void Register_unit::allocation ( 22 #ifdef STATISTICS 23 morpheo::behavioural::Parameters_Statistics * param_statistics 24 #else 25 void 26 #endif 27 ) 22 28 { 23 string rename, name_component;24 25 29 log_printf(FUNC,Register_unit,FUNCTION,"Begin"); 26 30 … … 249 253 // ~~~~~[ Component ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 250 254 251 st ring name;255 std::string name; 252 256 253 257 component_gpr = new morpheo::behavioural::generic::registerfile::RegisterFile::RegisterFile * [_param->_nb_ooo_engine]; … … 263 267 (name.c_str() 264 268 #ifdef STATISTICS 265 , _param_statistics269 ,param_statistics 266 270 #endif 267 271 ,_param->_param_gpr [i] … … 283 287 (name.c_str() 284 288 #ifdef STATISTICS 285 , _param_statistics289 ,param_statistics 286 290 #endif 287 291 ,_param->_param_gpr_status [i] … … 303 307 (name.c_str() 304 308 #ifdef STATISTICS 305 , _param_statistics309 ,param_statistics 306 310 #endif 307 311 ,_param->_param_spr [i] … … 322 326 (name.c_str() 323 327 #ifdef STATISTICS 324 , _param_statistics328 ,param_statistics 325 329 #endif 326 330 ,_param->_param_spr_status [i] … … 343 347 (name.c_str() 344 348 #ifdef STATISTICS 345 , _param_statistics349 ,param_statistics 346 350 #endif 347 351 ,_param->_param_glue … … 358 362 359 363 // ~~~~~[ Instanciation ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 360 364 std::string name_component; 365 361 366 for (uint32_t i=0; i<_param->_nb_ooo_engine; i++) 362 367 { 363 368 name_component = _name+"_gpr_"+toString(i); 364 369 365 cout << "Instance : " << name_component <<endl;370 std::cout << "Instance : " << name_component << std::endl; 366 371 367 372 #ifdef POSITION … … 420 425 name_component = _name+"_gpr_status_"+toString(i); 421 426 422 cout << "Instance : " << name_component <<endl;427 std::cout << "Instance : " << name_component << std::endl; 423 428 424 429 #ifdef POSITION … … 544 549 name_component = _name+"_spr_"+toString(i); 545 550 546 cout << "Instance : " << name_component <<endl;551 std::cout << "Instance : " << name_component << std::endl; 547 552 548 553 #ifdef POSITION … … 601 606 name_component = _name+"_spr_status_"+toString(i); 602 607 603 cout << "Instance : " << name_component <<endl;608 std::cout << "Instance : " << name_component << std::endl; 604 609 605 610 #ifdef POSITION … … 724 729 name_component = _name+"_glue"; 725 730 726 cout << "Instance : " << name_component <<endl;731 std::cout << "Instance : " << name_component << std::endl; 727 732 728 733 #ifdef POSITION … … 1034 1039 #endif 1035 1040 1036 // cout << *_component <<endl;1041 // std::cout << *_component << std::endl; 1037 1042 1038 1043 log_printf(FUNC,Register_unit,FUNCTION,"End"); -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/src/Register_unit_end_cycle.cpp
r60 r75 1 #if def VHDL_TESTBENCH1 #if defined(STATISTICS) or defined(VHDL_TESTBENCH) 2 2 /* 3 3 * $Id$ … … 16 16 namespace register_unit { 17 17 18 19 18 #undef FUNCTION 20 #define FUNCTION "Register_unit:: vhdl_testbench_transition"21 void Register_unit::vhdl_testbench_transition()19 #define FUNCTION "Register_unit::end_cycle" 20 void Register_unit::end_cycle () 22 21 { 23 22 log_printf(FUNC,Register_unit,FUNCTION,"Begin"); 24 23 24 #ifdef STATISTICS 25 _stat->end_cycle(); 26 #endif 27 28 #ifdef VHDL_TESTBENCH 25 29 // Evaluation before read the ouput signal 26 // sc_start(0); 27 30 // sc_start(0); 28 31 _interfaces->testbench(); 32 #endif 29 33 30 34 log_printf(FUNC,Register_unit,FUNCTION,"End"); -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/src/Register_unit_statistics_declaration.cpp
r60 r75 16 16 namespace register_unit { 17 17 18 19 18 #undef FUNCTION 20 #define FUNCTION "Register_unit::statistics "21 string Register_unit::statistics (uint32_t depth)19 #define FUNCTION "Register_unit::statistics_declaration" 20 void Register_unit::statistics_declaration (morpheo::behavioural::Parameters_Statistics * param_statistics) 22 21 { 23 22 log_printf(FUNC,Register_unit,FUNCTION,"Begin"); 24 23 25 string txt = _stat->print(depth); 26 24 _stat = new Stat (static_cast<std::string>(_name), 25 "Register_unit", 26 param_statistics); 27 28 for (uint32_t i=0; i<_param->_nb_ooo_engine; i++) 29 { 30 _stat->add_stat(component_gpr [i]->_stat); 31 _stat->add_stat(component_gpr_status[i]->_stat); 32 _stat->add_stat(component_spr [i]->_stat); 33 _stat->add_stat(component_spr_status[i]->_stat); 34 } 35 _stat->add_stat(component_glue->_stat); 36 27 37 log_printf(FUNC,Register_unit,FUNCTION,"End"); 28 29 return txt;30 38 }; 31 39 -
trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/Register_unit/src/Register_unit_transition.cpp
r60 r75 24 24 log_printf(FUNC,Register_unit,FUNCTION,"Begin"); 25 25 26 #ifdef STATISTICS 27 _stat->add(); 28 #endif 29 30 #ifdef VHDL_TESTBENCH 31 vhdl_testbench_transition (); 26 #if defined(STATISTICS) or defined(VHDL_TESTBENCH) 27 end_cycle(); 32 28 #endif 33 29
Note: See TracChangeset
for help on using the changeset viewer.