summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Analysis/NoAliasAnalysis.cpp
diff options
context:
space:
mode:
authorChandler Carruth <chandlerc@gmail.com>2015-07-22 23:15:57 +0000
committerChandler Carruth <chandlerc@gmail.com>2015-07-22 23:15:57 +0000
commit194f59ca5d2f48f1e0b7fa95971ae9f88e95ba95 (patch)
tree67fa8610cb1dccceeb055c823d16d438fed256d5 /llvm/lib/Analysis/NoAliasAnalysis.cpp
parent16fe4d178e9d81b07e8deb59a4b4292850364898 (diff)
downloadbcm5719-llvm-194f59ca5d2f48f1e0b7fa95971ae9f88e95ba95.tar.gz
bcm5719-llvm-194f59ca5d2f48f1e0b7fa95971ae9f88e95ba95.zip
[PM/AA] Extract the ModRef enums from the AliasAnalysis class in
preparation for de-coupling the AA implementations. In order to do this, they had to become fake-scoped using the traditional LLVM pattern of a leading initialism. These can't be actual scoped enumerations because they're bitfields and thus inherently we use them as integers. I've also renamed the behavior enums that are specific to reasoning about the mod/ref behavior of functions when called. This makes it more clear that they have a very narrow domain of applicability. I think there is a significantly cleaner API for all of this, but I don't want to try to do really substantive changes for now, I just want to refactor the things away from analysis groups so I'm preserving the exact original design and just cleaning up the names, style, and lifting out of the class. Differential Revision: http://reviews.llvm.org/D10564 llvm-svn: 242963
Diffstat (limited to 'llvm/lib/Analysis/NoAliasAnalysis.cpp')
-rw-r--r--llvm/lib/Analysis/NoAliasAnalysis.cpp26
1 files changed, 13 insertions, 13 deletions
diff --git a/llvm/lib/Analysis/NoAliasAnalysis.cpp b/llvm/lib/Analysis/NoAliasAnalysis.cpp
index 1d21ed75954..aa78ceab89c 100644
--- a/llvm/lib/Analysis/NoAliasAnalysis.cpp
+++ b/llvm/lib/Analysis/NoAliasAnalysis.cpp
@@ -46,29 +46,29 @@ namespace {
return MayAlias;
}
- ModRefBehavior getModRefBehavior(ImmutableCallSite CS) override {
- return UnknownModRefBehavior;
+ FunctionModRefBehavior getModRefBehavior(ImmutableCallSite CS) override {
+ return FMRB_UnknownModRefBehavior;
}
- ModRefBehavior getModRefBehavior(const Function *F) override {
- return UnknownModRefBehavior;
+ FunctionModRefBehavior getModRefBehavior(const Function *F) override {
+ return FMRB_UnknownModRefBehavior;
}
bool pointsToConstantMemory(const MemoryLocation &Loc,
bool OrLocal) override {
return false;
}
- ModRefResult getArgModRefInfo(ImmutableCallSite CS,
- unsigned ArgIdx) override {
- return ModRef;
+ ModRefInfo getArgModRefInfo(ImmutableCallSite CS,
+ unsigned ArgIdx) override {
+ return MRI_ModRef;
}
- ModRefResult getModRefInfo(ImmutableCallSite CS,
- const MemoryLocation &Loc) override {
- return ModRef;
+ ModRefInfo getModRefInfo(ImmutableCallSite CS,
+ const MemoryLocation &Loc) override {
+ return MRI_ModRef;
}
- ModRefResult getModRefInfo(ImmutableCallSite CS1,
- ImmutableCallSite CS2) override {
- return ModRef;
+ ModRefInfo getModRefInfo(ImmutableCallSite CS1,
+ ImmutableCallSite CS2) override {
+ return MRI_ModRef;
}
/// getAdjustedAnalysisPointer - This method is used when a pass implements
OpenPOWER on IntegriCloud