diff options
| author | Dan Gohman <gohman@apple.com> | 2009-07-25 00:48:42 +0000 | 
|---|---|---|
| committer | Dan Gohman <gohman@apple.com> | 2009-07-25 00:48:42 +0000 | 
| commit | 43d19d61d4ab124462152de2e0848ce4b2d8bdbe (patch) | |
| tree | 8e538a4de4f5983ae947a898d140bc7debf7a117 /llvm/lib/Analysis/AliasSetTracker.cpp | |
| parent | 67395e7c2c1c9ed95b147bd13ff25cf8b9983685 (diff) | |
| download | llvm-43d19d61d4ab124462152de2e0848ce4b2d8bdbe.zip llvm-43d19d61d4ab124462152de2e0848ce4b2d8bdbe.tar.gz llvm-43d19d61d4ab124462152de2e0848ce4b2d8bdbe.tar.bz2  | |
Make AliasAnalysis and related classes use
getAnalysisIfAvailable<TargetData>().
llvm-svn: 77028
Diffstat (limited to 'llvm/lib/Analysis/AliasSetTracker.cpp')
| -rw-r--r-- | llvm/lib/Analysis/AliasSetTracker.cpp | 9 | 
1 files changed, 4 insertions, 5 deletions
diff --git a/llvm/lib/Analysis/AliasSetTracker.cpp b/llvm/lib/Analysis/AliasSetTracker.cpp index 801628e..841cd2b 100644 --- a/llvm/lib/Analysis/AliasSetTracker.cpp +++ b/llvm/lib/Analysis/AliasSetTracker.cpp @@ -280,7 +280,7 @@ bool AliasSetTracker::add(Value *Ptr, unsigned Size) {  bool AliasSetTracker::add(LoadInst *LI) {    bool NewPtr;    AliasSet &AS = addPointer(LI->getOperand(0), -                            AA.getTargetData().getTypeStoreSize(LI->getType()), +                            AA.getTypeStoreSize(LI->getType()),                              AliasSet::Refs, NewPtr);    if (LI->isVolatile()) AS.setVolatile();    return NewPtr; @@ -290,7 +290,7 @@ bool AliasSetTracker::add(StoreInst *SI) {    bool NewPtr;    Value *Val = SI->getOperand(0);    AliasSet &AS = addPointer(SI->getOperand(1), -                            AA.getTargetData().getTypeStoreSize(Val->getType()), +                            AA.getTypeStoreSize(Val->getType()),                              AliasSet::Mods, NewPtr);    if (SI->isVolatile()) AS.setVolatile();    return NewPtr; @@ -412,7 +412,7 @@ bool AliasSetTracker::remove(Value *Ptr, unsigned Size) {  }  bool AliasSetTracker::remove(LoadInst *LI) { -  unsigned Size = AA.getTargetData().getTypeStoreSize(LI->getType()); +  unsigned Size = AA.getTypeStoreSize(LI->getType());    AliasSet *AS = findAliasSetForPointer(LI->getOperand(0), Size);    if (!AS) return false;    remove(*AS); @@ -420,8 +420,7 @@ bool AliasSetTracker::remove(LoadInst *LI) {  }  bool AliasSetTracker::remove(StoreInst *SI) { -  unsigned Size = -    AA.getTargetData().getTypeStoreSize(SI->getOperand(0)->getType()); +  unsigned Size = AA.getTypeStoreSize(SI->getOperand(0)->getType());    AliasSet *AS = findAliasSetForPointer(SI->getOperand(1), Size);    if (!AS) return false;    remove(*AS);  | 
