14 #ifndef LLVM_CODEGEN_MACHINEBLOCKFREQUENCYINFO_H
15 #define LLVM_CODEGEN_MACHINEBLOCKFREQUENCYINFO_H
25 template <
class BlockT>
class BlockFrequencyInfoImpl;
26 class MachineBasicBlock;
27 class MachineBranchProbabilityInfo;
28 class MachineFunction;
29 class MachineLoopInfo;
36 std::unique_ptr<ImplType> MBFI;
83 #endif // LLVM_CODEGEN_MACHINEBLOCKFREQUENCYINFO_H
MachineBlockFrequencyInfo pass uses BlockFrequencyInfoImpl implementation to estimate machine basic b...
BlockFrequency getBlockFreq(const MachineBasicBlock *MBB) const
getblockFreq - Return block frequency.
uint64_t getEntryFreq() const
MachineFunctionPass - This class adapts the FunctionPass interface to allow convenient creation of pa...
Twine - A lightweight data structure for efficiently representing the concatenation of temporary valu...
static bool isSimple(Instruction *I)
~MachineBlockFrequencyInfo() override
raw_ostream & printBlockFreq(raw_ostream &OS, const BlockFrequency Freq) const
Represent the analysis usage information of a pass.
Optional< uint64_t > getProfileCountFromFreq(uint64_t Freq) const
void view(const Twine &Name, bool isSimple=true) const
Pop up a ghostview window with the current block frequency propagation rendered using dot...
Optional< uint64_t > getBlockProfileCount(const MachineBasicBlock *MBB) const
void getAnalysisUsage(AnalysisUsage &AU) const override
getAnalysisUsage - This function should be overriden by passes that need analysis information to do t...
const MachineBranchProbabilityInfo * getMBPI() const
void releaseMemory() override
releaseMemory() - This member can be implemented by a pass if it wants to be able to release its memo...
MachineBlockFrequencyInfo()
bool runOnMachineFunction(MachineFunction &F) override
runOnMachineFunction - This method must be overloaded to perform the desired machine code transformat...
This class implements an extremely fast bulk output stream that can only output to a stream...
void calculate(const MachineFunction &F, const MachineBranchProbabilityInfo &MBPI, const MachineLoopInfo &MLI)
calculate - compute block frequency info for the given function.
Shared implementation for block frequency analysis.
const MachineFunction * getFunction() const