Go to the documentation of this file.
22 "Machine Branch Probability Analysis",
false,
true)
29 cl::desc(
"branch probability threshold in percentage"
30 "to be considered very likely"),
34 "profile-likely-prob",
35 cl::desc(
"branch probability threshold in percentage to be considered"
36 " very likely when profile is available"),
48 void MachineBranchProbabilityInfo::anchor() {}
53 return Src->getSuccProbability(Dst);
75 <<
" probability is " << Prob
76 << (
isEdgeHot(Src, Dst) ?
" [HOT edge]\n" :
"\n");
MachineBranchProbabilityInfo()
This is an optimization pass for GlobalISel generic memory operations.
ImmutablePass class - This class is used to provide information that does not need to be run.
Printable printMBBReference(const MachineBasicBlock &MBB)
Prints a machine basic block reference.
void initializeMachineBranchProbabilityInfoPass(PassRegistry &)
raw_ostream & printEdgeProbability(raw_ostream &OS, const MachineBasicBlock *Src, const MachineBasicBlock *Dst) const
static PassRegistry * getPassRegistry()
getPassRegistry - Access the global registry object, which is automatically initialized at applicatio...
PassRegistry - This class manages the registration and intitialization of the pass subsystem as appli...
cl::opt< unsigned > StaticLikelyProb
This class implements an extremely fast bulk output stream that can only output to a stream.
cl::opt< unsigned > ProfileLikelyProb
unsigned ID
LLVM IR allows to use arbitrary numbers as calling convention identifiers.
#define INITIALIZE_PASS_END(passName, arg, name, cfg, analysis)
auto find(R &&Range, const T &Val)
Provide wrappers to std::find which take ranges instead of having to pass begin/end explicitly.
initializer< Ty > init(const Ty &Val)
BranchProbability getEdgeProbability(const MachineBasicBlock *Src, const MachineBasicBlock *Dst) const
A global registry used in conjunction with static constructors to make pluggable components (like tar...
COFF::MachineTypes Machine
std::vector< MachineBasicBlock * >::const_iterator const_succ_iterator
INITIALIZE_PASS_BEGIN(MachineBranchProbabilityInfo, "machine-branch-prob", "Machine Branch Probability Analysis", false, true) INITIALIZE_PASS_END(MachineBranchProbabilityInfo
bool isEdgeHot(const MachineBasicBlock *Src, const MachineBasicBlock *Dst) const