29 #ifndef __CPU_PRED_RAS_HH__
30 #define __CPU_PRED_RAS_HH__
40 namespace branch_prediction
Defines global host-dependent types: Counter, Tick, and (indirectly) {int,uint}{8,...
Return address stack class, implements a simple RAS.
const PCStateBase * top()
Returns the top address on the RAS.
void push(const PCStateBase &return_addr)
Pushes an address onto the RAS.
std::vector< std::unique_ptr< PCStateBase > > addrStack
The RAS itself.
void restore(unsigned top_entry_idx, const PCStateBase *restored)
Changes index to the top of the RAS, and replaces the top address with a new target.
ReturnAddrStack()
Creates a return address stack, but init() must be called prior to use.
unsigned usedEntries
The number of used entries in the RAS.
void decrTos()
Decrements the top of stack index.
unsigned tos
The top of stack index.
void init(unsigned numEntries)
Initializes RAS with a specified number of entries.
void pop()
Pops the top address from the RAS.
unsigned topIdx()
Returns the index of the top of the RAS.
unsigned numEntries
The number of entries in the RAS.
void incrTos()
Increments the top of stack index.
Reference material can be found at the JEDEC website: UFS standard http://www.jedec....