From: Dan Gohman Date: Mon, 9 Jun 2008 14:09:13 +0000 (+0000) Subject: Abort on an unrecognized opcode. X-Git-Url: http://plrg.eecs.uci.edu/git/?a=commitdiff_plain;h=26825a84e97790adaffc55c6101b9fe2524fe1b7;p=oota-llvm.git Abort on an unrecognized opcode. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52146 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Target/CppBackend/CPPBackend.cpp b/lib/Target/CppBackend/CPPBackend.cpp index 22dd3058de0..8b450304d47 100644 --- a/lib/Target/CppBackend/CPPBackend.cpp +++ b/lib/Target/CppBackend/CPPBackend.cpp @@ -1065,6 +1065,10 @@ namespace { } switch (I->getOpcode()) { + default: + error("Invalid instruction"); + break; + case Instruction::Ret: { const ReturnInst* ret = cast(I); Out << "ReturnInst::Create("