source: trunk/IPs/systemC/processor/Morpheo/Behavioural/New_Component/include/New_Component.h @ 71

Last change on this file since 71 was 71, checked in by rosiere, 16 years ago

Modification of Statisctics
Add a new systemC component : Load_Store_Queue (tested with one benchmark and one configuration). Store don't supported the Data Buss Error (Load is supported)

File size: 3.1 KB
Line 
1#ifndef morpheo_behavioural_@DEFINE_@COMPONENT_h
2#define morpheo_behavioural_@DEFINE_@COMPONENT_h
3
4/*
5 * $Id$
6 *
7 * [ Description ]
8 *
9 */
10
11#ifdef SYSTEMC
12#include "systemc.h"
13#endif
14
15#include <iostream>
16#include "Common/include/ToString.h"
17#include "Common/include/Debug.h"
18#include "Behavioural/include/Types.h"
19
20#include "Behavioural/@DIRECTORY/include/Parameters.h"
21#ifdef STATISTICS
22#include "Behavioural/include/Stat.h"
23#endif
24#include "Behavioural/include/Component.h"
25#ifdef VHDL
26#include "Behavioural/include/Vhdl.h"
27#endif
28#include "Behavioural/include/Usage.h"
29
30namespace morpheo {
31namespace behavioural {
32
33@NAMESPACE_BEGIN
34
35  class @COMPONENT
36#if SYSTEMC
37    : public sc_module
38#endif
39  {
40    // -----[ fields ]----------------------------------------------------
41    // Parameters
42  protected : const std::string  _name;
43  protected : const Parameters * _param;
44  private   : const Tusage_t     _usage;
45
46#ifdef STATISTICS
47  private   : Stat                           * _stat;
48#endif
49
50  public    : Component                      * _component;
51  private   : Interfaces                     * _interfaces;
52
53#ifdef SYSTEMC
54    // ~~~~~[ Interface ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
55    // Interface
56  public    : SC_CLOCK                      *  in_CLOCK        ;
57  public    : SC_IN (Tcontrol_t)            *  in_NRESET       ;
58
59    // ~~~~~[ Component ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~   
60
61    // ~~~~~[ Register ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~   
62
63    // ~~~~~[ Internal ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
64#endif
65
66    // -----[ Methods ]---------------------------------------------------
67
68#ifdef SYSTEMC
69    SC_HAS_PROCESS (@COMPONENT);
70#endif
71  public  :          @COMPONENT             
72  (
73#ifdef SYSTEMC
74   sc_module_name                                name,
75#else                                         
76   std::string                                   name,
77#endif                                         
78#ifdef STATISTICS
79   morpheo::behavioural::Parameters_Statistics * param_statistics,
80#endif
81   Parameters                                  * param,
82   morpheo::behavioural::Tusage_t                usage=USE_ALL
83   );
84  public  :          ~@COMPONENT             (void);
85                                               
86  private : void     allocation                (void);
87  private : void     deallocation              (void);
88                                               
89#ifdef SYSTEMC                                 
90//#if defined(STATISTICS) or defined(VHDL_TESTBENCH)
91  public  : void     transition                (void);
92//#endif
93#endif                                         
94#ifdef STATISTICS
95  public  : void        statistics_declaration    (morpheo::behavioural::Parameters_Statistics * param_statistics);
96  public  : std::string statistics_print          (uint32_t depth);
97#endif
98                                               
99#if VHDL                                       
100  public  : void     vhdl                      (void);
101  private : void     vhdl_declaration          (Vhdl * & vhdl);
102  private : void     vhdl_body                 (Vhdl * & vhdl);
103#endif                                         
104                                               
105#if defined(STATISTICS) or defined(VHDL_TESTBENCH)
106  private : void     end_cycle                 (void);
107#endif
108  };
109
110@NAMESPACE_END
111}; // end namespace behavioural
112}; // end namespace morpheo             
113
114#endif
Note: See TracBrowser for help on using the repository browser.