[PATCH] D79396: [BrachProbablityInfo] Set edge probabilities at once. NFC.

Yevgeny Rouban via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon May 4 23:07:57 PDT 2020


yrouban created this revision.
yrouban added reviewers: yamaguchi, ebrevnov, asbirlea, nikic.
Herald added a subscriber: hiraditya.
Herald added a project: LLVM.

Hide the method that allows setting probability for particular edge and introduce a public method that sets probabilities for all outgoing edges at once.
Setting individual edge probability is error prone. More over it is difficult to check that the total probability is 1.0 because there is no easy way to know when the user finished setting all the probabilities.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D79396

Files:
  llvm/include/llvm/Analysis/BranchProbabilityInfo.h
  llvm/lib/Analysis/BranchProbabilityInfo.cpp
  llvm/lib/Transforms/Scalar/JumpThreading.cpp
  llvm/lib/Transforms/Utils/BreakCriticalEdges.cpp
  llvm/lib/Transforms/Utils/CodeExtractor.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D79396.262012.patch
Type: text/x-patch
Size: 11504 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200505/db6767f5/attachment.bin>


More information about the llvm-commits mailing list