diff options
author | Tim Northover <tnorthover@apple.com> | 2014-04-30 16:13:20 +0000 |
---|---|---|
committer | Tim Northover <tnorthover@apple.com> | 2014-04-30 16:13:20 +0000 |
commit | b8fb7f41938a4c5635eba25762d1dd216986003b (patch) | |
tree | 582d2bd2620df3a9da73d497187bd0342f31cd40 /llvm/lib/Target/ARM64/AsmParser/ARM64AsmParser.cpp | |
parent | 3c9a9401d5316c49ca62ef55faa634175c56fe21 (diff) | |
download | bcm5719-llvm-b8fb7f41938a4c5635eba25762d1dd216986003b.tar.gz bcm5719-llvm-b8fb7f41938a4c5635eba25762d1dd216986003b.zip |
AArch64/ARM64: add specific diagnostic for MRS/MSR and enable tests.
llvm-svn: 207667
Diffstat (limited to 'llvm/lib/Target/ARM64/AsmParser/ARM64AsmParser.cpp')
-rw-r--r-- | llvm/lib/Target/ARM64/AsmParser/ARM64AsmParser.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/llvm/lib/Target/ARM64/AsmParser/ARM64AsmParser.cpp b/llvm/lib/Target/ARM64/AsmParser/ARM64AsmParser.cpp index 530bab80b66..7572691fcf7 100644 --- a/llvm/lib/Target/ARM64/AsmParser/ARM64AsmParser.cpp +++ b/llvm/lib/Target/ARM64/AsmParser/ARM64AsmParser.cpp @@ -3857,6 +3857,10 @@ bool ARM64AsmParser::showMatchError(SMLoc Loc, unsigned ErrCode) { return Error(Loc, "immediate must be an integer in range [1,64]."); case Match_InvalidLabel: return Error(Loc, "expected label or encodable integer pc offset"); + case Match_MRS: + return Error(Loc, "expected readable system register"); + case Match_MSR: + return Error(Loc, "expected writable system register or pstate"); case Match_MnemonicFail: return Error(Loc, "unrecognized instruction mnemonic"); default: @@ -4394,7 +4398,9 @@ bool ARM64AsmParser::MatchAndEmitInstruction(SMLoc IDLoc, unsigned &Opcode, case Match_InvalidImm1_16: case Match_InvalidImm1_32: case Match_InvalidImm1_64: - case Match_InvalidLabel: { + case Match_InvalidLabel: + case Match_MSR: + case Match_MRS: { // Any time we get here, there's nothing fancy to do. Just get the // operand SMLoc and display the diagnostic. SMLoc ErrorLoc = ((ARM64Operand *)Operands[ErrorInfo])->getStartLoc(); |