Remove modifierType/Base from X86 disassembler tables as they are no longer used...
authorCraig Topper <craig.topper@gmail.com>
Wed, 1 Jan 2014 21:52:57 +0000 (21:52 +0000)
committerCraig Topper <craig.topper@gmail.com>
Wed, 1 Jan 2014 21:52:57 +0000 (21:52 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@198284 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/X86/Disassembler/X86DisassemblerDecoderCommon.h
utils/TableGen/X86DisassemblerShared.h
utils/TableGen/X86DisassemblerTables.cpp
utils/TableGen/X86RecognizableInstr.cpp

index 8ecda65d98901ae86764325f6cd9dc14a36dc0b2..1acaef1b9472f80eb0bcd88ef510f3566b4833c7 100644 (file)
@@ -541,9 +541,6 @@ typedef enum {
  * its operands.
  */
 struct InstructionSpecifier {
-  uint8_t modifierType;
-  uint8_t modifierBase;
-
   /* The macro below must be defined wherever this file is included. */
   INSTRUCTION_SPECIFIER_FIELDS
 };
index 3ff922b8225c91caac7096a50941b054afa8d229..6bcb78307a2cee2ee73dd81d826890fc4d250a57 100644 (file)
@@ -23,8 +23,6 @@
     filtered = false;                      \
     insnContext = IC;                      \
     name = "";                             \
-    modifierType = MODIFIER_NONE;          \
-    modifierBase = 0;                      \
     memset(operands, 0, sizeof(operands)); \
   }
 
index 02f78f13a9fe78311ed582ae7af0f7a6dbbf5a08..6ef924a882f82bc00b165c4f27ac1269416798b0 100644 (file)
@@ -362,22 +362,6 @@ static const char* stringForDecisionType(ModRMDecisionType dt) {
 #undef ENUM_ENTRY
 }
 
-/// stringForModifierType - Returns a statically-allocated string corresponding
-///   to an opcode modifier type.
-///
-/// @param mt - The modifier type.
-/// @return   - A pointer to the statically-allocated string (e.g.,
-///             "MODIFIER_NONE" for MODIFIER_NONE).
-static const char* stringForModifierType(ModifierType mt) {
-#define ENUM_ENTRY(n) case n: return #n;
-  switch(mt) {
-    default:
-      llvm_unreachable("Unknown modifier type");
-    MODIFIER_TYPES
-  };
-#undef ENUM_ENTRY
-}
-
 DisassemblerTables::DisassemblerTables() {
   unsigned i;
 
@@ -603,14 +587,6 @@ void DisassemblerTables::emitInstructionInfo(raw_ostream &o,
     o.indent(i * 2) << "{ /* " << index << " */" << "\n";
     i++;
 
-    o.indent(i * 2) << stringForModifierType(
-                       (ModifierType)InstructionSpecifiers[index].modifierType);
-    o << ",\n";
-
-    o.indent(i * 2) << "0x";
-    o << format("%02hhx", (uint16_t)InstructionSpecifiers[index].modifierBase);
-    o << ",\n";
-
     OperandListTy OperandList;
     for (unsigned OperandIndex = 0; OperandIndex < X86_MAX_OPERANDS;
          ++OperandIndex) {
index 4016116de1312cba4080962add1e580c8ca66e9d..15212d3f250b6ece84ea2498a2780ecd6570c675 100644 (file)
@@ -1182,8 +1182,6 @@ void RecognizableInstr::emitDecodePath(DisassemblerTables &tables) const {
                           *filter,
                           UID, Is32Bit, IgnoresVEX_L);
   }
-  Spec->modifierType = MODIFIER_NONE;
-  Spec->modifierBase = opcodeToSet;
 
   delete filter;