Go to the documentation of this file.
43 #ifndef __CPU_PRED_TAGE_SC_L
44 #define __CPU_PRED_TAGE_SC_L
48 #include "params/TAGE_SC_L.hh"
49 #include "params/TAGE_SC_L_LoopPredictor.hh"
50 #include "params/TAGE_SC_L_TAGE.hh"
102 Addr target)
override;
107 int F(
int phist,
int size,
int bank)
const override;
112 Addr target)
override;
115 ThreadHistory & tHist,
int brtype,
bool taken,
118 void adjustAlloc(
bool & alloc,
bool taken,
bool pred_taken)
override;
155 ThreadID tid,
Addr branch_pc,
bool cond_branch,
void* &
b)
override;
161 Addr corrTarget)
override;
187 #endif // __CPU_PRED_TAGE_SC_L
void buildTageTables() override
Instantiates the TAGE table entries.
const unsigned logTagTableSize
int16_t ThreadID
Thread index/ID type.
const bool truncatePathHist
TAGE_SC_L_TAGE(const TAGE_SC_L_TAGEParams *p)
void regStats() override
Callback to set stat parameters.
const unsigned shortTagsTageFactor
int calcDep(TAGEBase::BranchInfo *bi)
void squash(ThreadID tid, bool taken, TAGEBase::BranchInfo *bi, Addr target) override
Restores speculatively updated path and direction histories.
StatisticalCorrector * statisticalCorrector
@ LAST_LTAGE_PROVIDER_TYPE
TAGE_SC_L(const TAGE_SC_LParams *params)
TAGE_SC_L_LoopPredictor(TAGE_SC_L_LoopPredictorParams *p)
virtual void handleAllocAndUReset(bool alloc, bool taken, TAGEBase::BranchInfo *bi, int nrand) override=0
Handles Allocation and U bits reset on an update.
int bindex(Addr pc_in) const override
Computes the index used to access the bimodal table.
void calculateParameters() override
Calculates the history lengths and some other paramters in derived classes.
int gindex(ThreadID tid, Addr pc, int bank) const override
Computes the index used to access a partially tagged table.
StatisticalCorrector::BranchInfo * scBranchInfo
bool getBimodePred(Addr branch_pc, TAGEBase::BranchInfo *tage_bi) const override
Get a branch prediction from the bimodal predictor.
void calculateIndicesAndTags(ThreadID tid, Addr branch_pc, TAGEBase::BranchInfo *bi) override
On a prediction, calculates the TAGE indices and tags for all the different history lengths.
int F(int phist, int size, int bank) const override
Utility function to shuffle the path history depending on which tagged table we are accessing.
bool predict(ThreadID tid, Addr branch_pc, bool cond_branch, void *&b) override
Get a branch prediction from LTAGE.
void handleUReset() override
Handles the U bits reset.
virtual bool optionalAgeInc() const override
virtual uint16_t gtag(ThreadID tid, Addr pc, int bank) const override=0
Computes the partial tag of a tagged table.
unsigned getUseAltIdx(TAGEBase::BranchInfo *bi, Addr branch_pc) override
Calculation of the index for useAltPredForNewlyAllocated On this base TAGE implementation it is alway...
uint64_t Addr
Address type This will probably be moved somewhere else in the near future.
void updateHistories(ThreadID tid, Addr branch_pc, bool taken, TAGEBase::BranchInfo *b, bool speculative, const StaticInstPtr &inst, Addr target) override
(Speculatively) updates global histories (path and direction).
const Params * params() const
virtual ~TageSCLBranchInfo()
virtual int gindex_ext(int index, int bank) const =0
virtual bool calcConf(int index) const override
virtual void handleTAGEUpdate(Addr branch_pc, bool taken, TAGEBase::BranchInfo *bi) override=0
Handles the update of the TAGE entries.
BranchInfo(TAGEBase &tage)
const unsigned longTagsSize
const unsigned firstLongTagTable
void adjustAlloc(bool &alloc, bool taken, bool pred_taken) override
Extra calculation to tell whether TAGE allocaitons may happen or not on an update For this base TAGE ...
const unsigned shortTagsSize
void extraAltCalc(TAGEBase::BranchInfo *bi) override
Extra steps for calculating altTaken For this base TAGE class it does nothing.
void updatePathAndGlobalHistory(ThreadHistory &tHist, int brtype, bool taken, Addr branch_pc, Addr target)
virtual TAGEBase::BranchInfo * makeBranchInfo() override
const unsigned longTagsTageFactor
void update(ThreadID tid, Addr branch_addr, bool taken, void *bp_history, bool squashed, const StaticInstPtr &inst, Addr corrTarget) override
Updates the BP with taken/not taken information.
TageSCLBranchInfo(TAGEBase &tage, StatisticalCorrector &sc, LoopPredictor &lp)
Generated on Wed Sep 30 2020 14:02:09 for gem5 by doxygen 1.8.17