1/* 2 * Copyright (c) 2010 ARM Limited 3 * All rights reserved 4 * 5 * The license below extends only to copyright in the software and shall 6 * not be construed as granting a license to any other intellectual 7 * property including but not limited to intellectual property relating 8 * to a hardware implementation of the functionality of the software --- 93 unchanged lines hidden (view full) --- 102 /** Completes the access. Only valid for memory operations. */ 103 Fault completeAcc(PacketPtr pkt); 104 105 private: 106 /** Initializes variables. */ 107 void initVars(); 108 109 protected: |
110 /** Values to be written to the destination misc. registers. */ 111 MiscReg _destMiscRegVal[TheISA::MaxMiscDestRegs]; 112 |
113 /** Indexes of the destination misc. registers. They are needed to defer 114 * the write accesses to the misc. registers until the commit stage, when 115 * the instruction is out of its speculative state. 116 */ |
117 short _destMiscRegIdx[TheISA::MaxMiscDestRegs]; 118 |
119 /** Number of destination misc. registers. */ |
120 uint8_t _numDestMiscRegs; |
121 |
122 |
123 public: |
124#if TRACING_ON 125 /** Tick records used for the pipeline activity viewer. */ 126 Tick fetchTick; |
127 uint32_t decodeTick; 128 uint32_t renameTick; 129 uint32_t dispatchTick; 130 uint32_t issueTick; 131 uint32_t completeTick; |
132#endif 133 134 /** Reads a misc. register, including any side-effects the read 135 * might have as defined by the architecture. 136 */ 137 MiscReg readMiscReg(int misc_reg) 138 { 139 return this->cpu->readMiscReg(misc_reg, this->threadNumber); 140 } 141 142 /** Sets a misc. register, including any side-effects the write 143 * might have as defined by the architecture. 144 */ 145 void setMiscReg(int misc_reg, const MiscReg &val) 146 { 147 /** Writes to misc. registers are recorded and deferred until the 148 * commit stage, when updateMiscRegs() is called. 149 */ |
150 assert(_numDestMiscRegs < TheISA::MaxMiscDestRegs); |
151 _destMiscRegIdx[_numDestMiscRegs] = misc_reg; 152 _destMiscRegVal[_numDestMiscRegs] = val; 153 _numDestMiscRegs++; 154 } 155 156 /** Reads a misc. register, including any side-effects the read 157 * might have as defined by the architecture. 158 */ --- 140 unchanged lines hidden --- |