summaryrefslogtreecommitdiff
path: root/lib/Analysis/MemoryBuiltins.cpp
diff options
context:
space:
mode:
authorNuno Lopes <nunoplopes@sapo.pt>2012-05-03 22:08:19 +0000
committerNuno Lopes <nunoplopes@sapo.pt>2012-05-03 22:08:19 +0000
commitcb348b9b45025393ec5b28eac8bb6773a9b603f6 (patch)
tree74049a21e8b92bf60a169e917a10f934361363cc /lib/Analysis/MemoryBuiltins.cpp
parent26f61a158b3cce69252c05cc0e79f500d6c3d92e (diff)
downloadllvm-cb348b9b45025393ec5b28eac8bb6773a9b603f6.tar.gz
llvm-cb348b9b45025393ec5b28eac8bb6773a9b603f6.tar.bz2
llvm-cb348b9b45025393ec5b28eac8bb6773a9b603f6.tar.xz
remove calls to calloc if the allocated memory is not used (it was already being done for malloc)
fix a few typos found by Chad in my previous commit git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@156110 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Analysis/MemoryBuiltins.cpp')
-rw-r--r--lib/Analysis/MemoryBuiltins.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/Analysis/MemoryBuiltins.cpp b/lib/Analysis/MemoryBuiltins.cpp
index 347a7ea7a8..9695ae1dec 100644
--- a/lib/Analysis/MemoryBuiltins.cpp
+++ b/lib/Analysis/MemoryBuiltins.cpp
@@ -182,7 +182,7 @@ Value *llvm::getMallocArraySize(CallInst *CI, const TargetData *TD,
//===----------------------------------------------------------------------===//
-// clloc Call Utility Functions.
+// calloc Call Utility Functions.
//
static bool isCallocCall(const CallInst *CI) {
@@ -197,7 +197,7 @@ static bool isCallocCall(const CallInst *CI) {
// Check malloc prototype.
// FIXME: workaround for PR5130, this will be obsolete when a nobuiltin
- // attribute will exist.
+ // attribute exists.
FunctionType *FTy = Callee->getFunctionType();
return FTy->getReturnType() == Type::getInt8PtrTy(FTy->getContext()) &&
FTy->getNumParams() == 2 &&