Skip to content

Commit

Permalink
[X86] Explicitly list all X86 instruction forms in switch statement s…
Browse files Browse the repository at this point in the history
…o its easier to detect when one is missing. NFC

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@279420 91177308-0d34-0410-b5e6-96231b3b80d8
  • Loading branch information
topperc committed Aug 22, 2016
1 parent f631b7a commit d30b1a1
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion utils/TableGen/X86RecognizableInstr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -841,7 +841,16 @@ void RecognizableInstr::emitDecodePath(DisassemblerTables &tables) const {
}

switch (Form) {
default:
default: llvm_unreachable("Invalid form!");
case X86Local::Pseudo: llvm_unreachable("Pseudo should not be emitted!");
case X86Local::RawFrm:
case X86Local::AddRegFrm:
case X86Local::RawFrmMemOffs:
case X86Local::RawFrmSrc:
case X86Local::RawFrmDst:
case X86Local::RawFrmDstSrc:
case X86Local::RawFrmImm8:
case X86Local::RawFrmImm16:
filter = new DumbFilter();
break;
case X86Local::MRMDestReg: case X86Local::MRMDestMem:
Expand Down

0 comments on commit d30b1a1

Please sign in to comment.