Skip to content

Commit

Permalink
Move helper classes into anonymous namespaces.
Browse files Browse the repository at this point in the history
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@185262 91177308-0d34-0410-b5e6-96231b3b80d8
  • Loading branch information
d0k committed Jun 29, 2013
1 parent c22a4ee commit 3298179
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions lib/Transforms/Vectorize/LoopVectorize.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2856,6 +2856,7 @@ void LoopVectorizationLegality::collectLoopUniforms() {
}
}

namespace {
/// \brief Analyses memory accesses in a loop.
///
/// Checks whether run time pointer checks are needed and builds sets for data
Expand Down Expand Up @@ -2944,6 +2945,8 @@ class AccessAnalysis {
bool IsRTCheckNeeded;
};

} // end anonymous namespace

/// \brief Check whether a pointer can participate in a runtime bounds check.
static bool hasComputableBounds(ScalarEvolution *SE, Value *Ptr) {
const SCEV *PtrScev = SE->getSCEV(Ptr);
Expand Down Expand Up @@ -3102,6 +3105,7 @@ void AccessAnalysis::processMemAccesses(bool UseDeferred) {
}
}

namespace {
/// \brief Checks memory dependences among accesses to the same underlying
/// object to determine whether there vectorization is legal or not (and at
/// which vectorization factor).
Expand Down Expand Up @@ -3206,6 +3210,8 @@ class MemoryDepChecker {
bool couldPreventStoreLoadForward(unsigned Distance, unsigned TypeByteSize);
};

} // end anonymous namespace

static bool isInBoundsGep(Value *Ptr) {
if (GetElementPtrInst *GEP = dyn_cast<GetElementPtrInst>(Ptr))
return GEP->isInBounds();
Expand Down

0 comments on commit 3298179

Please sign in to comment.