mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-08-09 11:25:55 +00:00
Fix a bug that caused the pass to go into infinite loops on trivial testcases.
This is fallout of the Bug 122 changes. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@15811 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -251,7 +251,8 @@ namespace {
|
|||||||
///
|
///
|
||||||
Node *getNode(Value *V) {
|
Node *getNode(Value *V) {
|
||||||
if (Constant *C = dyn_cast<Constant>(V))
|
if (Constant *C = dyn_cast<Constant>(V))
|
||||||
return getNodeForConstantPointer(C);
|
if (!isa<GlobalValue>(C))
|
||||||
|
return getNodeForConstantPointer(C);
|
||||||
|
|
||||||
std::map<Value*, unsigned>::iterator I = ValueNodes.find(V);
|
std::map<Value*, unsigned>::iterator I = ValueNodes.find(V);
|
||||||
if (I == ValueNodes.end()) {
|
if (I == ValueNodes.end()) {
|
||||||
|
Reference in New Issue
Block a user