diff options
author | Chris Lattner <sabre@nondot.org> | 2011-06-17 06:57:15 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2011-06-17 06:57:15 +0000 |
commit | 59345c8b658a2203bb9fc232ce3b92d2fc9c12ae (patch) | |
tree | 3a868c8b1eb5b86311bcecb096413ece8ebaafa4 /llvm/lib/AsmParser/LLParser.cpp | |
parent | 640767fff6554824ed16975cf1fee73257161e85 (diff) | |
download | bcm5719-llvm-59345c8b658a2203bb9fc232ce3b92d2fc9c12ae.tar.gz bcm5719-llvm-59345c8b658a2203bb9fc232ce3b92d2fc9c12ae.zip |
remove asmparser support for the old getresult instruction, which has been subsumed by extractvalue.
llvm-svn: 133247
Diffstat (limited to 'llvm/lib/AsmParser/LLParser.cpp')
-rw-r--r-- | llvm/lib/AsmParser/LLParser.cpp | 20 |
1 files changed, 0 insertions, 20 deletions
diff --git a/llvm/lib/AsmParser/LLParser.cpp b/llvm/lib/AsmParser/LLParser.cpp index 024d013b814..ab3b86e018d 100644 --- a/llvm/lib/AsmParser/LLParser.cpp +++ b/llvm/lib/AsmParser/LLParser.cpp @@ -3024,7 +3024,6 @@ int LLParser::ParseInstruction(Instruction *&Inst, BasicBlock *BB, return ParseStore(Inst, PFS, true); else return TokError("expected 'load' or 'store'"); - case lltok::kw_getresult: return ParseGetResult(Inst, PFS); case lltok::kw_getelementptr: return ParseGetElementPtr(Inst, PFS); case lltok::kw_extractvalue: return ParseExtractValue(Inst, PFS); case lltok::kw_insertvalue: return ParseInsertValue(Inst, PFS); @@ -3717,25 +3716,6 @@ int LLParser::ParseStore(Instruction *&Inst, PerFunctionState &PFS, return AteExtraComma ? InstExtraComma : InstNormal; } -/// ParseGetResult -/// ::= 'getresult' TypeAndValue ',' i32 -/// FIXME: Remove support for getresult in LLVM 3.0 -bool LLParser::ParseGetResult(Instruction *&Inst, PerFunctionState &PFS) { - Value *Val; LocTy ValLoc, EltLoc; - unsigned Element; - if (ParseTypeAndValue(Val, ValLoc, PFS) || - ParseToken(lltok::comma, "expected ',' after getresult operand") || - ParseUInt32(Element, EltLoc)) - return true; - - if (!Val->getType()->isStructTy() && !Val->getType()->isArrayTy()) - return Error(ValLoc, "getresult inst requires an aggregate operand"); - if (!ExtractValueInst::getIndexedType(Val->getType(), Element)) - return Error(EltLoc, "invalid getresult index for value"); - Inst = ExtractValueInst::Create(Val, Element); - return false; -} - /// ParseGetElementPtr /// ::= 'getelementptr' 'inbounds'? TypeAndValue (',' TypeAndValue)* int LLParser::ParseGetElementPtr(Instruction *&Inst, PerFunctionState &PFS) { |