Fix a node mapping problem that was causing the pool allocator to locally allocate

nodes that were globally live, thus breaking programs.

llvm-svn: 12094
This commit is contained in:
Chris Lattner 2004-03-03 05:34:31 +00:00
parent 93e9878c2c
commit 140b2cbd28
1 changed files with 3 additions and 0 deletions

View File

@ -1847,4 +1847,7 @@ void DSGraph::computeNodeMapping(const DSNodeHandle &NH1,
for (unsigned i = 0, e = N1->getSize(); i < e; i += DS::PointerSize)
if (unsigned(N2Idx)+i < N2Size)
computeNodeMapping(N1->getLink(i), N2->getLink(N2Idx+i), NodeMap);
else
computeNodeMapping(N1->getLink(i),
N2->getLink(unsigned(N2Idx+i) % N2Size), NodeMap);
}