summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target
diff options
context:
space:
mode:
authorRichard Barton <richard.barton@arm.com>2012-06-14 10:48:04 +0000
committerRichard Barton <richard.barton@arm.com>2012-06-14 10:48:04 +0000
commitb0ec375b96260aa2235ada67c5136c999c98389f (patch)
tree1fd194b3c1b304f5eb62e6b2008421b5352a3255 /llvm/lib/Target
parentac96b764ea415c673ae6fde6a8f20516e184a7b8 (diff)
downloadbcm5719-llvm-b0ec375b96260aa2235ada67c5136c999c98389f.tar.gz
bcm5719-llvm-b0ec375b96260aa2235ada67c5136c999c98389f.zip
Replace assertion failure for badly formatted CPS instrution with error message.
llvm-svn: 158445
Diffstat (limited to 'llvm/lib/Target')
-rw-r--r--llvm/lib/Target/ARM/AsmParser/ARMAsmParser.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/llvm/lib/Target/ARM/AsmParser/ARMAsmParser.cpp b/llvm/lib/Target/ARM/AsmParser/ARMAsmParser.cpp
index 2fae489371d..6e0062ac44d 100644
--- a/llvm/lib/Target/ARM/AsmParser/ARMAsmParser.cpp
+++ b/llvm/lib/Target/ARM/AsmParser/ARMAsmParser.cpp
@@ -3284,7 +3284,8 @@ ARMAsmParser::OperandMatchResultTy ARMAsmParser::
parseProcIFlagsOperand(SmallVectorImpl<MCParsedAsmOperand*> &Operands) {
SMLoc S = Parser.getTok().getLoc();
const AsmToken &Tok = Parser.getTok();
- assert(Tok.is(AsmToken::Identifier) && "Token is not an Identifier");
+ if (!Tok.is(AsmToken::Identifier))
+ return MatchOperand_NoMatch;
StringRef IFlagsStr = Tok.getString();
// An iflags string of "none" is interpreted to mean that none of the AIF
OpenPOWER on IntegriCloud