aboutsummaryrefslogtreecommitdiffstats
path: root/include/llvm/Analysis
diff options
context:
space:
mode:
authorNadav Rotem <nrotem@apple.com>2013-04-09 18:16:05 +0000
committerNadav Rotem <nrotem@apple.com>2013-04-09 18:16:05 +0000
commit8e4df489d0e02e0fbdd00ed829e70e5f21998162 (patch)
treeaaf942d501b6b4ced668cda0c66e5d4c3117f0bc /include/llvm/Analysis
parentb976e407dcd7794eb9e151b81cdc8fbbe05e6bd8 (diff)
downloadexternal_llvm-8e4df489d0e02e0fbdd00ed829e70e5f21998162.zip
external_llvm-8e4df489d0e02e0fbdd00ed829e70e5f21998162.tar.gz
external_llvm-8e4df489d0e02e0fbdd00ed829e70e5f21998162.tar.bz2
Revert r176408 and r176407 to address PR15540.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@179111 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/Analysis')
-rw-r--r--include/llvm/Analysis/MemoryBuiltins.h12
1 files changed, 1 insertions, 11 deletions
diff --git a/include/llvm/Analysis/MemoryBuiltins.h b/include/llvm/Analysis/MemoryBuiltins.h
index 63262eb..4883383 100644
--- a/include/llvm/Analysis/MemoryBuiltins.h
+++ b/include/llvm/Analysis/MemoryBuiltins.h
@@ -146,14 +146,6 @@ static inline CallInst *isFreeCall(Value *I, const TargetLibraryInfo *TLI) {
bool getObjectSize(const Value *Ptr, uint64_t &Size, const DataLayout *TD,
const TargetLibraryInfo *TLI, bool RoundToAlign = false);
-/// \brief Compute the size of the underlying object pointed by Ptr. Returns
-/// true and the object size in Size if successful, and false otherwise.
-/// If RoundToAlign is true, then Size is rounded up to the aligment of allocas,
-/// byval arguments, and global variables.
-bool getUnderlyingObjectSize(const Value *Ptr, uint64_t &Size,
- const DataLayout *TD, const TargetLibraryInfo *TLI,
- bool RoundToAlign = false);
-
typedef std::pair<APInt, APInt> SizeOffsetType;
@@ -163,14 +155,12 @@ typedef std::pair<APInt, APInt> SizeOffsetType;
class ObjectSizeOffsetVisitor
: public InstVisitor<ObjectSizeOffsetVisitor, SizeOffsetType> {
- typedef DenseMap<const Value*, SizeOffsetType> CacheMapTy;
-
const DataLayout *TD;
const TargetLibraryInfo *TLI;
bool RoundToAlign;
unsigned IntTyBits;
APInt Zero;
- CacheMapTy CacheMap;
+ SmallPtrSet<Instruction *, 8> SeenInsts;
APInt align(APInt Size, uint64_t Align);