aboutsummaryrefslogtreecommitdiffstats
path: root/include/llvm/Transforms/Utils/BuildLibCalls.h
diff options
context:
space:
mode:
authorNuno Lopes <nunoplopes@sapo.pt>2012-07-25 17:18:59 +0000
committerNuno Lopes <nunoplopes@sapo.pt>2012-07-25 17:18:59 +0000
commita536835230afcd334068bc6f5781a244938feaf9 (patch)
treea6e5a5be9811068bd4437002b43bcecefea020f9 /include/llvm/Transforms/Utils/BuildLibCalls.h
parent84315f03cb6127ac92a5b02239c6edc2a347069a (diff)
downloadexternal_llvm-a536835230afcd334068bc6f5781a244938feaf9.zip
external_llvm-a536835230afcd334068bc6f5781a244938feaf9.tar.gz
external_llvm-a536835230afcd334068bc6f5781a244938feaf9.tar.bz2
add EmitStrNLen()
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160741 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/Transforms/Utils/BuildLibCalls.h')
-rw-r--r--include/llvm/Transforms/Utils/BuildLibCalls.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/llvm/Transforms/Utils/BuildLibCalls.h b/include/llvm/Transforms/Utils/BuildLibCalls.h
index f72600a..a6e41f0 100644
--- a/include/llvm/Transforms/Utils/BuildLibCalls.h
+++ b/include/llvm/Transforms/Utils/BuildLibCalls.h
@@ -31,6 +31,12 @@ namespace llvm {
Value *EmitStrLen(Value *Ptr, IRBuilder<> &B, const TargetData *TD,
const TargetLibraryInfo *TLI);
+ /// EmitStrNLen - Emit a call to the strnlen function to the builder, for the
+ /// specified pointer. Ptr is required to be some pointer type, MaxLen must
+ /// be of size_t type, and the return value has 'intptr_t' type.
+ Value *EmitStrNLen(Value *Ptr, Value *MaxLen, IRBuilder<> &B,
+ const TargetData *TD, const TargetLibraryInfo *TLI);
+
/// EmitStrChr - Emit a call to the strchr function to the builder, for the
/// specified pointer and character. Ptr is required to be some pointer type,
/// and the return value has 'i8*' type.