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