summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/Sparc
diff options
context:
space:
mode:
authorCraig Topper <craig.topper@gmail.com>2015-01-03 08:16:34 +0000
committerCraig Topper <craig.topper@gmail.com>2015-01-03 08:16:34 +0000
commit589ceee7f449db13c61995625be7bd2374d23595 (patch)
tree62bc8a3f454dd729ba593958353b8025996d545d /llvm/lib/Target/Sparc
parenta5754e6e82ae241b2c0ca3263a0d1ccca6ae1099 (diff)
downloadbcm5719-llvm-589ceee7f449db13c61995625be7bd2374d23595.tar.gz
bcm5719-llvm-589ceee7f449db13c61995625be7bd2374d23595.zip
Minor cleanup to all the switches after MatchInstructionImpl in all the AsmParsers.
Make sure they all have llvm_unreachable on the default path out of the switch. Remove unnecessary "default: break". Remove a 'return' after unreachable. Fix some indentation. llvm-svn: 225114
Diffstat (limited to 'llvm/lib/Target/Sparc')
-rw-r--r--llvm/lib/Target/Sparc/AsmParser/SparcAsmParser.cpp5
1 files changed, 1 insertions, 4 deletions
diff --git a/llvm/lib/Target/Sparc/AsmParser/SparcAsmParser.cpp b/llvm/lib/Target/Sparc/AsmParser/SparcAsmParser.cpp
index d0b362c92a8..551189c13c7 100644
--- a/llvm/lib/Target/Sparc/AsmParser/SparcAsmParser.cpp
+++ b/llvm/lib/Target/Sparc/AsmParser/SparcAsmParser.cpp
@@ -393,9 +393,6 @@ bool SparcAsmParser::MatchAndEmitInstruction(SMLoc IDLoc, unsigned &Opcode,
unsigned MatchResult = MatchInstructionImpl(Operands, Inst, ErrorInfo,
MatchingInlineAsm);
switch (MatchResult) {
- default:
- break;
-
case Match_Success: {
Inst.setLoc(IDLoc);
Out.EmitInstruction(Inst, STI);
@@ -422,7 +419,7 @@ bool SparcAsmParser::MatchAndEmitInstruction(SMLoc IDLoc, unsigned &Opcode,
case Match_MnemonicFail:
return Error(IDLoc, "invalid instruction mnemonic");
}
- return true;
+ llvm_unreachable("Implement any new match types added!");
}
bool SparcAsmParser::
OpenPOWER on IntegriCloud