Moving definition of MnemonicContainsDot field from class Instruction to class AsmPar...
authorVladimir Medic <Vladimir.Medic@imgtec.com>
Thu, 1 Aug 2013 09:25:27 +0000 (09:25 +0000)
committerVladimir Medic <Vladimir.Medic@imgtec.com>
Thu, 1 Aug 2013 09:25:27 +0000 (09:25 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@187569 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/Target/Target.td
lib/Target/Mips/Mips.td
lib/Target/Mips/MipsInstrFormats.td
utils/TableGen/AsmMatcherEmitter.cpp

index 82cd4dd91427ef653e77af5d644fab6c6d3f105e..89ca529d530d5df3317024f8c4bc7806859bdb6c 100644 (file)
@@ -444,9 +444,6 @@ class Instruction {
   /// constraint. For example, "$Rn = $Rd".
   string TwoOperandAliasConstraint = "";
 
-  /// Does the instruction mnemonic allow '.'
-  bit MnemonicContainsDot = 0;
-
   ///@}
 
   /// UseNamedOperandTable - If set, the operand indices of this instruction
@@ -821,6 +818,9 @@ class AsmParser {
   // ShouldEmitMatchRegisterName - Set to false if the target needs a hand
   // written register name matcher
   bit ShouldEmitMatchRegisterName = 1;
+
+  /// Does the instruction mnemonic allow '.'
+  bit MnemonicContainsDot = 0;
 }
 def DefaultAsmParser : AsmParser;
 
index eefb02a494ca1f06132c98fbbf671036c1f832ec..2595e41a877f16d6151f1ee7635b6c0a97b2235b 100644 (file)
@@ -101,6 +101,7 @@ def MipsAsmWriter : AsmWriter {
 
 def MipsAsmParser : AsmParser {
   let ShouldEmitMatchRegisterName = 0;
+  let MnemonicContainsDot = 1;
 }
 
 def MipsAsmParserVariant : AsmParserVariant {
index c3108aa67ee4b92c826b8cf3b02110f226b02cc2..13227848791d39129a0e6c980c5f682c5dcb94af 100644 (file)
@@ -97,7 +97,6 @@ class InstSE<dag outs, dag ins, string asmstr, list<dag> pattern,
   let Predicates = [HasStdEnc];
   string BaseOpcode = opstr;
   string Arch;
-  let MnemonicContainsDot = 1;
 }
 
 // Mips Pseudo Instructions Format
index a7ae41ef0c1100704377600f8794ad040025ca28..840c9aa34e68c286a5f11cb71a57b0d732b7e5d8 100644 (file)
@@ -837,8 +837,7 @@ void MatchableInfo::tokenizeAsmString(const AsmMatcherInfo &Info) {
     }
 
     case '.':
-      if (!(TheDef->getValue("MnemonicContainsDot")) ||
-          !(TheDef->getValueAsBit("MnemonicContainsDot"))) {
+      if (!Info.AsmParser->getValueAsBit("MnemonicContainsDot")) {
         if (InTok)
           AsmOperands.push_back(AsmOperand(String.slice(Prev, i)));
         Prev = i;