mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-30 02:25:19 +00:00
Factor out the code for testing whether a function accesses
arbitrary memory into a helper function, and adjust some comments. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@118687 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -131,9 +131,8 @@ bool FunctionAttrs::AddReadAttrs(const CallGraphSCC &SCC) {
|
||||
AliasAnalysis::ModRefBehavior MRB = AA->getModRefBehavior(CS);
|
||||
// If the call doesn't access arbitrary memory, we may be able to
|
||||
// figure out something.
|
||||
if (!(MRB & AliasAnalysis::Anywhere &
|
||||
~AliasAnalysis::ArgumentPointees)) {
|
||||
// If the call accesses argument pointees, check each argument.
|
||||
if (AliasAnalysis::onlyAccessesArgPointees(MRB)) {
|
||||
// If the call does access argument pointees, check each argument.
|
||||
if (MRB & AliasAnalysis::AccessesArguments)
|
||||
// Check whether all pointer arguments point to local memory, and
|
||||
// ignore calls that only access local memory.
|
||||
|
Reference in New Issue
Block a user