aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2008-02-03 07:13:32 +0000
committerChris Lattner <sabre@nondot.org>2008-02-03 07:13:32 +0000
commit2d41a227a7422ac991a8412ddd0c7c1c5374f24e (patch)
treed4c7c5d293dc836b5635a25448f47962ceb85772 /lib
parent0fdf4edd2d64ee5d6bdb5d66beed0da325e5e117 (diff)
downloadexternal_llvm-2d41a227a7422ac991a8412ddd0c7c1c5374f24e.zip
external_llvm-2d41a227a7422ac991a8412ddd0c7c1c5374f24e.tar.gz
external_llvm-2d41a227a7422ac991a8412ddd0c7c1c5374f24e.tar.bz2
handle the case where a node can become ready to process
multiple times due to a RAUW. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@46680 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r--lib/CodeGen/SelectionDAG/LegalizeTypes.cpp3
-rw-r--r--lib/CodeGen/SelectionDAG/LegalizeTypes.h4
2 files changed, 4 insertions, 3 deletions
diff --git a/lib/CodeGen/SelectionDAG/LegalizeTypes.cpp b/lib/CodeGen/SelectionDAG/LegalizeTypes.cpp
index 85a96a8..76b7527 100644
--- a/lib/CodeGen/SelectionDAG/LegalizeTypes.cpp
+++ b/lib/CodeGen/SelectionDAG/LegalizeTypes.cpp
@@ -234,7 +234,8 @@ namespace {
// Node updates can mean pretty much anything. It is possible that an
// operand was set to something already processed (f.e.) in which case
// this node could become ready. Recompoute its flags.
- DTL.ReanalyzeNodeFlags(N);
+ if (N->getNodeId() != DAGTypeLegalizer::ReadyToProcess)
+ DTL.ReanalyzeNodeFlags(N);
}
};
}
diff --git a/lib/CodeGen/SelectionDAG/LegalizeTypes.h b/lib/CodeGen/SelectionDAG/LegalizeTypes.h
index 912747d..23d9bf1 100644
--- a/lib/CodeGen/SelectionDAG/LegalizeTypes.h
+++ b/lib/CodeGen/SelectionDAG/LegalizeTypes.h
@@ -40,7 +40,7 @@ namespace llvm {
class VISIBILITY_HIDDEN DAGTypeLegalizer {
TargetLowering &TLI;
SelectionDAG &DAG;
-
+public:
// NodeIDFlags - This pass uses the NodeID on the SDNodes to hold information
// about the state of the node. The enum has all the values.
enum NodeIDFlags {
@@ -57,7 +57,7 @@ class VISIBILITY_HIDDEN DAGTypeLegalizer {
// 1+ - This is a node which has this many unlegalized operands.
};
-
+private:
enum LegalizeAction {
Legal, // The target natively supports this type.
Promote, // This type should be executed in a larger type.