X-Git-Url: http://plrg.eecs.uci.edu/git/?p=oota-llvm.git;a=blobdiff_plain;f=lib%2FBitcode%2FReader%2FBitcodeReader.cpp;fp=lib%2FBitcode%2FReader%2FBitcodeReader.cpp;h=210ffd8d912ed5112d7adfb5567c42d6ba70d28e;hp=e85cf4d8ebda3f15c70f7b9a5e9152856af19964;hb=868145efb053c3f9294676cf4f36d6220e500269;hpb=16cba6923a59f37985c34484a64879b7bca263bd diff --git a/lib/Bitcode/Reader/BitcodeReader.cpp b/lib/Bitcode/Reader/BitcodeReader.cpp index e85cf4d8ebd..210ffd8d912 100644 --- a/lib/Bitcode/Reader/BitcodeReader.cpp +++ b/lib/Bitcode/Reader/BitcodeReader.cpp @@ -4484,40 +4484,6 @@ std::error_code BitcodeReader::parseFunctionBody(Function *F) { InstructionList.push_back(I); break; } - case bitc::FUNC_CODE_INST_TERMINATEPAD: { // TERMINATEPAD: [tok,bb#,num,(ty,val)*] - // We must have, at minimum, the outer scope and the number of arguments. - if (Record.size() < 2) - return error("Invalid record"); - - unsigned Idx = 0; - - Value *ParentPad = - getValue(Record, Idx++, NextValueNo, Type::getTokenTy(Context)); - - unsigned NumArgOperands = Record[Idx++]; - - SmallVector Args; - for (unsigned Op = 0; Op != NumArgOperands; ++Op) { - Value *Val; - if (getValueTypePair(Record, Idx, NextValueNo, Val)) - return error("Invalid record"); - Args.push_back(Val); - } - - BasicBlock *UnwindDest = nullptr; - if (Idx + 1 == Record.size()) { - UnwindDest = getBasicBlock(Record[Idx++]); - if (!UnwindDest) - return error("Invalid record"); - } - - if (Record.size() != Idx) - return error("Invalid record"); - - I = TerminatePadInst::Create(ParentPad, UnwindDest, Args); - InstructionList.push_back(I); - break; - } case bitc::FUNC_CODE_INST_CATCHPAD: case bitc::FUNC_CODE_INST_CLEANUPPAD: { // [tok,num,(ty,val)*] // We must have, at minimum, the outer scope and the number of arguments.