[llvm] 13fec93 - [NFC] rename to reflect F is not necessarily an Intrinsic

Sanne Wouda via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 13 07:30:12 PDT 2020


Author: Sanne Wouda
Date: 2020-07-13T15:28:46+01:00
New Revision: 13fec93a77fa159d700eff40b27402520eed2dfa

URL: https://github.com/llvm/llvm-project/commit/13fec93a77fa159d700eff40b27402520eed2dfa
DIFF: https://github.com/llvm/llvm-project/commit/13fec93a77fa159d700eff40b27402520eed2dfa.diff

LOG: [NFC] rename to reflect F is not necessarily an Intrinsic

Added: 
    

Modified: 
    llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp

Removed: 
    


################################################################################
diff  --git a/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp b/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp
index fe9ea2995377..5bc35aa4695f 100644
--- a/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp
+++ b/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp
@@ -3039,7 +3039,7 @@ void BoUpSLP::buildTree_rec(ArrayRef<Value *> VL, unsigned Depth,
         LLVM_DEBUG(dbgs() << "SLP: Non-vectorizable call.\n");
         return;
       }
-      Function *Int = CI->getCalledFunction();
+      Function *F = CI->getCalledFunction();
       unsigned NumArgs = CI->getNumArgOperands();
       SmallVector<Value*, 4> ScalarArgs(NumArgs, nullptr);
       for (unsigned j = 0; j != NumArgs; ++j)
@@ -3047,7 +3047,7 @@ void BoUpSLP::buildTree_rec(ArrayRef<Value *> VL, unsigned Depth,
           ScalarArgs[j] = CI->getArgOperand(j);
       for (Value *V : VL) {
         CallInst *CI2 = dyn_cast<CallInst>(V);
-        if (!CI2 || CI2->getCalledFunction() != Int ||
+        if (!CI2 || CI2->getCalledFunction() != F ||
             getVectorIntrinsicIDForCall(CI2, TLI) != ID ||
             (VecFunc &&
              VecFunc != VFDatabase(*CI2).getVectorizedFunction(Shape)) ||
@@ -4542,9 +4542,8 @@ Value *BoUpSLP::vectorizeTree(TreeEntry *E) {
             false /*HasGlobalPred*/);
         CF = VFDatabase(*CI).getVectorizedFunction(Shape);
       } else {
-        Module *M = F->getParent();
         Type *Tys[] = {FixedVectorType::get(CI->getType(), E->Scalars.size())};
-        CF = Intrinsic::getDeclaration(M, ID, Tys);
+        CF = Intrinsic::getDeclaration(F->getParent(), ID, Tys);
       }
 
       SmallVector<OperandBundleDef, 1> OpBundles;


        


More information about the llvm-commits mailing list