comparison lib/Transforms/ObjCARC/ObjCARCAliasAnalysis.h @ 77:54457678186b LLVM3.6

LLVM 3.6
author Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
date Mon, 08 Sep 2014 22:06:00 +0900
parents 95c75e76d11b
children
comparison
equal deleted inserted replaced
34:e874dbf0ad9d 77:54457678186b
18 /// used. Naive LLVM IR transformations which would otherwise be 18 /// used. Naive LLVM IR transformations which would otherwise be
19 /// behavior-preserving may break these assumptions. 19 /// behavior-preserving may break these assumptions.
20 /// 20 ///
21 //===----------------------------------------------------------------------===// 21 //===----------------------------------------------------------------------===//
22 22
23 #ifndef LLVM_TRANSFORMS_OBJCARC_OBJCARCALIASANALYSIS_H 23 #ifndef LLVM_LIB_TRANSFORMS_OBJCARC_OBJCARCALIASANALYSIS_H
24 #define LLVM_TRANSFORMS_OBJCARC_OBJCARCALIASANALYSIS_H 24 #define LLVM_LIB_TRANSFORMS_OBJCARC_OBJCARCALIASANALYSIS_H
25 25
26 #include "llvm/Analysis/AliasAnalysis.h" 26 #include "llvm/Analysis/AliasAnalysis.h"
27 #include "llvm/Pass.h" 27 #include "llvm/Pass.h"
28 28
29 namespace llvm { 29 namespace llvm {
42 ObjCARCAliasAnalysis() : ImmutablePass(ID) { 42 ObjCARCAliasAnalysis() : ImmutablePass(ID) {
43 initializeObjCARCAliasAnalysisPass(*PassRegistry::getPassRegistry()); 43 initializeObjCARCAliasAnalysisPass(*PassRegistry::getPassRegistry());
44 } 44 }
45 45
46 private: 46 private:
47 virtual void initializePass() { 47 void initializePass() override {
48 InitializeAliasAnalysis(this); 48 InitializeAliasAnalysis(this);
49 } 49 }
50 50
51 /// This method is used when a pass implements an analysis interface through 51 /// This method is used when a pass implements an analysis interface through
52 /// multiple inheritance. If needed, it should override this to adjust the 52 /// multiple inheritance. If needed, it should override this to adjust the
53 /// this pointer as needed for the specified pass info. 53 /// this pointer as needed for the specified pass info.
54 virtual void *getAdjustedAnalysisPointer(const void *PI) { 54 void *getAdjustedAnalysisPointer(const void *PI) override {
55 if (PI == &AliasAnalysis::ID) 55 if (PI == &AliasAnalysis::ID)
56 return static_cast<AliasAnalysis *>(this); 56 return static_cast<AliasAnalysis *>(this);
57 return this; 57 return this;
58 } 58 }
59 59
60 virtual void getAnalysisUsage(AnalysisUsage &AU) const; 60 void getAnalysisUsage(AnalysisUsage &AU) const override;
61 virtual AliasResult alias(const Location &LocA, const Location &LocB); 61 AliasResult alias(const Location &LocA, const Location &LocB) override;
62 virtual bool pointsToConstantMemory(const Location &Loc, bool OrLocal); 62 bool pointsToConstantMemory(const Location &Loc, bool OrLocal) override;
63 virtual ModRefBehavior getModRefBehavior(ImmutableCallSite CS); 63 ModRefBehavior getModRefBehavior(ImmutableCallSite CS) override;
64 virtual ModRefBehavior getModRefBehavior(const Function *F); 64 ModRefBehavior getModRefBehavior(const Function *F) override;
65 virtual ModRefResult getModRefInfo(ImmutableCallSite CS, 65 ModRefResult getModRefInfo(ImmutableCallSite CS,
66 const Location &Loc); 66 const Location &Loc) override;
67 virtual ModRefResult getModRefInfo(ImmutableCallSite CS1, 67 ModRefResult getModRefInfo(ImmutableCallSite CS1,
68 ImmutableCallSite CS2); 68 ImmutableCallSite CS2) override;
69 }; 69 };
70 70
71 } // namespace objcarc 71 } // namespace objcarc
72 } // namespace llvm 72 } // namespace llvm
73 73
74 #endif // LLVM_TRANSFORMS_OBJCARC_OBJCARCALIASANALYSIS_H 74 #endif