[llvm] [InstCombine] Set !prof metadata on Selects identified by add.ll test (PR #158743)

Aiden Grossman via llvm-commits llvm-commits at lists.llvm.org
Mon Sep 29 12:58:09 PDT 2025


================
@@ -185,6 +185,14 @@ inline uint32_t scaleBranchCount(uint64_t Count, uint64_t Scale) {
 LLVM_ABI void setExplicitlyUnknownBranchWeights(Instruction &I,
                                                 StringRef PassName);
 
+/// Like setExplicitlyUnknownBranchWeights(...), but only sets unknown branch
+/// weights in the new instruction if the parent function of the original
+/// instruction has function counts. This is to not confuse users by injecting
----------------
boomanaiden154 wrote:

Nit: has function counts -> has an entry count

https://github.com/llvm/llvm-project/pull/158743


More information about the llvm-commits mailing list