Disable integer tracking by default

llvm-svn: 9960
This commit is contained in:
Chris Lattner 2003-11-13 03:10:49 +00:00
parent 97cf7cf400
commit fb4c057c4c
1 changed files with 6 additions and 1 deletions

View File

@ -33,13 +33,18 @@ using namespace llvm;
static RegisterAnalysis<LocalDataStructures>
X("datastructure", "Local Data Structure Analysis");
static cl::opt<bool>
TrackIntegersAsPointers("dsa-track-integers",
cl::desc("If this is set, track integers as potential pointers"));
namespace llvm {
namespace DS {
// isPointerType - Return true if this type is big enough to hold a pointer.
bool isPointerType(const Type *Ty) {
if (isa<PointerType>(Ty))
return true;
else if (Ty->isPrimitiveType() && Ty->isInteger())
else if (TrackIntegersAsPointers && Ty->isPrimitiveType() &&Ty->isInteger())
return Ty->getPrimitiveSize() >= PointerSize;
return false;
}