summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Analysis/DataStructure/DataStructure.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2003-02-01 06:51:17 +0000
committerChris Lattner <sabre@nondot.org>2003-02-01 06:51:17 +0000
commit5965bbb02f060b02f086b54006bd442944df96cd (patch)
tree5c08bc1b97d8f62a17b68413b64c0ffd658d3151 /llvm/lib/Analysis/DataStructure/DataStructure.cpp
parentc154bdcd4cd1162e7f7d7dfd99af07ee727dd963 (diff)
downloadbcm5719-llvm-5965bbb02f060b02f086b54006bd442944df96cd.tar.gz
bcm5719-llvm-5965bbb02f060b02f086b54006bd442944df96cd.zip
Fix a bug where we would incorrectly delete globals which had edges to alive nodes in
a graph in the t-d pass. This slows down the TD pass by quite a bit (1/3), but is needed for correctness. llvm-svn: 5464
Diffstat (limited to 'llvm/lib/Analysis/DataStructure/DataStructure.cpp')
-rw-r--r--llvm/lib/Analysis/DataStructure/DataStructure.cpp3
1 files changed, 0 insertions, 3 deletions
diff --git a/llvm/lib/Analysis/DataStructure/DataStructure.cpp b/llvm/lib/Analysis/DataStructure/DataStructure.cpp
index f1b6e420bb9..2c9a75c9a85 100644
--- a/llvm/lib/Analysis/DataStructure/DataStructure.cpp
+++ b/llvm/lib/Analysis/DataStructure/DataStructure.cpp
@@ -973,9 +973,6 @@ static bool CanReachAliveNodes(DSNode *N, hash_set<DSNode*> &Alive,
if (Visited.count(N)) return false; // Found a cycle
Visited.insert(N); // No recursion, insert into Visited...
- if (N->NodeType & DSNode::GlobalNode)
- return false; // Global nodes will be marked on their own
-
for (unsigned i = 0, e = N->getSize(); i < e; i += DS::PointerSize)
if (CanReachAliveNodes(N->getLink(i).getNode(), Alive, Visited)) {
N->markReachableNodes(Alive);
OpenPOWER on IntegriCloud