source: trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/RegisterFile/include/RegisterFile.h @ 112

Last change on this file since 112 was 112, checked in by rosiere, 15 years ago

1) Stat_list : fix retire old and new register bug
2) Stat_list : remove read_counter and valid flag, because validation of destination is in retire step (not in commit step)
3) Model : add class Model (cf Morpheo.sim)
4) Allocation : alloc_interface_begin and alloc_interface_end to delete temporary array.
5) Script : add distexe.sh
6) Add Comparator, Multiplier, Divider. But this component are not implemented
7) Software : add Dhrystone

  • Property svn:keywords set to Id
File size: 3.8 KB
Line 
1#ifndef morpheo_behavioural_generic_registerfile_RegisterFile_h
2#define morpheo_behavioural_generic_registerfile_RegisterFile_h
3
4/*
5 * $Id: RegisterFile.h 112 2009-03-18 22:36:26Z rosiere $
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
19#include "Behavioural/Generic/RegisterFile/RegisterFile_Monolithic/include/RegisterFile_Monolithic.h"
20#include "Behavioural/Generic/RegisterFile/RegisterFile_Multi_Banked/include/RegisterFile_Multi_Banked.h"
21
22#include "Behavioural/Generic/RegisterFile/include/Parameters.h"
23#include "Behavioural/Generic/RegisterFile/include/Types.h"
24#ifdef STATISTICS
25#include "Behavioural/include/Stat.h"
26#endif
27#include "Behavioural/include/Component.h"
28#ifdef VHDL
29#include "Behavioural/include/Vhdl.h"
30#endif
31#include "Behavioural/include/Usage.h"
32
33namespace morpheo {
34namespace behavioural {
35namespace generic {
36namespace registerfile {
37
38
39  class RegisterFile
40#if SYSTEMC
41    : public sc_module
42#endif
43  {
44    // -----[ fields ]----------------------------------------------------
45    // Parameters
46  protected : const std::string  _name;
47  protected : const Parameters * _param;
48  private   : const Tusage_t     _usage;
49
50#ifdef STATISTICS
51  public    : Stat                           * _stat;
52#endif
53
54  public    : Component                      * _component;
55  private   : Interfaces                     * _interfaces;
56
57#ifdef SYSTEMC
58    // ~~~~~[ Interface ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
59    // Interface
60  public    : SC_CLOCK                      *  in_CLOCK        ;
61  public    : SC_IN (Tcontrol_t)            *  in_NRESET       ;
62
63    // ----- Interface Read
64  public    : SC_IN       (Tcontrol_t)     **  in_READ_VAL     ;
65  public    : SC_OUT      (Tcontrol_t)     ** out_READ_ACK     ;
66  public    : SC_IN       (Taddress_t)     **  in_READ_ADDRESS ;
67  public    : SC_OUT      (Tdata_t)        ** out_READ_DATA    ;
68
69    // ----- Interface Write
70  public    : SC_IN       (Tcontrol_t)     **  in_WRITE_VAL    ;
71  public    : SC_OUT      (Tcontrol_t)     ** out_WRITE_ACK    ;
72  public    : SC_IN       (Taddress_t)     **  in_WRITE_ADDRESS;
73  public    : SC_IN       (Tdata_t)        **  in_WRITE_DATA   ;
74
75#endif
76
77    // ~~~~~[ Component ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~   
78  protected : morpheo::behavioural::generic::registerfile::registerfile_monolithic  ::RegisterFile_Monolithic  ::RegisterFile_Monolithic   * component_RegisterFile_Monolithic  ;
79  protected : morpheo::behavioural::generic::registerfile::registerfile_multi_banked::RegisterFile_Multi_Banked::RegisterFile_Multi_Banked * component_RegisterFile_Multi_Banked;
80
81    // ~~~~~[ Register ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~   
82
83    // ~~~~~[ Internal ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
84
85    // -----[ methods ]---------------------------------------------------
86
87#ifdef SYSTEMC
88    SC_HAS_PROCESS (RegisterFile);
89#endif
90  public  :          RegisterFile              (
91#ifdef SYSTEMC
92                                                sc_module_name                              name,
93#else                                         
94                                                std::string                                      name,
95#endif                                         
96#ifdef STATISTICS
97                                                morpheo::behavioural::Parameters_Statistics * param_statistics,
98#endif
99                                                Parameters                                  * param ,
100                                                Tusage_t usage);
101   
102  public  :          ~RegisterFile             (void);
103                                               
104#ifdef SYSTEMC                                 
105  private : void     allocation                (
106#ifdef STATISTICS
107                                                morpheo::behavioural::Parameters_Statistics * param_statistics
108#else
109                                                void
110#endif
111                                                );
112  private : void     deallocation              (void);
113#endif                                         
114  };
115
116}; // end namespace registerfile
117}; // end namespace generic
118
119}; // end namespace behavioural
120}; // end namespace morpheo             
121
122#endif
Note: See TracBrowser for help on using the repository browser.