source: trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Victim/Victim_Pseudo_LRU/src/Victim_Pseudo_LRU.cpp @ 78

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

Add :

  • Execute_loop (must be test systemC)
  • Prediction
    • Direction : predifined scheme
    • Branch Target Buffer
  • iFetch_unit
    • ifetch_queue
    • pc management
  • Decod_unit
    • coming soon : support for custom operation
  • Rename_unit
    • RAT
    • Free_list
    • Dependence RAW check
    • Load store unit pointer
  • New Environnement (hierarchy_memory will remove in a next version)


Modif :

  • Manage Custom Operation
  • All component in execute_loop to use the new statistics management

Not Finish :

  • Return Address Stack
  • Environnement
File size: 2.1 KB
RevLine 
[10]1/*
2 * $Id$
3 *
4 * [ Description ]
5 *
6 */
7
[15]8#include "Behavioural/Generic/Victim/Victim_Pseudo_LRU/include/Victim_Pseudo_LRU.h"
[10]9
10namespace morpheo {
11namespace behavioural {
12namespace generic {
13namespace victim {
[15]14namespace victim_pseudo_lru {
[10]15
16#ifdef SYSTEMC
[15]17  Victim_Pseudo_LRU::Victim_Pseudo_LRU (sc_module_name name,
[10]18#else
[75]19  Victim_Pseudo_LRU::Victim_Pseudo_LRU (std::string name,
[10]20#endif
21#ifdef STATISTICS
[75]22                          morpheo::behavioural::Parameters_Statistics * param_statistics,
[10]23#endif
[78]24                          morpheo::behavioural::generic::victim::victim_pseudo_lru::Parameters * param ):
[10]25                          _name   (name)
26                          ,_param (param)
27  {
[15]28    log_printf(FUNC,Victim_Pseudo_LRU,"Victim_Pseudo_LRU","Begin");
[10]29
[42]30#ifdef SYSTEMC
31    log_printf(TRACE,Victim_Pseudo_LRU,"Victim_Pseudo_LRU","Allocation");
32    allocation ();
33#endif
34
[10]35#ifdef STATISTICS
[15]36    log_printf(TRACE,Victim_Pseudo_LRU,"Victim_Pseudo_LRU","Allocation of statistics");
[10]37   
38    // Allocation of statistics
[75]39    statistics_declaration(param_statistics);
[10]40#endif
41
42#ifdef VHDL
43    // generate the vhdl
[15]44    log_printf(TRACE,Victim_Pseudo_LRU,"Victim_Pseudo_LRU","Generation of VHDL");
[10]45    vhdl();
46#endif
47
48#ifdef SYSTEMC
[15]49    log_printf(TRACE,Victim_Pseudo_LRU,"Victim_Pseudo_LRU","Definition of sc_method");
[10]50    SC_METHOD (transition);
51    dont_initialize ();
[66]52    sensitive << (*(in_CLOCK)).pos();
[10]53
[78]54    SC_METHOD (genMoore);
[10]55    dont_initialize ();
[66]56    sensitive << (*(in_CLOCK)).neg();
[10]57
58#ifdef SYSTEMCASS_SPECIFIC
59#endif   
60
61    // Constant - ack is always at one
[78]62    for (uint32_t i=0; i<_param->_nb_access; i++)
63      {
64        internal_ACCESS_ACK [i] = 1;
65        PORT_WRITE (out_ACCESS_ACK [i], internal_ACCESS_ACK [i]);
66      }
[10]67
68#endif
[15]69    log_printf(FUNC,Victim_Pseudo_LRU,"Victim_Pseudo_LRU","End");
[10]70  };
71 
[15]72  Victim_Pseudo_LRU::~Victim_Pseudo_LRU (void)
[10]73  {
[15]74    log_printf(FUNC,Victim_Pseudo_LRU,"~Victim_Pseudo_LRU","Begin");
[10]75#ifdef SYSTEMC
76    deallocation ();
77#endif
78
79#ifdef STATISTICS
80    delete _stat;
81#endif
[15]82    log_printf(FUNC,Victim_Pseudo_LRU,"~Victim_Pseudo_LRU","End");
[10]83  };
84
[15]85}; // end namespace victim_pseudo_lru
[10]86}; // end namespace victim
87}; // end namespace generic
88}; // end namespace behavioural
89}; // end namespace morpheo             
Note: See TracBrowser for help on using the repository browser.