[llvm] r225542 - Remove duplicating code. NFC.

Michael Zolotukhin mzolotukhin at apple.com
Fri Jan 9 12:36:19 PST 2015


Author: mzolotukhin
Date: Fri Jan  9 14:36:19 2015
New Revision: 225542

URL: http://llvm.org/viewvc/llvm-project?rev=225542&view=rev
Log:
Remove duplicating code. NFC.

The removed condition is checked in the previous loop.

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

Modified: llvm/trunk/lib/Transforms/Vectorize/SLPVectorizer.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Vectorize/SLPVectorizer.cpp?rev=225542&r1=225541&r2=225542&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Vectorize/SLPVectorizer.cpp (original)
+++ llvm/trunk/lib/Transforms/Vectorize/SLPVectorizer.cpp Fri Jan  9 14:36:19 2015
@@ -1034,8 +1034,8 @@ void BoUpSLP::buildTree_rec(ArrayRef<Val
   // If any of the scalars appears in the table OR it is marked as a value that
   // needs to stat scalar then we need to gather the scalars.
   for (unsigned i = 0, e = VL.size(); i != e; ++i) {
-    if (ScalarToTreeEntry.count(VL[i]) || MustGather.count(VL[i])) {
-      DEBUG(dbgs() << "SLP: Gathering due to gathered scalar. \n");
+    if (MustGather.count(VL[i])) {
+      DEBUG(dbgs() << "SLP: Gathering due to gathered scalar.\n");
       newTreeEntry(VL, false);
       return;
     }





More information about the llvm-commits mailing list