[PATCH] D13745: Replace all uses of branch weights by branch probabilities on machine code level passes.
Sean Silva via llvm-commits
llvm-commits at lists.llvm.org
Wed Oct 14 18:55:13 PDT 2015
silvas added a subscriber: silvas.
================
Comment at: include/llvm/Analysis/BranchProbabilityInfo.h:118-121
@@ -114,1 +117,6 @@
+ static BranchProbability getBranchProbStackProtector(bool IsLikely) {
+ return IsLikely ? BranchProbability((1u << 20) - 1, 1u << 20)
+ : BranchProbability(1, 1u << 20);
+ }
+
----------------
Can you factor out 1u<<20 into a named constant?
http://reviews.llvm.org/D13745
More information about the llvm-commits
mailing list