mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2026-04-26 12:20:42 +00:00
Do partial inlining in BU. This resolves more call sites. Also add options to merge in globals during recursion and to back annotate DSNodes when function pointers are resolved. This makes PA work for a whole lot more things (unresolved call sites being what has been killing various DSA based passes)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28859 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -116,6 +116,9 @@ protected:
|
||||
/// GlobalECs - The equivalence classes for each global value that is merged
|
||||
/// with other global values in the DSGraphs.
|
||||
EquivalenceClasses<GlobalValue*> GlobalECs;
|
||||
|
||||
std::map<CallSite, std::vector<Function*> > AlreadyInlined;
|
||||
|
||||
public:
|
||||
~BUDataStructures() { releaseMyMemory(); }
|
||||
|
||||
@@ -135,6 +138,12 @@ public:
|
||||
return const_cast<BUDataStructures*>(this)->
|
||||
CreateGraphForExternalFunction(F);
|
||||
}
|
||||
|
||||
/// DSGraphExists - Is the DSGraph computed for this function?
|
||||
///
|
||||
bool doneDSGraph(const Function *F) const {
|
||||
return (DSInfo.find(const_cast<Function*>(F)) != DSInfo.end());
|
||||
}
|
||||
|
||||
DSGraph &getGlobalsGraph() const { return *GlobalsGraph; }
|
||||
|
||||
@@ -176,7 +185,7 @@ public:
|
||||
}
|
||||
|
||||
private:
|
||||
void calculateGraph(DSGraph &G);
|
||||
bool calculateGraph(DSGraph &G);
|
||||
|
||||
DSGraph &getOrCreateGraph(Function *F);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user