summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDan Gohman <gohman@apple.com>2010-04-14 17:11:23 +0000
committerDan Gohman <gohman@apple.com>2010-04-14 17:11:23 +0000
commit0e026729aef35523e4f8d6124a569dceb4286bbb (patch)
tree7a85b293155ee85a67487da77287ab000a1dbf03
parent046fe6b6ba9851d3b8fed164493a54db3ac107e6 (diff)
downloadllvm-0e026729aef35523e4f8d6124a569dceb4286bbb.tar.gz
llvm-0e026729aef35523e4f8d6124a569dceb4286bbb.tar.bz2
llvm-0e026729aef35523e4f8d6124a569dceb4286bbb.tar.xz
Move this assert out of SelectionDAGISel into FunctionLoweringInfo, and
drop the redundant #ifndef NDEBUG. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@101261 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--lib/CodeGen/SelectionDAG/FunctionLoweringInfo.cpp3
-rw-r--r--lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp5
2 files changed, 3 insertions, 5 deletions
diff --git a/lib/CodeGen/SelectionDAG/FunctionLoweringInfo.cpp b/lib/CodeGen/SelectionDAG/FunctionLoweringInfo.cpp
index d7ed46a08a..43cc6603a4 100644
--- a/lib/CodeGen/SelectionDAG/FunctionLoweringInfo.cpp
+++ b/lib/CodeGen/SelectionDAG/FunctionLoweringInfo.cpp
@@ -243,6 +243,9 @@ void FunctionLoweringInfo::set(Function &fn, MachineFunction &mf,
/// FunctionLoweringInfo to an empty state, ready to be used for a
/// different function.
void FunctionLoweringInfo::clear() {
+ assert(CatchInfoFound.size() == CatchInfoLost.size() &&
+ "Not all catch info was assigned to a landing pad!");
+
MBBMap.clear();
ValueMap.clear();
StaticAllocaMap.clear();
diff --git a/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp b/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp
index 8583336df6..1438fe2b5d 100644
--- a/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp
+++ b/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp
@@ -221,11 +221,6 @@ bool SelectionDAGISel::runOnMachineFunction(MachineFunction &mf) {
// emitting the code for the block.
RegInfo->EmitLiveInCopies(MF->begin(), TRI, TII);
-#ifndef NDEBUG
- assert(FuncInfo->CatchInfoFound.size() == FuncInfo->CatchInfoLost.size() &&
- "Not all catch info was assigned to a landing pad!");
-#endif
-
// Release function-specific state. SDB and CurDAG are already cleared
// at this point.
FuncInfo->clear();