source: trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Front_end/Front_end/Context_State/include/Types.h @ 119

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

1) Prediction unit : static prediction not blocking

  • Property svn:keywords set to Id
File size: 8.7 KB
Line 
1#ifndef morpheo_behavioural_core_multi_front_end_front_end_context_state_Types_h
2#define morpheo_behavioural_core_multi_front_end_front_end_context_state_Types_h
3
4/*
5 * $Id: Types.h 119 2009-05-25 17:40:26Z rosiere $
6 *
7 * [ Description ]
8 *
9 */
10
11#include "Behavioural/include/Types.h"
12
13namespace morpheo {
14namespace behavioural {
15namespace core {
16namespace multi_front_end {
17namespace front_end {
18namespace context_state {
19
20//   NOTES :
21//   - MSYNC : memory model is weakly order. MSYNC can be sequentialize memory access
22//   - PSYNC : Finalize all instruction, to enter in a critic zone
23//   - CSYNC : to flush all structure in the CPU, to change a thread
24
25  typedef enum
26    {
27      CONTEXT_STATE_OK                                 , // none event
28      CONTEXT_STATE_KO_EXCEP                           , // wait end of event (exception)
29      CONTEXT_STATE_KO_EXCEP_ADDR                      , // update address manager
30      CONTEXT_STATE_KO_EXCEP_SPR                       , // update spr (epc, esr, sr[DSX])
31//       CONTEXT_STATE_KO_MISS_BRANCH_FAST_ADDR           , // update address manager
32//       CONTEXT_STATE_KO_MISS_BRANCH_FAST_WAIT_UPDATE    , // branch is complete, wait update by update_prediction_table
33      CONTEXT_STATE_KO_MISS_BRANCH_WAIT_UPDATE         , // branch is complete, wait update by update_prediction_table
34      CONTEXT_STATE_KO_MISS_BRANCH_ADDR                , // update address manager
35      CONTEXT_STATE_KO_MISS_BRANCH_WAITEND             , // wait end of event (miss branch)
36      CONTEXT_STATE_KO_MISS_LOAD_ADDR                  , // update address manager
37      CONTEXT_STATE_KO_MISS_LOAD_WAITEND               , // wait end of event (miss load))
38      CONTEXT_STATE_KO_MISS_LOAD_AND_BRANCH_WAIT_UPDATE, // branch is complete, wait update by update_prediction_table
39      CONTEXT_STATE_KO_MISS_LOAD_AND_BRANCH_ADDR       , // update address manager
40      CONTEXT_STATE_KO_MISS_LOAD_AND_BRANCH_WAITEND    , // wait end of event (miss branch)
41//    CONTEXT_STATE_KO_MSYNC                           , // wait completion of all memory operation
42//    CONTEXT_STATE_KO_MSYNC_ISSUE                     , // issue msync operation
43      CONTEXT_STATE_KO_MSYNC_EXEC                      , // wait completion of     msync  operation
44//    CONTEXT_STATE_KO_PSYNC                           , // wait completion of all        operation and after flush pipeline
45      CONTEXT_STATE_KO_PSYNC_FLUSH                     , // wait completion of all
46      CONTEXT_STATE_KO_PSYNC_ADDR                      , // wait completion of all
47//    CONTEXT_STATE_KO_CSYNC                           , // wait completion of all        operation and after flush pipeline and flush ALL units (MMU, cache ...)
48      CONTEXT_STATE_KO_CSYNC_FLUSH                     ,
49      CONTEXT_STATE_KO_CSYNC_ADDR                      ,
50//    CONTEXT_STATE_KO_SPR                             , // wait completion of all        operation
51//    CONTEXT_STATE_KO_SPR_ISSUE                       , // issue spr's access
52      CONTEXT_STATE_KO_SPR_EXEC                          // wait completion of all        operation (spr access)
53    } context_state_t;
54
55
56}; // end namespace context_state
57}; // end namespace front_end
58}; // end namespace multi_front_end
59}; // end namespace core
60}; // end namespace behavioural
61
62  template<> inline std::string toString<morpheo::behavioural::core::multi_front_end::front_end::context_state::context_state_t>(const morpheo::behavioural::core::multi_front_end::front_end::context_state::context_state_t& x)
63  {
64    switch (x)
65      {
66      case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_OK                                  : return "context_state_ok"                                 ; break;
67      case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_EXCEP                            : return "context_state_ko_excep"                           ; break;
68      case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_EXCEP_ADDR                       : return "context_state_ko_excep_addr"                      ; break;
69      case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_EXCEP_SPR                        : return "context_state_ko_excep_spr"                       ; break;
70//       case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_MISS_BRANCH_FAST_WAIT_UPDATE     : return "context_state_ko_miss_branch_fast_wait_update"    ; break;
71//       case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_MISS_BRANCH_FAST_ADDR            : return "context_state_ko_miss_branch_fast_addr"           ; break;
72      case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_MISS_BRANCH_WAIT_UPDATE          : return "context_state_ko_miss_branch_wait_update"         ; break;
73      case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_MISS_BRANCH_ADDR                 : return "context_state_ko_miss_branch_addr"                ; break;
74      case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_MISS_BRANCH_WAITEND              : return "context_state_ko_miss_branch_waitend"             ; break;
75      case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_MISS_LOAD_AND_BRANCH_WAIT_UPDATE : return "context_state_ko_miss_load_and_branch_wait_update"; break;
76      case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_MISS_LOAD_AND_BRANCH_ADDR        : return "context_state_ko_miss_load_and_branch_addr"       ; break;
77      case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_MISS_LOAD_AND_BRANCH_WAITEND     : return "context_state_ko_miss_load_and_branch_waitend"    ; break;
78      case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_MISS_LOAD_ADDR                   : return "context_state_ko_miss_load_addr"                  ; break;
79      case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_MISS_LOAD_WAITEND                : return "context_state_ko_miss_load_waitend"               ; break;
80//    case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_MSYNC                            : return "context_state_ko_msync"                           ; break;
81//    case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_MSYNC_ISSUE                      : return "context_state_ko_msync_issue"                     ; break;
82      case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_MSYNC_EXEC                       : return "context_state_ko_msync_exec"                      ; break;
83//    case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_PSYNC                            : return "context_state_ko_psync"                           ; break;
84      case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_PSYNC_FLUSH                      : return "context_state_ko_psync_flush"                     ; break;
85      case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_PSYNC_ADDR                       : return "context_state_ko_psync_addr"                      ; break;
86//    case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_CSYNC                            : return "context_state_ko_csync"                           ; break;
87      case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_CSYNC_FLUSH                      : return "context_state_ko_csync_flush"                     ; break;
88      case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_CSYNC_ADDR                       : return "context_state_ko_csync_addr"                      ; break;
89//    case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_SPR                              : return "context_state_ko_spr"                             ; break;
90//    case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_SPR_ISSUE                        : return "context_state_ko_spr_issue"                       ; break;
91      case morpheo::behavioural::core::multi_front_end::front_end::context_state::CONTEXT_STATE_KO_SPR_EXEC                         : return "context_state_ko_spr_exec"                        ; break;
92      default    : return ""      ; break;
93      }
94  };
95
96}; // end namespace morpheo             
97
98#endif
Note: See TracBrowser for help on using the repository browser.