summaryrefslogtreecommitdiff
path: root/lib/Transforms/Vectorize
diff options
context:
space:
mode:
authorEric Christopher <echristo@gmail.com>2014-04-07 12:46:30 +0000
committerEric Christopher <echristo@gmail.com>2014-04-07 12:46:30 +0000
commit231ed9dd9c34551524767ea04073c19a1c52ce2e (patch)
tree73544007be2bf2e609ef334bb02fc98fc84ee1ad /lib/Transforms/Vectorize
parentc75aecc473b3c93f920c7a70011e184a6d874fc2 (diff)
downloadllvm-231ed9dd9c34551524767ea04073c19a1c52ce2e.tar.gz
llvm-231ed9dd9c34551524767ea04073c19a1c52ce2e.tar.bz2
llvm-231ed9dd9c34551524767ea04073c19a1c52ce2e.tar.xz
Add NDEBUG markers around debug only function.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@205706 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms/Vectorize')
-rw-r--r--lib/Transforms/Vectorize/LoopVectorize.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/Transforms/Vectorize/LoopVectorize.cpp b/lib/Transforms/Vectorize/LoopVectorize.cpp
index c3b0121e6c..c5de6bc6bb 100644
--- a/lib/Transforms/Vectorize/LoopVectorize.cpp
+++ b/lib/Transforms/Vectorize/LoopVectorize.cpp
@@ -470,6 +470,8 @@ static void setDebugLocFromInst(IRBuilder<> &B, const Value *Ptr) {
else
B.SetCurrentDebugLocation(DebugLoc());
}
+
+#ifndef NDEBUG
/// \return string containing a file name and a line # for the given
/// instruction.
static format_object3<const char *, const char *, unsigned>
@@ -489,6 +491,8 @@ getDebugLocString(const Instruction *I) {
const char *FileName = Loc.getFilename().data();
return format("%s/%s:%u", DirName, FileName, LineNo);
}
+#endif
+
/// LoopVectorizationLegality checks if it is legal to vectorize a loop, and
/// to what vectorization factor.
/// This class does not look at the profitability of vectorization, only the