source: trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Execute_loop/Execute_loop/src/Execute_loop.cpp @ 146

Last change on this file since 146 was 146, checked in by rosiere, 13 years ago

1) Integration of RegisterFile_Internal_Banked in RegisterFile?
2) Erase "read_write" interface in RegisterFile_Monolithic component
3) Add smith predictor parameters in Load_store_pointer_unit.
4) Fix not statistics flags

  • Property svn:keywords set to Id
File size: 2.7 KB
Line 
1/*
2 * $Id: Execute_loop.cpp 146 2011-02-01 20:57:54Z rosiere $
3 *
4 * [ Description ]
5 *
6 */
7
8#include "Behavioural/Core/Multi_Execute_loop/Execute_loop/include/Execute_loop.h"
9
10namespace morpheo                    {
11namespace behavioural {
12namespace core {
13namespace multi_execute_loop {
14namespace execute_loop {
15
16
17#undef  FUNCTION
18#define FUNCTION "Execute_loop::Execute_loop"
19  Execute_loop::Execute_loop
20  (
21#ifdef SYSTEMC
22   sc_module_name name,
23#else
24   string name,
25#endif
26#ifdef STATISTICS
27   morpheo::behavioural::Parameters_Statistics * param_statistics,
28#endif
29   morpheo::behavioural::core::multi_execute_loop::execute_loop::Parameters * param,
30   morpheo::behavioural::Tusage_t usage
31   ):
32    _name              (name)
33    ,_param            (param)
34    ,_usage            (usage)
35  {
36    log_printf(FUNC,Execute_loop,FUNCTION,_("<%s> Begin"),_name.c_str());
37
38// #if DEBUG_Execute_loop == true
39//     log_printf(INFO,Execute_loop,FUNCTION,_("<%s> Parameters"),_name.c_str());
40
41//     std::cout << *param << std::endl;
42// #endif   
43
44    log_printf(INFO,Execute_loop,FUNCTION,_("<%s> Allocation"),_name.c_str());
45
46    allocation (
47#ifdef STATISTICS
48                param_statistics
49#endif
50                );
51
52#ifdef STATISTICS
53    if (usage_is_set(_usage,USE_STATISTICS))
54      { 
55        log_printf(INFO,Execute_loop,FUNCTION,_("<%s> Allocation of statistics"),_name.c_str());
56
57        statistics_declaration(param_statistics);
58      }
59#endif
60
61#ifdef VHDL
62    if (usage_is_set(_usage,USE_VHDL))
63      {
64        // generate the vhdl
65        log_printf(INFO,Execute_loop,FUNCTION,_("<%s> Generate the vhdl"),_name.c_str());
66       
67        vhdl();
68      }
69#endif
70
71#ifdef SYSTEMC
72# if defined(STATISTICS) or defined(VHDL_TESTBENCH)
73
74    if (usage_is_set(_usage,USE_SYSTEMC))
75      {
76        log_printf(INFO,Execute_loop,FUNCTION,_("<%s> Method - transition"),_name.c_str());
77
78        SC_METHOD (transition);
79        dont_initialize ();
80        sensitive << (*(in_CLOCK)).pos();
81       
82# ifdef SYSTEMCASS_SPECIFIC
83        // List dependency information
84# endif
85      }
86# endif
87#endif
88    log_printf(FUNC,Execute_loop,FUNCTION,_("<%s> End"),_name.c_str());
89  };
90   
91#undef  FUNCTION
92#define FUNCTION "Execute_loop::~Execute_loop"
93  Execute_loop::~Execute_loop (void)
94  {
95    log_printf(FUNC,Execute_loop,FUNCTION,_("<%s> Begin"),_name.c_str());
96
97#ifdef STATISTICS
98    if (usage_is_set(_usage,USE_STATISTICS))
99      {
100        log_printf(INFO,Execute_loop,FUNCTION,_("<%s> Generate Statistics file"),_name.c_str());
101       
102        delete _stat;
103      }
104#endif
105
106    log_printf(INFO,Execute_loop,FUNCTION,_("<%s> Deallocation"),_name.c_str());
107    deallocation ();
108
109    log_printf(FUNC,Execute_loop,FUNCTION,_("<%s> End"),_name.c_str());
110  };
111
112}; // end namespace execute_loop
113}; // end namespace multi_execute_loop
114}; // end namespace core
115
116}; // end namespace behavioural
117}; // end namespace morpheo             
Note: See TracBrowser for help on using the repository browser.