summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
diff options
context:
space:
mode:
authorJakob Stoklund Olesen <stoklund@2pi.dk>2011-02-09 21:52:06 +0000
committerJakob Stoklund Olesen <stoklund@2pi.dk>2011-02-09 21:52:06 +0000
commit6d4d8581bc085cd485e0c7b86fafa111a97a1aa5 (patch)
treeff166ea9b6a6d08dbfae84b248e7a39fe5a9753f /llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
parent8f59b46750767921e9ca398fadbffb1bd3268246 (diff)
downloadbcm5719-llvm-6d4d8581bc085cd485e0c7b86fafa111a97a1aa5.tar.gz
bcm5719-llvm-6d4d8581bc085cd485e0c7b86fafa111a97a1aa5.zip
Assert on bad jump tables.
llvm-svn: 125225
Diffstat (limited to 'llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp')
-rw-r--r--llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp b/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
index 4528a34286c..bf83f841294 100644
--- a/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
+++ b/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
@@ -1033,6 +1033,7 @@ void AsmPrinter::EmitJumpTableInfo() {
void AsmPrinter::EmitJumpTableEntry(const MachineJumpTableInfo *MJTI,
const MachineBasicBlock *MBB,
unsigned UID) const {
+ assert(MBB && MBB->getNumber() >= 0 && "Invalid basic block");
const MCExpr *Value = 0;
switch (MJTI->getEntryKind()) {
case MachineJumpTableInfo::EK_Inline:
OpenPOWER on IntegriCloud