mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-02-07 14:33:15 +00:00
Disable integer tracking by default
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9960 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
de0579d946
commit
a190766a54
@ -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;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user