[llvm] [AMDGPU][StructurizeCFG] Maintain branch MD_prof metadata (PR #109813)
Matt Arsenault via llvm-commits
llvm-commits at lists.llvm.org
Wed Sep 25 03:04:38 PDT 2024
================
@@ -578,12 +621,14 @@ void StructurizeCFG::insertConditions(bool Loops) {
Dominator.addBlock(Parent);
Value *ParentValue = nullptr;
- for (std::pair<BasicBlock *, Value *> BBAndPred : Preds) {
+ MaybeCondBranchWeights ParentWeights = std::nullopt;
+ for (std::pair<BasicBlock *, ValueWeightPair> BBAndPred : Preds) {
BasicBlock *BB = BBAndPred.first;
- Value *Pred = BBAndPred.second;
+ Value *Pred = BBAndPred.second.first;
----------------
arsenm wrote:
C++17 destructuring would help here and below
https://github.com/llvm/llvm-project/pull/109813
More information about the llvm-commits
mailing list