[llvm] [SimplifyCFG] Update profile metadata regardless of weight count (PR #190982)
Aiden Grossman via llvm-commits
llvm-commits at lists.llvm.org
Wed Apr 8 08:24:49 PDT 2026
================
@@ -3699,7 +3699,7 @@ class SwitchInstProfUpdateWrapper {
SwitchInstProfUpdateWrapper(SwitchInst &SI) : SI(SI) { init(); }
~SwitchInstProfUpdateWrapper() {
- if (Changed && Weights.has_value() && Weights->size() >= 2)
+ if (Changed && Weights.has_value())
----------------
boomanaiden154 wrote:
Ah, it still does get set, I was just looking through `getBranchWeightMDNode` which folds everything without the minimum number of operands to `nullptr`.
https://github.com/llvm/llvm-project/pull/190982
More information about the llvm-commits
mailing list