[PATCH] D147944: [LV][NFC] Improve complexity of fixing users of reductions
    Alexey Bataev via Phabricator via llvm-commits 
    llvm-commits at lists.llvm.org
       
    Mon Apr 10 08:02:44 PDT 2023
    
    
  
ABataev added inline comments.
================
Comment at: llvm/lib/Transforms/Vectorize/LoopVectorize.cpp:4105
+    SmallPtrSet<PHINode *, 2> ToFix;
+    PHINode *Phi = cast<PHINode>(PhiR->getUnderlyingValue());
+    for (User *U : Phi->users())
----------------
auto *Phi
================
Comment at: llvm/lib/Transforms/Vectorize/LoopVectorize.cpp:4107
+    for (User *U : Phi->users())
+      if (isa<PHINode>(U) && cast<Instruction>(U)->getParent() == LoopExitBlock)
+        ToFix.insert(cast<PHINode>(U));
----------------
if (auto *UPhi = dyn_cast<PHINode>(U); UPhi && UPhi->getParent() == LoopExitBlock) 
Repository:
  rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D147944/new/
https://reviews.llvm.org/D147944
    
    
More information about the llvm-commits
mailing list