mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-23 01:24:30 +00:00
Feed AA to the inliner and use AA->getModRefBehavior in AddAliasScopeMetadata
This feeds AA through the IFI structure into the inliner so that AddAliasScopeMetadata can use AA->getModRefBehavior to figure out which functions only access their arguments (instead of just hard-coding some knowledge of memory intrinsics). Most of the information is only available from BasicAA; this is important for preserving alias scoping information for target-specific intrinsics when doing the noalias parameter attribute to metadata conversion. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@216866 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -43,6 +43,7 @@ class DataLayout;
|
||||
class Loop;
|
||||
class LoopInfo;
|
||||
class AllocaInst;
|
||||
class AliasAnalysis;
|
||||
|
||||
/// CloneModule - Return an exact copy of the specified module
|
||||
///
|
||||
@ -157,13 +158,16 @@ void CloneAndPruneFunctionInto(Function *NewFunc, const Function *OldFunc,
|
||||
/// InlineFunction call, and records the auxiliary results produced by it.
|
||||
class InlineFunctionInfo {
|
||||
public:
|
||||
explicit InlineFunctionInfo(CallGraph *cg = nullptr, const DataLayout *DL = nullptr)
|
||||
: CG(cg), DL(DL) {}
|
||||
explicit InlineFunctionInfo(CallGraph *cg = nullptr,
|
||||
const DataLayout *DL = nullptr,
|
||||
AliasAnalysis *AA = nullptr)
|
||||
: CG(cg), DL(DL), AA(AA) {}
|
||||
|
||||
/// CG - If non-null, InlineFunction will update the callgraph to reflect the
|
||||
/// changes it makes.
|
||||
CallGraph *CG;
|
||||
const DataLayout *DL;
|
||||
AliasAnalysis *AA;
|
||||
|
||||
/// StaticAllocas - InlineFunction fills this in with all static allocas that
|
||||
/// get copied into the caller.
|
||||
|
Reference in New Issue
Block a user