mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-13 22:24:07 +00:00
add a method to compute a commonly used mapping.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20588 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -2082,3 +2082,16 @@ void DSGraph::computeNodeMapping(const DSNodeHandle &NH1,
|
||||
computeNodeMapping(N1->getLink(i),
|
||||
N2->getLink(unsigned(N2Idx+i) % N2Size), NodeMap);
|
||||
}
|
||||
|
||||
|
||||
/// computeGlobalGraphMapping - Compute the mapping of nodes in the global
|
||||
/// graph to nodes in this graph.
|
||||
void DSGraph::computeGlobalGraphMapping(NodeMapTy &NodeMap) {
|
||||
DSGraph &GG = *getGlobalsGraph();
|
||||
|
||||
DSScalarMap &SM = getScalarMap();
|
||||
for (DSScalarMap::global_iterator I = SM.global_begin(),
|
||||
E = SM.global_end(); I != E; ++I)
|
||||
DSGraph::computeNodeMapping(SM[*I], GG.getNodeForValue(*I), NodeMap);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user