mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-22 23:24:59 +00:00
[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 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@242963 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -481,9 +481,9 @@ static void AddAliasScopeMetadata(CallSite CS, ValueToValueMapTy &VMap,
|
||||
|
||||
IsFuncCall = true;
|
||||
if (AA) {
|
||||
AliasAnalysis::ModRefBehavior MRB = AA->getModRefBehavior(ICS);
|
||||
if (MRB == AliasAnalysis::OnlyAccessesArgumentPointees ||
|
||||
MRB == AliasAnalysis::OnlyReadsArgumentPointees)
|
||||
FunctionModRefBehavior MRB = AA->getModRefBehavior(ICS);
|
||||
if (MRB == FMRB_OnlyAccessesArgumentPointees ||
|
||||
MRB == FMRB_OnlyReadsArgumentPointees)
|
||||
IsArgMemOnlyCall = true;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user