diff options
author | Dan Gohman <gohman@apple.com> | 2009-11-18 00:58:27 +0000 |
---|---|---|
committer | Dan Gohman <gohman@apple.com> | 2009-11-18 00:58:27 +0000 |
commit | 3dbb9e64d6e9d1e8bf16f75ebe4fe59ffdf93dd3 (patch) | |
tree | eb1ba91cca452635f06247f3af86ae531866772e /lib/Analysis/MemoryBuiltins.cpp | |
parent | 5052c1547ef75f401fd397084831e0bb15311b09 (diff) |
Simplify ComputeMultiple so that it doesn't depend on TargetData.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@89175 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Analysis/MemoryBuiltins.cpp')
-rw-r--r-- | lib/Analysis/MemoryBuiltins.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/Analysis/MemoryBuiltins.cpp b/lib/Analysis/MemoryBuiltins.cpp index 9f036f4e2a..b4486283fe 100644 --- a/lib/Analysis/MemoryBuiltins.cpp +++ b/lib/Analysis/MemoryBuiltins.cpp @@ -105,9 +105,8 @@ static Value *computeArraySize(const CallInst *CI, const TargetData *TD, // return the multiple. Otherwise, return NULL. Value *MallocArg = CI->getOperand(1); Value *Multiple = NULL; - APInt Val(TD->getTypeSizeInBits(MallocArg->getType()->getScalarType()), 0); if (ComputeMultiple(MallocArg, ElementSize, Multiple, - Val, LookThroughSExt, TD)) + LookThroughSExt)) return Multiple; return NULL; |