[88] | 1 | #ifndef morpheo_behavioural_core_multi_ooo_engine_ooo_engine_commit_unit_Types_h |
---|
| 2 | #define morpheo_behavioural_core_multi_ooo_engine_ooo_engine_commit_unit_Types_h |
---|
| 3 | |
---|
| 4 | /* |
---|
| 5 | * $Id: Types.h 112 2009-03-18 22:36:26Z rosiere $ |
---|
| 6 | * |
---|
| 7 | * [ Description ] |
---|
| 8 | * |
---|
| 9 | */ |
---|
| 10 | |
---|
| 11 | #include "Behavioural/include/Types.h" |
---|
| 12 | |
---|
| 13 | namespace morpheo { |
---|
| 14 | namespace behavioural { |
---|
| 15 | namespace core { |
---|
| 16 | namespace multi_ooo_engine { |
---|
| 17 | namespace ooo_engine { |
---|
| 18 | namespace commit_unit { |
---|
| 19 | |
---|
| 20 | typedef enum |
---|
| 21 | { |
---|
| 22 | RETIRE_IN_ORDER , |
---|
| 23 | RETIRE_OOO_RENAME_UNIT, |
---|
| 24 | RETIRE_OOO_CONTEXT |
---|
| 25 | } retire_ooo_t; |
---|
| 26 | |
---|
| 27 | typedef enum |
---|
| 28 | { |
---|
[100] | 29 | ROB_EMPTY , // |
---|
| 30 | ROB_BRANCH_WAIT_END , // |
---|
| 31 | ROB_BRANCH_COMPLETE , // |
---|
| 32 | ROB_STORE_WAIT_HEAD_OK , // |
---|
| 33 | // ROB_STORE_WAIT_HEAD_KO , // |
---|
| 34 | ROB_STORE_HEAD_OK , // |
---|
| 35 | ROB_STORE_HEAD_KO , // |
---|
| 36 | ROB_OTHER_WAIT_END , // |
---|
[112] | 37 | |
---|
| 38 | ROB_EVENT_WAIT_END , // |
---|
| 39 | |
---|
[100] | 40 | ROB_END_OK_SPECULATIVE , // |
---|
| 41 | ROB_END_OK , // |
---|
| 42 | ROB_END_KO_SPECULATIVE , // |
---|
| 43 | ROB_END_KO , // |
---|
| 44 | ROB_END_BRANCH_MISS_SPECULATIVE, // |
---|
| 45 | ROB_END_BRANCH_MISS , // |
---|
[105] | 46 | ROB_END_LOAD_MISS_SPECULATIVE , // |
---|
| 47 | ROB_END_LOAD_MISS_UPDATE , // |
---|
| 48 | ROB_END_LOAD_MISS , // |
---|
[100] | 49 | ROB_END_MISS , // |
---|
| 50 | ROB_END_EXCEPTION_WAIT_HEAD , // |
---|
[105] | 51 | ROB_END_EXCEPTION_UPDATE , // |
---|
| 52 | ROB_END_EXCEPTION // |
---|
[112] | 53 | |
---|
[88] | 54 | } rob_state_t; |
---|
| 55 | |
---|
| 56 | class entry_t |
---|
| 57 | { |
---|
| 58 | public : rob_state_t state ; |
---|
| 59 | public : uint32_t ptr ; |
---|
| 60 | public : Tcontext_t front_end_id ; |
---|
| 61 | public : Tcontext_t context_id ; |
---|
| 62 | public : uint32_t rename_unit_id ; |
---|
| 63 | public : Tdepth_t depth ; |
---|
| 64 | public : Ttype_t type ; |
---|
| 65 | public : Toperation_t operation ; |
---|
| 66 | public : Tcontrol_t is_delay_slot ; |
---|
[105] | 67 | //public : Tgeneral_data_t address ; |
---|
[88] | 68 | public : Tcontrol_t use_store_queue ; |
---|
| 69 | public : Tcontrol_t use_load_queue ; |
---|
| 70 | public : Tlsq_ptr_t store_queue_ptr_write ; |
---|
| 71 | public : Tlsq_ptr_t load_queue_ptr_write ; |
---|
| 72 | public : Tcontrol_t read_ra ; |
---|
| 73 | public : Tgeneral_address_t num_reg_ra_log ; |
---|
| 74 | public : Tgeneral_address_t num_reg_ra_phy ; |
---|
| 75 | public : Tcontrol_t read_rb ; |
---|
| 76 | public : Tgeneral_address_t num_reg_rb_log ; |
---|
| 77 | public : Tgeneral_address_t num_reg_rb_phy ; |
---|
| 78 | public : Tcontrol_t read_rc ; |
---|
| 79 | public : Tspecial_address_t num_reg_rc_log ; |
---|
| 80 | public : Tspecial_address_t num_reg_rc_phy ; |
---|
| 81 | public : Tcontrol_t write_rd ; |
---|
| 82 | public : Tgeneral_address_t num_reg_rd_log ; |
---|
| 83 | public : Tgeneral_address_t num_reg_rd_phy_old ; |
---|
| 84 | public : Tgeneral_address_t num_reg_rd_phy_new ; |
---|
| 85 | public : Tcontrol_t write_re ; |
---|
| 86 | public : Tspecial_address_t num_reg_re_log ; |
---|
| 87 | public : Tspecial_address_t num_reg_re_phy_old ; |
---|
| 88 | public : Tspecial_address_t num_reg_re_phy_new ; |
---|
| 89 | |
---|
| 90 | public : Texception_t exception ; |
---|
| 91 | public : Texception_t exception_use ; |
---|
| 92 | |
---|
| 93 | public : Tspecial_data_t flags ; |
---|
| 94 | public : Tcontrol_t no_sequence ; |
---|
[108] | 95 | public : Tcontrol_t speculative ; |
---|
[105] | 96 | //public : Tgeneral_data_t data_commit ; // branch's destination |
---|
[108] | 97 | #ifdef DEBUG |
---|
| 98 | public : Taddress_t address ; |
---|
| 99 | #endif |
---|
[105] | 100 | public : Taddress_t address_next ; |
---|
[111] | 101 | #ifdef DEBUG |
---|
| 102 | public : double cycle_rob_in ; |
---|
| 103 | public : double cycle_commit ; |
---|
| 104 | #endif |
---|
[88] | 105 | |
---|
| 106 | }; |
---|
| 107 | |
---|
| 108 | }; // end namespace commit_unit |
---|
| 109 | }; // end namespace ooo_engine |
---|
| 110 | }; // end namespace multi_ooo_engine |
---|
| 111 | }; // end namespace core |
---|
| 112 | }; // end namespace behavioural |
---|
| 113 | |
---|
| 114 | template<> inline std::string toString<morpheo::behavioural::core::multi_ooo_engine::ooo_engine::commit_unit::rob_state_t>(const morpheo::behavioural::core::multi_ooo_engine::ooo_engine::commit_unit::rob_state_t& x) |
---|
| 115 | { |
---|
| 116 | switch (x) |
---|
| 117 | { |
---|
[100] | 118 | case morpheo::behavioural::core::multi_ooo_engine::ooo_engine::commit_unit::ROB_EMPTY : return "ROB_EMPTY" ; break; |
---|
| 119 | case morpheo::behavioural::core::multi_ooo_engine::ooo_engine::commit_unit::ROB_BRANCH_WAIT_END : return "ROB_BRANCH_WAIT_END" ; break; |
---|
| 120 | case morpheo::behavioural::core::multi_ooo_engine::ooo_engine::commit_unit::ROB_BRANCH_COMPLETE : return "ROB_BRANCH_COMPLETE" ; break; |
---|
| 121 | case morpheo::behavioural::core::multi_ooo_engine::ooo_engine::commit_unit::ROB_STORE_WAIT_HEAD_OK : return "ROB_STORE_WAIT_HEAD_OK" ; break; |
---|
| 122 | // case morpheo::behavioural::core::multi_ooo_engine::ooo_engine::commit_unit::ROB_STORE_WAIT_HEAD_KO : return "ROB_STORE_WAIT_HEAD_KO" ; break; |
---|
| 123 | case morpheo::behavioural::core::multi_ooo_engine::ooo_engine::commit_unit::ROB_STORE_HEAD_OK : return "ROB_STORE_HEAD_OK" ; break; |
---|
| 124 | case morpheo::behavioural::core::multi_ooo_engine::ooo_engine::commit_unit::ROB_STORE_HEAD_KO : return "ROB_STORE_HEAD_KO" ; break; |
---|
| 125 | case morpheo::behavioural::core::multi_ooo_engine::ooo_engine::commit_unit::ROB_OTHER_WAIT_END : return "ROB_OTHER_WAIT_END" ; break; |
---|
[112] | 126 | case morpheo::behavioural::core::multi_ooo_engine::ooo_engine::commit_unit::ROB_EVENT_WAIT_END : return "ROB_EVENT_WAIT_END" ; break; |
---|
[100] | 127 | case morpheo::behavioural::core::multi_ooo_engine::ooo_engine::commit_unit::ROB_END_OK_SPECULATIVE : return "ROB_END_OK_SPECULATIVE" ; break; |
---|
| 128 | case morpheo::behavioural::core::multi_ooo_engine::ooo_engine::commit_unit::ROB_END_OK : return "ROB_END_OK" ; break; |
---|
| 129 | case morpheo::behavioural::core::multi_ooo_engine::ooo_engine::commit_unit::ROB_END_KO_SPECULATIVE : return "ROB_END_KO_SPECULATIVE" ; break; |
---|
| 130 | case morpheo::behavioural::core::multi_ooo_engine::ooo_engine::commit_unit::ROB_END_KO : return "ROB_END_KO" ; break; |
---|
| 131 | case morpheo::behavioural::core::multi_ooo_engine::ooo_engine::commit_unit::ROB_END_BRANCH_MISS_SPECULATIVE: return "ROB_END_BRANCH_MISS_SPECULATIVE" ; break; |
---|
| 132 | case morpheo::behavioural::core::multi_ooo_engine::ooo_engine::commit_unit::ROB_END_BRANCH_MISS : return "ROB_END_BRANCH_MISS" ; break; |
---|
[105] | 133 | case morpheo::behavioural::core::multi_ooo_engine::ooo_engine::commit_unit::ROB_END_LOAD_MISS_SPECULATIVE : return "ROB_END_LOAD_MISS_SPECULATIVE" ; break; |
---|
| 134 | case morpheo::behavioural::core::multi_ooo_engine::ooo_engine::commit_unit::ROB_END_LOAD_MISS_UPDATE : return "ROB_END_LOAD_MISS_UPDATE" ; break; |
---|
| 135 | case morpheo::behavioural::core::multi_ooo_engine::ooo_engine::commit_unit::ROB_END_LOAD_MISS : return "ROB_END_LOAD_MISS" ; break; |
---|
[100] | 136 | case morpheo::behavioural::core::multi_ooo_engine::ooo_engine::commit_unit::ROB_END_MISS : return "ROB_END_MISS" ; break; |
---|
| 137 | case morpheo::behavioural::core::multi_ooo_engine::ooo_engine::commit_unit::ROB_END_EXCEPTION_WAIT_HEAD : return "ROB_END_EXCEPTION_WAIT_HEAD" ; break; |
---|
[105] | 138 | case morpheo::behavioural::core::multi_ooo_engine::ooo_engine::commit_unit::ROB_END_EXCEPTION_UPDATE : return "ROB_END_EXCEPTION_UPDATE" ; break; |
---|
[100] | 139 | case morpheo::behavioural::core::multi_ooo_engine::ooo_engine::commit_unit::ROB_END_EXCEPTION : return "ROB_END_EXCEPTION" ; break; |
---|
| 140 | |
---|
[88] | 141 | default : return "" ; break; |
---|
| 142 | } |
---|
| 143 | }; |
---|
| 144 | |
---|
| 145 | }; // end namespace morpheo |
---|
| 146 | |
---|
| 147 | #endif |
---|