LCOV - code coverage report
Current view: top level - build-llvm/lib/Target/WebAssembly - WebAssemblyGenAsmMatcher.inc (source / functions) Hit Total Coverage
Test: llvm-toolchain.info Lines: 46 137 33.6 %
Date: 2018-10-20 13:21:21 Functions: 2 10 20.0 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : /*===- TableGen'erated file -------------------------------------*- C++ -*-===*\
       2             : |*                                                                            *|
       3             : |* Assembly Matcher Source Fragment                                           *|
       4             : |*                                                                            *|
       5             : |* Automatically generated file, do not edit!                                 *|
       6             : |*                                                                            *|
       7             : \*===----------------------------------------------------------------------===*/
       8             : 
       9             : 
      10             : #ifdef GET_ASSEMBLER_HEADER
      11             : #undef GET_ASSEMBLER_HEADER
      12             :   // This should be included into the middle of the declaration of
      13             :   // your subclasses implementation of MCTargetAsmParser.
      14             :   uint64_t ComputeAvailableFeatures(const FeatureBitset& FB) const;
      15             :   void convertToMCInst(unsigned Kind, MCInst &Inst, unsigned Opcode,
      16             :                        const OperandVector &Operands);
      17             :   void convertToMapAndConstraints(unsigned Kind,
      18             :                            const OperandVector &Operands) override;
      19             :   unsigned MatchInstructionImpl(const OperandVector &Operands,
      20             :                                 MCInst &Inst,
      21             :                                 uint64_t &ErrorInfo,
      22             :                                 bool matchingInlineAsm,
      23             :                                 unsigned VariantID = 0);
      24             : #endif // GET_ASSEMBLER_HEADER_INFO
      25             : 
      26             : 
      27             : #ifdef GET_OPERAND_DIAGNOSTIC_TYPES
      28             : #undef GET_OPERAND_DIAGNOSTIC_TYPES
      29             : 
      30             : #endif // GET_OPERAND_DIAGNOSTIC_TYPES
      31             : 
      32             : 
      33             : #ifdef GET_REGISTER_MATCHER
      34             : #undef GET_REGISTER_MATCHER
      35             : 
      36             : // Flags for subtarget features that participate in instruction matching.
      37             : enum SubtargetFeatureFlag : uint8_t {
      38             :   Feature_HasSIMD128 = (1ULL << 3),
      39             :   Feature_HasAtomics = (1ULL << 0),
      40             :   Feature_HasNontrappingFPToInt = (1ULL << 2),
      41             :   Feature_NotHasNontrappingFPToInt = (1ULL << 6),
      42             :   Feature_HasSignExt = (1ULL << 4),
      43             :   Feature_NotHasSignExt = (1ULL << 7),
      44             :   Feature_HasExceptionHandling = (1ULL << 1),
      45             :   Feature_NotHasExceptionHandling = (1ULL << 5),
      46             :   Feature_None = 0
      47             : };
      48             : 
      49             : #endif // GET_REGISTER_MATCHER
      50             : 
      51             : 
      52             : #ifdef GET_SUBTARGET_FEATURE_NAME
      53             : #undef GET_SUBTARGET_FEATURE_NAME
      54             : 
      55             : // User-level names for subtarget features that participate in
      56             : // instruction matching.
      57             : static const char *getSubtargetFeatureName(uint64_t Val) {
      58             :   switch(Val) {
      59             :   case Feature_HasSIMD128: return "simd128";
      60             :   case Feature_HasAtomics: return "atomics";
      61             :   case Feature_HasNontrappingFPToInt: return "nontrapping-fptoint";
      62             :   case Feature_NotHasNontrappingFPToInt: return "nontrapping-fptoint";
      63             :   case Feature_HasSignExt: return "sign-ext";
      64             :   case Feature_NotHasSignExt: return "sign-ext";
      65             :   case Feature_HasExceptionHandling: return "exception-handling";
      66             :   case Feature_NotHasExceptionHandling: return "exception-handling";
      67             :   default: return "(unknown)";
      68             :   }
      69             : }
      70             : 
      71             : #endif // GET_SUBTARGET_FEATURE_NAME
      72             : 
      73             : 
      74             : #ifdef GET_MATCHER_IMPLEMENTATION
      75             : #undef GET_MATCHER_IMPLEMENTATION
      76             : 
      77             : static const uint8_t TiedAsmOperandTable[][3] = { /* empty  */ {0, 0, 0} };
      78             : 
      79             : namespace {
      80             : enum OperatorConversionKind {
      81             :   CVT_Done,
      82             :   CVT_Reg,
      83             :   CVT_Tied,
      84             :   CVT_95_addImmOperands,
      85             :   CVT_imm_95_0,
      86             :   CVT_NUM_CONVERTERS
      87             : };
      88             : 
      89             : enum InstructionConversionKind {
      90             :   Convert__Imm1_1__Imm1_0,
      91             :   Convert__Imm1_0,
      92             :   Convert_NoOperands,
      93             :   Convert__Imm1_0__imm_95_0,
      94             :   Convert__Imm1_0__Imm1_1,
      95             :   Convert__Imm1_0__Imm1_1__Imm1_2__Imm1_3,
      96             :   Convert__Imm1_0__Imm1_1__Imm1_2__Imm1_3__Imm1_4__Imm1_5__Imm1_6__Imm1_7,
      97             :   Convert__Imm1_0__Imm1_1__Imm1_2__Imm1_3__Imm1_4__Imm1_5__Imm1_6__Imm1_7__Imm1_8__Imm1_9__Imm1_10__Imm1_11__Imm1_12__Imm1_13__Imm1_14__Imm1_15,
      98             :   CVT_NUM_SIGNATURES
      99             : };
     100             : 
     101             : } // end anonymous namespace
     102             : 
     103             : static const uint8_t ConversionTable[CVT_NUM_SIGNATURES][33] = {
     104             :   // Convert__Imm1_1__Imm1_0
     105             :   { CVT_95_addImmOperands, 2, CVT_95_addImmOperands, 1, CVT_Done },
     106             :   // Convert__Imm1_0
     107             :   { CVT_95_addImmOperands, 1, CVT_Done },
     108             :   // Convert_NoOperands
     109             :   { CVT_Done },
     110             :   // Convert__Imm1_0__imm_95_0
     111             :   { CVT_95_addImmOperands, 1, CVT_imm_95_0, 0, CVT_Done },
     112             :   // Convert__Imm1_0__Imm1_1
     113             :   { CVT_95_addImmOperands, 1, CVT_95_addImmOperands, 2, CVT_Done },
     114             :   // Convert__Imm1_0__Imm1_1__Imm1_2__Imm1_3
     115             :   { CVT_95_addImmOperands, 1, CVT_95_addImmOperands, 2, CVT_95_addImmOperands, 3, CVT_95_addImmOperands, 4, CVT_Done },
     116             :   // Convert__Imm1_0__Imm1_1__Imm1_2__Imm1_3__Imm1_4__Imm1_5__Imm1_6__Imm1_7
     117             :   { CVT_95_addImmOperands, 1, CVT_95_addImmOperands, 2, CVT_95_addImmOperands, 3, CVT_95_addImmOperands, 4, CVT_95_addImmOperands, 5, CVT_95_addImmOperands, 6, CVT_95_addImmOperands, 7, CVT_95_addImmOperands, 8, CVT_Done },
     118             :   // Convert__Imm1_0__Imm1_1__Imm1_2__Imm1_3__Imm1_4__Imm1_5__Imm1_6__Imm1_7__Imm1_8__Imm1_9__Imm1_10__Imm1_11__Imm1_12__Imm1_13__Imm1_14__Imm1_15
     119             :   { CVT_95_addImmOperands, 1, CVT_95_addImmOperands, 2, CVT_95_addImmOperands, 3, CVT_95_addImmOperands, 4, CVT_95_addImmOperands, 5, CVT_95_addImmOperands, 6, CVT_95_addImmOperands, 7, CVT_95_addImmOperands, 8, CVT_95_addImmOperands, 9, CVT_95_addImmOperands, 10, CVT_95_addImmOperands, 11, CVT_95_addImmOperands, 12, CVT_95_addImmOperands, 13, CVT_95_addImmOperands, 14, CVT_95_addImmOperands, 15, CVT_95_addImmOperands, 16, CVT_Done },
     120             : };
     121             : 
     122           0 : void WebAssemblyAsmParser::
     123             : convertToMCInst(unsigned Kind, MCInst &Inst, unsigned Opcode,
     124             :                 const OperandVector &Operands) {
     125             :   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
     126           0 :   const uint8_t *Converter = ConversionTable[Kind];
     127             :   unsigned OpIdx;
     128             :   Inst.setOpcode(Opcode);
     129           0 :   for (const uint8_t *p = Converter; *p; p+= 2) {
     130           0 :     OpIdx = *(p + 1);
     131           0 :     switch (*p) {
     132           0 :     default: llvm_unreachable("invalid conversion entry!");
     133           0 :     case CVT_Reg:
     134             :       static_cast<WebAssemblyOperand&>(*Operands[OpIdx]).addRegOperands(Inst, 1);
     135             :       break;
     136           0 :     case CVT_Tied: {
     137             :       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
     138             :                           std::begin(TiedAsmOperandTable)) &&
     139             :              "Tied operand not found");
     140           0 :       unsigned TiedResOpnd = TiedAsmOperandTable[OpIdx][0];
     141           0 :       if (TiedResOpnd != (uint8_t) -1)
     142             :         Inst.addOperand(Inst.getOperand(TiedResOpnd));
     143             :       break;
     144             :     }
     145           0 :     case CVT_95_addImmOperands:
     146           0 :       static_cast<WebAssemblyOperand&>(*Operands[OpIdx]).addImmOperands(Inst, 1);
     147           0 :       break;
     148             :     case CVT_imm_95_0:
     149           0 :       Inst.addOperand(MCOperand::createImm(0));
     150           0 :       break;
     151             :     }
     152             :   }
     153           0 : }
     154             : 
     155           0 : void WebAssemblyAsmParser::
     156             : convertToMapAndConstraints(unsigned Kind,
     157             :                            const OperandVector &Operands) {
     158             :   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
     159             :   unsigned NumMCOperands = 0;
     160           0 :   const uint8_t *Converter = ConversionTable[Kind];
     161           0 :   for (const uint8_t *p = Converter; *p; p+= 2) {
     162           0 :     switch (*p) {
     163           0 :     default: llvm_unreachable("invalid conversion entry!");
     164           0 :     case CVT_Reg:
     165           0 :       Operands[*(p + 1)]->setMCOperandNum(NumMCOperands);
     166           0 :       Operands[*(p + 1)]->setConstraint("r");
     167           0 :       ++NumMCOperands;
     168           0 :       break;
     169           0 :     case CVT_Tied:
     170           0 :       ++NumMCOperands;
     171           0 :       break;
     172           0 :     case CVT_95_addImmOperands:
     173           0 :       Operands[*(p + 1)]->setMCOperandNum(NumMCOperands);
     174           0 :       Operands[*(p + 1)]->setConstraint("m");
     175           0 :       NumMCOperands += 1;
     176           0 :       break;
     177           0 :     case CVT_imm_95_0:
     178           0 :       Operands[*(p + 1)]->setMCOperandNum(NumMCOperands);
     179           0 :       Operands[*(p + 1)]->setConstraint("");
     180           0 :       ++NumMCOperands;
     181           0 :       break;
     182             :     }
     183             :   }
     184           0 : }
     185             : 
     186             : namespace {
     187             : 
     188             : /// MatchClassKind - The kinds of classes which participate in
     189             : /// instruction matching.
     190             : enum MatchClassKind {
     191             :   InvalidMatchClass = 0,
     192             :   OptionalMatchClass = 1,
     193             :   MCK_LAST_TOKEN = OptionalMatchClass,
     194             :   MCK_EXCEPT_REF, // register class 'EXCEPT_REF'
     195             :   MCK_F32, // register class 'F32'
     196             :   MCK_F64, // register class 'F64'
     197             :   MCK_V128, // register class 'V128'
     198             :   MCK_I32, // register class 'I32'
     199             :   MCK_I64, // register class 'I64'
     200             :   MCK_LAST_REGISTER = MCK_I64,
     201             :   MCK_Imm, // user defined class 'ImmAsmOperand'
     202             :   NumMatchClassKinds
     203             : };
     204             : 
     205             : }
     206             : 
     207           0 : static unsigned getDiagKindFromRegisterClass(MatchClassKind RegisterClass) {
     208           0 :   return MCTargetAsmParser::Match_InvalidOperand;
     209             : }
     210             : 
     211           0 : static MatchClassKind matchTokenString(StringRef Name) {
     212           0 :   return InvalidMatchClass;
     213             : }
     214             : 
     215             : /// isSubclass - Compute whether \p A is a subclass of \p B.
     216             : static bool isSubclass(MatchClassKind A, MatchClassKind B) {
     217          20 :   if (A == B)
     218             :     return true;
     219             : 
     220             :   return false;
     221             : }
     222             : 
     223             : static unsigned validateOperandClass(MCParsedAsmOperand &GOp, MatchClassKind Kind) {
     224             :   WebAssemblyOperand &Operand = (WebAssemblyOperand&)GOp;
     225         209 :   if (Kind == InvalidMatchClass)
     226             :     return MCTargetAsmParser::Match_InvalidOperand;
     227             : 
     228         189 :   if (Operand.isToken() && Kind <= MCK_LAST_TOKEN)
     229             :     return isSubclass(matchTokenString(Operand.getToken()), Kind) ?
     230             :              MCTargetAsmParser::Match_Success :
     231             :              MCTargetAsmParser::Match_InvalidOperand;
     232             : 
     233         189 :   switch (Kind) {
     234             :   default: break;
     235             :   // 'Imm' class
     236         189 :   case MCK_Imm: {
     237             :     DiagnosticPredicate DP(Operand.isImm());
     238             :     if (DP.isMatch())
     239             :       return MCTargetAsmParser::Match_Success;
     240             :     break;
     241             :     }
     242             :   } // end switch (Kind)
     243             : 
     244             :   if (Operand.isReg()) {
     245             :     MatchClassKind OpKind;
     246             :     switch (Operand.getReg()) {
     247             :     default: OpKind = InvalidMatchClass; break;
     248             :     case WebAssembly::FP32: OpKind = MCK_I32; break;
     249             :     case WebAssembly::FP64: OpKind = MCK_I64; break;
     250             :     case WebAssembly::SP32: OpKind = MCK_I32; break;
     251             :     case WebAssembly::SP64: OpKind = MCK_I64; break;
     252             :     case WebAssembly::I32_0: OpKind = MCK_I32; break;
     253             :     case WebAssembly::I64_0: OpKind = MCK_I64; break;
     254             :     case WebAssembly::F32_0: OpKind = MCK_F32; break;
     255             :     case WebAssembly::F64_0: OpKind = MCK_F64; break;
     256             :     case WebAssembly::V128_0: OpKind = MCK_V128; break;
     257             :     case WebAssembly::EXCEPT_REF_0: OpKind = MCK_EXCEPT_REF; break;
     258             :     }
     259             :     return isSubclass(OpKind, Kind) ? (unsigned)MCTargetAsmParser::Match_Success :
     260             :                                       getDiagKindFromRegisterClass(Kind);
     261             :   }
     262             : 
     263             :   if (Kind > MCK_LAST_TOKEN && Kind <= MCK_LAST_REGISTER)
     264             :     return getDiagKindFromRegisterClass(Kind);
     265             : 
     266             :   return MCTargetAsmParser::Match_InvalidOperand;
     267             : }
     268             : 
     269             : #ifndef NDEBUG
     270             : const char *getMatchClassName(MatchClassKind Kind) {
     271             :   switch (Kind) {
     272             :   case InvalidMatchClass: return "InvalidMatchClass";
     273             :   case OptionalMatchClass: return "OptionalMatchClass";
     274             :   case MCK_EXCEPT_REF: return "MCK_EXCEPT_REF";
     275             :   case MCK_F32: return "MCK_F32";
     276             :   case MCK_F64: return "MCK_F64";
     277             :   case MCK_V128: return "MCK_V128";
     278             :   case MCK_I32: return "MCK_I32";
     279             :   case MCK_I64: return "MCK_I64";
     280             :   case MCK_Imm: return "MCK_Imm";
     281             :   case NumMatchClassKinds: return "NumMatchClassKinds";
     282             :   }
     283             :   llvm_unreachable("unhandled MatchClassKind!");
     284             : }
     285             : 
     286             : #endif // NDEBUG
     287           0 : uint64_t WebAssemblyAsmParser::
     288             : ComputeAvailableFeatures(const FeatureBitset& FB) const {
     289             :   uint64_t Features = 0;
     290           0 :   if ((FB[WebAssembly::FeatureSIMD128]))
     291             :     Features |= Feature_HasSIMD128;
     292           0 :   if ((FB[WebAssembly::FeatureAtomics]))
     293           0 :     Features |= Feature_HasAtomics;
     294           0 :   if ((FB[WebAssembly::FeatureNontrappingFPToInt]))
     295           0 :     Features |= Feature_HasNontrappingFPToInt;
     296           0 :   if ((!FB[WebAssembly::FeatureNontrappingFPToInt]))
     297           0 :     Features |= Feature_NotHasNontrappingFPToInt;
     298           0 :   if ((FB[WebAssembly::FeatureSignExt]))
     299           0 :     Features |= Feature_HasSignExt;
     300           0 :   if ((!FB[WebAssembly::FeatureSignExt]))
     301           0 :     Features |= Feature_NotHasSignExt;
     302           0 :   if ((FB[WebAssembly::FeatureExceptionHandling]))
     303           0 :     Features |= Feature_HasExceptionHandling;
     304           0 :   if ((!FB[WebAssembly::FeatureExceptionHandling]))
     305           0 :     Features |= Feature_NotHasExceptionHandling;
     306           0 :   return Features;
     307             : }
     308             : 
     309         177 : static bool checkAsmTiedOperandConstraints(const WebAssemblyAsmParser&AsmParser,
     310             :                                unsigned Kind,
     311             :                                const OperandVector &Operands,
     312             :                                uint64_t &ErrorInfo) {
     313             :   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
     314         177 :   const uint8_t *Converter = ConversionTable[Kind];
     315         290 :   for (const uint8_t *p = Converter; *p; p+= 2) {
     316         113 :     switch (*p) {
     317           0 :     case CVT_Tied: {
     318           0 :       unsigned OpIdx = *(p+1);
     319             :       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
     320             :                               std::begin(TiedAsmOperandTable)) &&
     321             :              "Tied operand not found");
     322           0 :       unsigned OpndNum1 = TiedAsmOperandTable[OpIdx][1];
     323             :       unsigned OpndNum2 = TiedAsmOperandTable[OpIdx][2];
     324           0 :       if (OpndNum1 != OpndNum2) {
     325           0 :         auto &SrcOp1 = Operands[OpndNum1];
     326             :         auto &SrcOp2 = Operands[OpndNum2];
     327           0 :         if (SrcOp1->isReg() && SrcOp2->isReg()) {
     328           0 :           if (!AsmParser.regsEqual(*SrcOp1, *SrcOp2)) {
     329           0 :             ErrorInfo = OpndNum2;
     330           0 :             return false;
     331             :           }
     332             :         }
     333             :       }
     334             :       break;
     335             :     }
     336             :     default:
     337             :       break;
     338             :     }
     339             :   }
     340             :   return true;
     341             : }
     342             : 
     343             : static const char *const MnemonicTable =
     344             :     "\015atomic.notify\005block\002br\005br_if\010br_table\004call\015call_i"
     345             :     "ndirect\tcatch_all\016current_memory\004drop\tend_block\014end_function"
     346             :     "\010end_loop\007end_try\017except_ref.call\030except_ref.call_indirect\021"
     347             :     "except_ref.select\007f32.abs\007f32.add\010f32.call\021f32.call_indirec"
     348             :     "t\010f32.ceil\tf32.const\021f32.convert_s/i32\021f32.convert_s/i64\021f"
     349             :     "32.convert_u/i32\021f32.convert_u/i64\014f32.copysign\016f32.demote/f64"
     350             :     "\007f32.div\006f32.eq\tf32.floor\006f32.ge\006f32.gt\006f32.le\010f32.l"
     351             :     "oad\006f32.lt\007f32.max\007f32.min\007f32.mul\006f32.ne\013f32.nearest"
     352             :     "\007f32.neg\023f32.reinterpret/i32\nf32.select\010f32.sqrt\tf32.store\007"
     353             :     "f32.sub\tf32.trunc\tf32x4.abs\tf32x4.add\025f32x4.convert_s/i32x4\025f3"
     354             :     "2x4.convert_u/i32x4\tf32x4.div\010f32x4.eq\022f32x4.extract_lane\010f32"
     355             :     "x4.ge\010f32x4.gt\010f32x4.le\010f32x4.lt\tf32x4.max\tf32x4.min\tf32x4."
     356             :     "mul\010f32x4.ne\tf32x4.neg\022f32x4.replace_lane\013f32x4.splat\nf32x4."
     357             :     "sqrt\tf32x4.sub\007f64.abs\007f64.add\010f64.call\021f64.call_indirect\010"
     358             :     "f64.ceil\tf64.const\021f64.convert_s/i32\021f64.convert_s/i64\021f64.co"
     359             :     "nvert_u/i32\021f64.convert_u/i64\014f64.copysign\007f64.div\006f64.eq\t"
     360             :     "f64.floor\006f64.ge\006f64.gt\006f64.le\010f64.load\006f64.lt\007f64.ma"
     361             :     "x\007f64.min\007f64.mul\006f64.ne\013f64.nearest\007f64.neg\017f64.prom"
     362             :     "ote/f32\023f64.reinterpret/i64\nf64.select\010f64.sqrt\tf64.store\007f6"
     363             :     "4.sub\tf64.trunc\tf64x2.abs\tf64x2.add\025f64x2.convert_s/i64x2\025f64x"
     364             :     "2.convert_u/i64x2\tf64x2.div\010f64x2.eq\022f64x2.extract_lane\010f64x2"
     365             :     ".ge\010f64x2.gt\010f64x2.le\010f64x2.lt\tf64x2.max\tf64x2.min\tf64x2.mu"
     366             :     "l\010f64x2.ne\tf64x2.neg\022f64x2.replace_lane\013f64x2.splat\nf64x2.sq"
     367             :     "rt\tf64x2.sub\nget_global\tget_local\013grow_memory\ti16x8.add\024i16x8"
     368             :     ".add_saturate_s\024i16x8.add_saturate_u\016i16x8.all_true\016i16x8.any_"
     369             :     "true\010i16x8.eq\024i16x8.extract_lane_s\024i16x8.extract_lane_u\ni16x8"
     370             :     ".ge_s\ni16x8.ge_u\ni16x8.gt_s\ni16x8.gt_u\ni16x8.le_s\ni16x8.le_u\ni16x"
     371             :     "8.lt_s\ni16x8.lt_u\ti16x8.mul\010i16x8.ne\ti16x8.neg\022i16x8.replace_l"
     372             :     "ane\ti16x8.shl\013i16x8.shr_s\013i16x8.shr_u\013i16x8.splat\ti16x8.sub\024"
     373             :     "i16x8.sub_saturate_s\024i16x8.sub_saturate_u\007i32.add\007i32.and\017i"
     374             :     "32.atomic.load\023i32.atomic.load16_u\022i32.atomic.load8_u\022i32.atom"
     375             :     "ic.rmw.add\022i32.atomic.rmw.and\026i32.atomic.rmw.cmpxchg\021i32.atomi"
     376             :     "c.rmw.or\022i32.atomic.rmw.sub\023i32.atomic.rmw.xchg\022i32.atomic.rmw"
     377             :     ".xor\026i32.atomic.rmw16_u.add\026i32.atomic.rmw16_u.and\032i32.atomic."
     378             :     "rmw16_u.cmpxchg\025i32.atomic.rmw16_u.or\026i32.atomic.rmw16_u.sub\027i"
     379             :     "32.atomic.rmw16_u.xchg\026i32.atomic.rmw16_u.xor\025i32.atomic.rmw8_u.a"
     380             :     "dd\025i32.atomic.rmw8_u.and\031i32.atomic.rmw8_u.cmpxchg\024i32.atomic."
     381             :     "rmw8_u.or\025i32.atomic.rmw8_u.sub\026i32.atomic.rmw8_u.xchg\025i32.ato"
     382             :     "mic.rmw8_u.xor\020i32.atomic.store\022i32.atomic.store16\021i32.atomic."
     383             :     "store8\017i32.atomic.wait\010i32.call\021i32.call_indirect\ti32.catch\007"
     384             :     "i32.clz\ti32.const\007i32.ctz\ti32.div_s\ti32.div_u\006i32.eq\007i32.eq"
     385             :     "z\016i32.extend16_s\015i32.extend8_s\010i32.ge_s\010i32.ge_u\010i32.gt_"
     386             :     "s\010i32.gt_u\010i32.le_s\010i32.le_u\010i32.load\014i32.load16_s\014i3"
     387             :     "2.load16_u\013i32.load8_s\013i32.load8_u\010i32.lt_s\010i32.lt_u\007i32"
     388             :     ".mul\006i32.ne\006i32.or\ni32.popcnt\023i32.reinterpret/f32\ti32.rem_s\t"
     389             :     "i32.rem_u\010i32.rotl\010i32.rotr\ni32.select\007i32.shl\ti32.shr_s\ti3"
     390             :     "2.shr_u\ti32.store\013i32.store16\ni32.store8\007i32.sub\017i32.trunc_s"
     391             :     "/f32\017i32.trunc_s/f64\023i32.trunc_s:sat/f32\023i32.trunc_s:sat/f64\017"
     392             :     "i32.trunc_u/f32\017i32.trunc_u/f64\023i32.trunc_u:sat/f32\023i32.trunc_"
     393             :     "u:sat/f64\014i32.wrap/i64\007i32.xor\ti32x4.add\016i32x4.all_true\016i3"
     394             :     "2x4.any_true\010i32x4.eq\022i32x4.extract_lane\ni32x4.ge_s\ni32x4.ge_u\n"
     395             :     "i32x4.gt_s\ni32x4.gt_u\ni32x4.le_s\ni32x4.le_u\ni32x4.lt_s\ni32x4.lt_u\t"
     396             :     "i32x4.mul\010i32x4.ne\ti32x4.neg\022i32x4.replace_lane\ti32x4.shl\013i3"
     397             :     "2x4.shr_s\013i32x4.shr_u\013i32x4.splat\ti32x4.sub\027i32x4.trunc_sat_s"
     398             :     "/f32x4\027i32x4.trunc_sat_u/f32x4\007i64.add\007i64.and\017i64.atomic.l"
     399             :     "oad\023i64.atomic.load16_u\023i64.atomic.load32_u\022i64.atomic.load8_u"
     400             :     "\022i64.atomic.rmw.add\022i64.atomic.rmw.and\026i64.atomic.rmw.cmpxchg\021"
     401             :     "i64.atomic.rmw.or\022i64.atomic.rmw.sub\023i64.atomic.rmw.xchg\022i64.a"
     402             :     "tomic.rmw.xor\026i64.atomic.rmw16_u.add\026i64.atomic.rmw16_u.and\032i6"
     403             :     "4.atomic.rmw16_u.cmpxchg\025i64.atomic.rmw16_u.or\026i64.atomic.rmw16_u"
     404             :     ".sub\027i64.atomic.rmw16_u.xchg\026i64.atomic.rmw16_u.xor\026i64.atomic"
     405             :     ".rmw32_u.add\026i64.atomic.rmw32_u.and\032i64.atomic.rmw32_u.cmpxchg\025"
     406             :     "i64.atomic.rmw32_u.or\026i64.atomic.rmw32_u.sub\027i64.atomic.rmw32_u.x"
     407             :     "chg\026i64.atomic.rmw32_u.xor\025i64.atomic.rmw8_u.add\025i64.atomic.rm"
     408             :     "w8_u.and\031i64.atomic.rmw8_u.cmpxchg\024i64.atomic.rmw8_u.or\025i64.at"
     409             :     "omic.rmw8_u.sub\026i64.atomic.rmw8_u.xchg\025i64.atomic.rmw8_u.xor\020i"
     410             :     "64.atomic.store\022i64.atomic.store16\022i64.atomic.store32\021i64.atom"
     411             :     "ic.store8\017i64.atomic.wait\010i64.call\021i64.call_indirect\ti64.catc"
     412             :     "h\007i64.clz\ti64.const\007i64.ctz\ti64.div_s\ti64.div_u\006i64.eq\007i"
     413             :     "64.eqz\016i64.extend16_s\016i64.extend32_s\015i64.extend8_s\020i64.exte"
     414             :     "nd_s/i32\020i64.extend_u/i32\010i64.ge_s\010i64.ge_u\010i64.gt_s\010i64"
     415             :     ".gt_u\010i64.le_s\010i64.le_u\010i64.load\014i64.load16_s\014i64.load16"
     416             :     "_u\014i64.load32_s\014i64.load32_u\013i64.load8_s\013i64.load8_u\010i64"
     417             :     ".lt_s\010i64.lt_u\007i64.mul\006i64.ne\006i64.or\ni64.popcnt\023i64.rei"
     418             :     "nterpret/f64\ti64.rem_s\ti64.rem_u\010i64.rotl\010i64.rotr\ni64.select\007"
     419             :     "i64.shl\ti64.shr_s\ti64.shr_u\ti64.store\013i64.store16\013i64.store32\n"
     420             :     "i64.store8\007i64.sub\017i64.trunc_s/f32\017i64.trunc_s/f64\023i64.trun"
     421             :     "c_s:sat/f32\023i64.trunc_s:sat/f64\017i64.trunc_u/f32\017i64.trunc_u/f6"
     422             :     "4\023i64.trunc_u:sat/f32\023i64.trunc_u:sat/f64\007i64.xor\ti64x2.add\016"
     423             :     "i64x2.all_true\016i64x2.any_true\022i64x2.extract_lane\ti64x2.neg\022i6"
     424             :     "4x2.replace_lane\ti64x2.shl\013i64x2.shr_s\013i64x2.shr_u\013i64x2.spla"
     425             :     "t\ti64x2.sub\027i64x2.trunc_sat_s/f64x2\027i64x2.trunc_sat_u/f64x2\ti8x"
     426             :     "16.add\024i8x16.add_saturate_s\024i8x16.add_saturate_u\016i8x16.all_tru"
     427             :     "e\016i8x16.any_true\010i8x16.eq\024i8x16.extract_lane_s\024i8x16.extrac"
     428             :     "t_lane_u\ni8x16.ge_s\ni8x16.ge_u\ni8x16.gt_s\ni8x16.gt_u\ni8x16.le_s\ni"
     429             :     "8x16.le_u\ni8x16.lt_s\ni8x16.lt_u\ti8x16.mul\010i8x16.ne\ti8x16.neg\022"
     430             :     "i8x16.replace_lane\ti8x16.shl\013i8x16.shr_s\013i8x16.shr_u\013i8x16.sp"
     431             :     "lat\ti8x16.sub\024i8x16.sub_saturate_s\024i8x16.sub_saturate_u\004loop\010"
     432             :     "mem.grow\010mem.size\013memory.grow\013memory.size\003nop\007rethrow\006"
     433             :     "return\nset_global\tset_local\ttee_local\005throw\003try\013unreachable"
     434             :     "\010v128.and\016v128.bitselect\tv128.call\022v128.call_indirect\nv128.c"
     435             :     "onst\tv128.load\010v128.not\007v128.or\nv128.store\010v128.xor\015v8x16"
     436             :     ".shuffle";
     437             : 
     438             : namespace {
     439             :   struct MatchEntry {
     440             :     uint16_t Mnemonic;
     441             :     uint16_t Opcode;
     442             :     uint16_t ConvertFn;
     443             :     uint8_t RequiredFeatures;
     444             :     uint8_t Classes[16];
     445           0 :     StringRef getMnemonic() const {
     446           0 :       return StringRef(MnemonicTable + Mnemonic + 1,
     447           0 :                        MnemonicTable[Mnemonic]);
     448             :     }
     449             :   };
     450             : 
     451             :   // Predicate for searching for an opcode.
     452             :   struct LessOpcode {
     453           0 :     bool operator()(const MatchEntry &LHS, StringRef RHS) {
     454           0 :       return LHS.getMnemonic() < RHS;
     455             :     }
     456           0 :     bool operator()(StringRef LHS, const MatchEntry &RHS) {
     457           0 :       return LHS < RHS.getMnemonic();
     458             :     }
     459             :     bool operator()(const MatchEntry &LHS, const MatchEntry &RHS) {
     460             :       return LHS.getMnemonic() < RHS.getMnemonic();
     461             :     }
     462             :   };
     463             : } // end anonymous namespace.
     464             : 
     465             : static const MatchEntry MatchTable0[] = {
     466             :   { 0 /* atomic.notify */, WebAssembly::ATOMIC_NOTIFY_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     467             :   { 14 /* block */, WebAssembly::BLOCK_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     468             :   { 20 /* br */, WebAssembly::BR_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     469             :   { 23 /* br_if */, WebAssembly::BR_IF_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     470             :   { 29 /* br_table */, WebAssembly::BR_TABLE_I32_S, Convert_NoOperands, 0, {  }, },
     471             :   { 29 /* br_table */, WebAssembly::BR_TABLE_I64_S, Convert_NoOperands, 0, {  }, },
     472             :   { 38 /* call */, WebAssembly::CALL_VOID_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     473             :   { 43 /* call_indirect */, WebAssembly::CALL_INDIRECT_VOID_S, Convert__Imm1_0__imm_95_0, 0, { MCK_Imm }, },
     474             :   { 57 /* catch_all */, WebAssembly::CATCH_ALL_S, Convert_NoOperands, Feature_HasExceptionHandling, {  }, },
     475             :   { 67 /* current_memory */, WebAssembly::CURRENT_MEMORY_I32_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     476             :   { 82 /* drop */, WebAssembly::DROP_EXCEPT_REF_S, Convert_NoOperands, Feature_HasExceptionHandling, {  }, },
     477             :   { 82 /* drop */, WebAssembly::DROP_V128_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     478             :   { 82 /* drop */, WebAssembly::DROP_F32_S, Convert_NoOperands, 0, {  }, },
     479             :   { 82 /* drop */, WebAssembly::DROP_F64_S, Convert_NoOperands, 0, {  }, },
     480             :   { 82 /* drop */, WebAssembly::DROP_I32_S, Convert_NoOperands, 0, {  }, },
     481             :   { 82 /* drop */, WebAssembly::DROP_I64_S, Convert_NoOperands, 0, {  }, },
     482             :   { 87 /* end_block */, WebAssembly::END_BLOCK_S, Convert_NoOperands, 0, {  }, },
     483             :   { 97 /* end_function */, WebAssembly::END_FUNCTION_S, Convert_NoOperands, 0, {  }, },
     484             :   { 110 /* end_loop */, WebAssembly::END_LOOP_S, Convert_NoOperands, 0, {  }, },
     485             :   { 119 /* end_try */, WebAssembly::END_TRY_S, Convert_NoOperands, Feature_HasExceptionHandling, {  }, },
     486             :   { 127 /* except_ref.call */, WebAssembly::CALL_EXCEPT_REF_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     487             :   { 143 /* except_ref.call_indirect */, WebAssembly::CALL_INDIRECT_EXCEPT_REF_S, Convert__Imm1_0__imm_95_0, 0, { MCK_Imm }, },
     488             :   { 168 /* except_ref.select */, WebAssembly::SELECT_EXCEPT_REF_S, Convert_NoOperands, 0, {  }, },
     489             :   { 186 /* f32.abs */, WebAssembly::ABS_F32_S, Convert_NoOperands, 0, {  }, },
     490             :   { 194 /* f32.add */, WebAssembly::ADD_F32_S, Convert_NoOperands, 0, {  }, },
     491             :   { 202 /* f32.call */, WebAssembly::CALL_F32_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     492             :   { 211 /* f32.call_indirect */, WebAssembly::CALL_INDIRECT_F32_S, Convert__Imm1_0__imm_95_0, 0, { MCK_Imm }, },
     493             :   { 229 /* f32.ceil */, WebAssembly::CEIL_F32_S, Convert_NoOperands, 0, {  }, },
     494             :   { 238 /* f32.const */, WebAssembly::CONST_F32_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     495             :   { 248 /* f32.convert_s/i32 */, WebAssembly::F32_CONVERT_S_I32_S, Convert_NoOperands, 0, {  }, },
     496             :   { 266 /* f32.convert_s/i64 */, WebAssembly::F32_CONVERT_S_I64_S, Convert_NoOperands, 0, {  }, },
     497             :   { 284 /* f32.convert_u/i32 */, WebAssembly::F32_CONVERT_U_I32_S, Convert_NoOperands, 0, {  }, },
     498             :   { 302 /* f32.convert_u/i64 */, WebAssembly::F32_CONVERT_U_I64_S, Convert_NoOperands, 0, {  }, },
     499             :   { 320 /* f32.copysign */, WebAssembly::COPYSIGN_F32_S, Convert_NoOperands, 0, {  }, },
     500             :   { 333 /* f32.demote/f64 */, WebAssembly::F32_DEMOTE_F64_S, Convert_NoOperands, 0, {  }, },
     501             :   { 348 /* f32.div */, WebAssembly::DIV_F32_S, Convert_NoOperands, 0, {  }, },
     502             :   { 356 /* f32.eq */, WebAssembly::EQ_F32_S, Convert_NoOperands, 0, {  }, },
     503             :   { 363 /* f32.floor */, WebAssembly::FLOOR_F32_S, Convert_NoOperands, 0, {  }, },
     504             :   { 373 /* f32.ge */, WebAssembly::GE_F32_S, Convert_NoOperands, 0, {  }, },
     505             :   { 380 /* f32.gt */, WebAssembly::GT_F32_S, Convert_NoOperands, 0, {  }, },
     506             :   { 387 /* f32.le */, WebAssembly::LE_F32_S, Convert_NoOperands, 0, {  }, },
     507             :   { 394 /* f32.load */, WebAssembly::LOAD_F32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     508             :   { 403 /* f32.lt */, WebAssembly::LT_F32_S, Convert_NoOperands, 0, {  }, },
     509             :   { 410 /* f32.max */, WebAssembly::MAX_F32_S, Convert_NoOperands, 0, {  }, },
     510             :   { 418 /* f32.min */, WebAssembly::MIN_F32_S, Convert_NoOperands, 0, {  }, },
     511             :   { 426 /* f32.mul */, WebAssembly::MUL_F32_S, Convert_NoOperands, 0, {  }, },
     512             :   { 434 /* f32.ne */, WebAssembly::NE_F32_S, Convert_NoOperands, 0, {  }, },
     513             :   { 441 /* f32.nearest */, WebAssembly::NEAREST_F32_S, Convert_NoOperands, 0, {  }, },
     514             :   { 453 /* f32.neg */, WebAssembly::NEG_F32_S, Convert_NoOperands, 0, {  }, },
     515             :   { 461 /* f32.reinterpret/i32 */, WebAssembly::F32_REINTERPRET_I32_S, Convert_NoOperands, 0, {  }, },
     516             :   { 481 /* f32.select */, WebAssembly::SELECT_F32_S, Convert_NoOperands, 0, {  }, },
     517             :   { 492 /* f32.sqrt */, WebAssembly::SQRT_F32_S, Convert_NoOperands, 0, {  }, },
     518             :   { 501 /* f32.store */, WebAssembly::STORE_F32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     519             :   { 511 /* f32.sub */, WebAssembly::SUB_F32_S, Convert_NoOperands, 0, {  }, },
     520             :   { 519 /* f32.trunc */, WebAssembly::TRUNC_F32_S, Convert_NoOperands, 0, {  }, },
     521             :   { 529 /* f32x4.abs */, WebAssembly::ABS_v4f32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     522             :   { 539 /* f32x4.add */, WebAssembly::ADD_v4f32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     523             :   { 549 /* f32x4.convert_s/i32x4 */, WebAssembly::sint_to_fp_v4f32_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     524             :   { 571 /* f32x4.convert_u/i32x4 */, WebAssembly::uint_to_fp_v4f32_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     525             :   { 593 /* f32x4.div */, WebAssembly::DIV_v4f32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     526             :   { 603 /* f32x4.eq */, WebAssembly::EQ_v4f32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     527             :   { 612 /* f32x4.extract_lane */, WebAssembly::EXTRACT_LANE_v4f32_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     528             :   { 631 /* f32x4.ge */, WebAssembly::GE_v4f32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     529             :   { 640 /* f32x4.gt */, WebAssembly::GT_v4f32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     530             :   { 649 /* f32x4.le */, WebAssembly::LE_v4f32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     531             :   { 658 /* f32x4.lt */, WebAssembly::LT_v4f32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     532             :   { 667 /* f32x4.max */, WebAssembly::MAX_v4f32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     533             :   { 677 /* f32x4.min */, WebAssembly::MIN_v4f32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     534             :   { 687 /* f32x4.mul */, WebAssembly::MUL_v4f32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     535             :   { 697 /* f32x4.ne */, WebAssembly::NE_v4f32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     536             :   { 706 /* f32x4.neg */, WebAssembly::NEG_v4f32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     537             :   { 716 /* f32x4.replace_lane */, WebAssembly::REPLACE_LANE_v4f32_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     538             :   { 735 /* f32x4.splat */, WebAssembly::SPLAT_v4f32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     539             :   { 747 /* f32x4.sqrt */, WebAssembly::SQRT_v4f32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     540             :   { 758 /* f32x4.sub */, WebAssembly::SUB_v4f32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     541             :   { 768 /* f64.abs */, WebAssembly::ABS_F64_S, Convert_NoOperands, 0, {  }, },
     542             :   { 776 /* f64.add */, WebAssembly::ADD_F64_S, Convert_NoOperands, 0, {  }, },
     543             :   { 784 /* f64.call */, WebAssembly::CALL_F64_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     544             :   { 793 /* f64.call_indirect */, WebAssembly::CALL_INDIRECT_F64_S, Convert__Imm1_0__imm_95_0, 0, { MCK_Imm }, },
     545             :   { 811 /* f64.ceil */, WebAssembly::CEIL_F64_S, Convert_NoOperands, 0, {  }, },
     546             :   { 820 /* f64.const */, WebAssembly::CONST_F64_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     547             :   { 830 /* f64.convert_s/i32 */, WebAssembly::F64_CONVERT_S_I32_S, Convert_NoOperands, 0, {  }, },
     548             :   { 848 /* f64.convert_s/i64 */, WebAssembly::F64_CONVERT_S_I64_S, Convert_NoOperands, 0, {  }, },
     549             :   { 866 /* f64.convert_u/i32 */, WebAssembly::F64_CONVERT_U_I32_S, Convert_NoOperands, 0, {  }, },
     550             :   { 884 /* f64.convert_u/i64 */, WebAssembly::F64_CONVERT_U_I64_S, Convert_NoOperands, 0, {  }, },
     551             :   { 902 /* f64.copysign */, WebAssembly::COPYSIGN_F64_S, Convert_NoOperands, 0, {  }, },
     552             :   { 915 /* f64.div */, WebAssembly::DIV_F64_S, Convert_NoOperands, 0, {  }, },
     553             :   { 923 /* f64.eq */, WebAssembly::EQ_F64_S, Convert_NoOperands, 0, {  }, },
     554             :   { 930 /* f64.floor */, WebAssembly::FLOOR_F64_S, Convert_NoOperands, 0, {  }, },
     555             :   { 940 /* f64.ge */, WebAssembly::GE_F64_S, Convert_NoOperands, 0, {  }, },
     556             :   { 947 /* f64.gt */, WebAssembly::GT_F64_S, Convert_NoOperands, 0, {  }, },
     557             :   { 954 /* f64.le */, WebAssembly::LE_F64_S, Convert_NoOperands, 0, {  }, },
     558             :   { 961 /* f64.load */, WebAssembly::LOAD_F64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     559             :   { 970 /* f64.lt */, WebAssembly::LT_F64_S, Convert_NoOperands, 0, {  }, },
     560             :   { 977 /* f64.max */, WebAssembly::MAX_F64_S, Convert_NoOperands, 0, {  }, },
     561             :   { 985 /* f64.min */, WebAssembly::MIN_F64_S, Convert_NoOperands, 0, {  }, },
     562             :   { 993 /* f64.mul */, WebAssembly::MUL_F64_S, Convert_NoOperands, 0, {  }, },
     563             :   { 1001 /* f64.ne */, WebAssembly::NE_F64_S, Convert_NoOperands, 0, {  }, },
     564             :   { 1008 /* f64.nearest */, WebAssembly::NEAREST_F64_S, Convert_NoOperands, 0, {  }, },
     565             :   { 1020 /* f64.neg */, WebAssembly::NEG_F64_S, Convert_NoOperands, 0, {  }, },
     566             :   { 1028 /* f64.promote/f32 */, WebAssembly::F64_PROMOTE_F32_S, Convert_NoOperands, 0, {  }, },
     567             :   { 1044 /* f64.reinterpret/i64 */, WebAssembly::F64_REINTERPRET_I64_S, Convert_NoOperands, 0, {  }, },
     568             :   { 1064 /* f64.select */, WebAssembly::SELECT_F64_S, Convert_NoOperands, 0, {  }, },
     569             :   { 1075 /* f64.sqrt */, WebAssembly::SQRT_F64_S, Convert_NoOperands, 0, {  }, },
     570             :   { 1084 /* f64.store */, WebAssembly::STORE_F64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     571             :   { 1094 /* f64.sub */, WebAssembly::SUB_F64_S, Convert_NoOperands, 0, {  }, },
     572             :   { 1102 /* f64.trunc */, WebAssembly::TRUNC_F64_S, Convert_NoOperands, 0, {  }, },
     573             :   { 1112 /* f64x2.abs */, WebAssembly::ABS_v2f64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     574             :   { 1122 /* f64x2.add */, WebAssembly::ADD_v2f64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     575             :   { 1132 /* f64x2.convert_s/i64x2 */, WebAssembly::sint_to_fp_v2f64_v2i64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     576             :   { 1154 /* f64x2.convert_u/i64x2 */, WebAssembly::uint_to_fp_v2f64_v2i64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     577             :   { 1176 /* f64x2.div */, WebAssembly::DIV_v2f64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     578             :   { 1186 /* f64x2.eq */, WebAssembly::EQ_v2f64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     579             :   { 1195 /* f64x2.extract_lane */, WebAssembly::EXTRACT_LANE_v2f64_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     580             :   { 1214 /* f64x2.ge */, WebAssembly::GE_v2f64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     581             :   { 1223 /* f64x2.gt */, WebAssembly::GT_v2f64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     582             :   { 1232 /* f64x2.le */, WebAssembly::LE_v2f64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     583             :   { 1241 /* f64x2.lt */, WebAssembly::LT_v2f64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     584             :   { 1250 /* f64x2.max */, WebAssembly::MAX_v2f64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     585             :   { 1260 /* f64x2.min */, WebAssembly::MIN_v2f64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     586             :   { 1270 /* f64x2.mul */, WebAssembly::MUL_v2f64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     587             :   { 1280 /* f64x2.ne */, WebAssembly::NE_v2f64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     588             :   { 1289 /* f64x2.neg */, WebAssembly::NEG_v2f64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     589             :   { 1299 /* f64x2.replace_lane */, WebAssembly::REPLACE_LANE_v2f64_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     590             :   { 1318 /* f64x2.splat */, WebAssembly::SPLAT_v2f64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     591             :   { 1330 /* f64x2.sqrt */, WebAssembly::SQRT_v2f64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     592             :   { 1341 /* f64x2.sub */, WebAssembly::SUB_v2f64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     593             :   { 1351 /* get_global */, WebAssembly::GET_GLOBAL_EXCEPT_REF_S, Convert__Imm1_0, Feature_HasExceptionHandling, { MCK_Imm }, },
     594             :   { 1351 /* get_global */, WebAssembly::GET_GLOBAL_V128_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     595             :   { 1351 /* get_global */, WebAssembly::GET_GLOBAL_F32_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     596             :   { 1351 /* get_global */, WebAssembly::GET_GLOBAL_F64_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     597             :   { 1351 /* get_global */, WebAssembly::GET_GLOBAL_I32_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     598             :   { 1351 /* get_global */, WebAssembly::GET_GLOBAL_I64_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     599             :   { 1362 /* get_local */, WebAssembly::GET_LOCAL_EXCEPT_REF_S, Convert__Imm1_0, Feature_HasExceptionHandling, { MCK_Imm }, },
     600             :   { 1362 /* get_local */, WebAssembly::GET_LOCAL_V128_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     601             :   { 1362 /* get_local */, WebAssembly::GET_LOCAL_F32_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     602             :   { 1362 /* get_local */, WebAssembly::GET_LOCAL_F64_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     603             :   { 1362 /* get_local */, WebAssembly::GET_LOCAL_I32_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     604             :   { 1362 /* get_local */, WebAssembly::GET_LOCAL_I64_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     605             :   { 1372 /* grow_memory */, WebAssembly::GROW_MEMORY_I32_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     606             :   { 1384 /* i16x8.add */, WebAssembly::ADD_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     607             :   { 1394 /* i16x8.add_saturate_s */, WebAssembly::ADD_SAT_S_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     608             :   { 1415 /* i16x8.add_saturate_u */, WebAssembly::ADD_SAT_U_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     609             :   { 1436 /* i16x8.all_true */, WebAssembly::ALLTRUE_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     610             :   { 1451 /* i16x8.any_true */, WebAssembly::ANYTRUE_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     611             :   { 1466 /* i16x8.eq */, WebAssembly::EQ_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     612             :   { 1475 /* i16x8.extract_lane_s */, WebAssembly::EXTRACT_LANE_v8i16_s_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     613             :   { 1496 /* i16x8.extract_lane_u */, WebAssembly::EXTRACT_LANE_v8i16_u_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     614             :   { 1517 /* i16x8.ge_s */, WebAssembly::GE_S_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     615             :   { 1528 /* i16x8.ge_u */, WebAssembly::GE_U_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     616             :   { 1539 /* i16x8.gt_s */, WebAssembly::GT_S_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     617             :   { 1550 /* i16x8.gt_u */, WebAssembly::GT_U_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     618             :   { 1561 /* i16x8.le_s */, WebAssembly::LE_S_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     619             :   { 1572 /* i16x8.le_u */, WebAssembly::LE_U_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     620             :   { 1583 /* i16x8.lt_s */, WebAssembly::LT_S_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     621             :   { 1594 /* i16x8.lt_u */, WebAssembly::LT_U_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     622             :   { 1605 /* i16x8.mul */, WebAssembly::MUL_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     623             :   { 1615 /* i16x8.ne */, WebAssembly::NE_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     624             :   { 1624 /* i16x8.neg */, WebAssembly::NEG_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     625             :   { 1634 /* i16x8.replace_lane */, WebAssembly::REPLACE_LANE_v8i16_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     626             :   { 1653 /* i16x8.shl */, WebAssembly::SHL_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     627             :   { 1663 /* i16x8.shr_s */, WebAssembly::SHR_S_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     628             :   { 1675 /* i16x8.shr_u */, WebAssembly::SHR_U_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     629             :   { 1687 /* i16x8.splat */, WebAssembly::SPLAT_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     630             :   { 1699 /* i16x8.sub */, WebAssembly::SUB_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     631             :   { 1709 /* i16x8.sub_saturate_s */, WebAssembly::SUB_SAT_S_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     632             :   { 1730 /* i16x8.sub_saturate_u */, WebAssembly::SUB_SAT_U_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     633             :   { 1751 /* i32.add */, WebAssembly::ADD_I32_S, Convert_NoOperands, 0, {  }, },
     634             :   { 1759 /* i32.and */, WebAssembly::AND_I32_S, Convert_NoOperands, 0, {  }, },
     635             :   { 1767 /* i32.atomic.load */, WebAssembly::ATOMIC_LOAD_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     636             :   { 1783 /* i32.atomic.load16_u */, WebAssembly::ATOMIC_LOAD16_U_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     637             :   { 1803 /* i32.atomic.load8_u */, WebAssembly::ATOMIC_LOAD8_U_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     638             :   { 1822 /* i32.atomic.rmw.add */, WebAssembly::ATOMIC_RMW_ADD_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     639             :   { 1841 /* i32.atomic.rmw.and */, WebAssembly::ATOMIC_RMW_AND_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     640             :   { 1860 /* i32.atomic.rmw.cmpxchg */, WebAssembly::ATOMIC_RMW_CMPXCHG_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     641             :   { 1883 /* i32.atomic.rmw.or */, WebAssembly::ATOMIC_RMW_OR_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     642             :   { 1901 /* i32.atomic.rmw.sub */, WebAssembly::ATOMIC_RMW_SUB_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     643             :   { 1920 /* i32.atomic.rmw.xchg */, WebAssembly::ATOMIC_RMW_XCHG_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     644             :   { 1940 /* i32.atomic.rmw.xor */, WebAssembly::ATOMIC_RMW_XOR_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     645             :   { 1959 /* i32.atomic.rmw16_u.add */, WebAssembly::ATOMIC_RMW16_U_ADD_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     646             :   { 1982 /* i32.atomic.rmw16_u.and */, WebAssembly::ATOMIC_RMW16_U_AND_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     647             :   { 2005 /* i32.atomic.rmw16_u.cmpxchg */, WebAssembly::ATOMIC_RMW16_U_CMPXCHG_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     648             :   { 2032 /* i32.atomic.rmw16_u.or */, WebAssembly::ATOMIC_RMW16_U_OR_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     649             :   { 2054 /* i32.atomic.rmw16_u.sub */, WebAssembly::ATOMIC_RMW16_U_SUB_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     650             :   { 2077 /* i32.atomic.rmw16_u.xchg */, WebAssembly::ATOMIC_RMW16_U_XCHG_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     651             :   { 2101 /* i32.atomic.rmw16_u.xor */, WebAssembly::ATOMIC_RMW16_U_XOR_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     652             :   { 2124 /* i32.atomic.rmw8_u.add */, WebAssembly::ATOMIC_RMW8_U_ADD_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     653             :   { 2146 /* i32.atomic.rmw8_u.and */, WebAssembly::ATOMIC_RMW8_U_AND_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     654             :   { 2168 /* i32.atomic.rmw8_u.cmpxchg */, WebAssembly::ATOMIC_RMW8_U_CMPXCHG_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     655             :   { 2194 /* i32.atomic.rmw8_u.or */, WebAssembly::ATOMIC_RMW8_U_OR_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     656             :   { 2215 /* i32.atomic.rmw8_u.sub */, WebAssembly::ATOMIC_RMW8_U_SUB_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     657             :   { 2237 /* i32.atomic.rmw8_u.xchg */, WebAssembly::ATOMIC_RMW8_U_XCHG_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     658             :   { 2260 /* i32.atomic.rmw8_u.xor */, WebAssembly::ATOMIC_RMW8_U_XOR_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     659             :   { 2282 /* i32.atomic.store */, WebAssembly::ATOMIC_STORE_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     660             :   { 2299 /* i32.atomic.store16 */, WebAssembly::ATOMIC_STORE16_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     661             :   { 2318 /* i32.atomic.store8 */, WebAssembly::ATOMIC_STORE8_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     662             :   { 2336 /* i32.atomic.wait */, WebAssembly::ATOMIC_WAIT_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     663             :   { 2352 /* i32.call */, WebAssembly::CALL_I32_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     664             :   { 2361 /* i32.call_indirect */, WebAssembly::CALL_INDIRECT_I32_S, Convert__Imm1_0__imm_95_0, 0, { MCK_Imm }, },
     665             :   { 2379 /* i32.catch */, WebAssembly::CATCH_I32_S, Convert__Imm1_0, Feature_HasExceptionHandling, { MCK_Imm }, },
     666             :   { 2389 /* i32.clz */, WebAssembly::CLZ_I32_S, Convert_NoOperands, 0, {  }, },
     667             :   { 2397 /* i32.const */, WebAssembly::CONST_I32_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     668             :   { 2407 /* i32.ctz */, WebAssembly::CTZ_I32_S, Convert_NoOperands, 0, {  }, },
     669             :   { 2415 /* i32.div_s */, WebAssembly::DIV_S_I32_S, Convert_NoOperands, 0, {  }, },
     670             :   { 2425 /* i32.div_u */, WebAssembly::DIV_U_I32_S, Convert_NoOperands, 0, {  }, },
     671             :   { 2435 /* i32.eq */, WebAssembly::EQ_I32_S, Convert_NoOperands, 0, {  }, },
     672             :   { 2442 /* i32.eqz */, WebAssembly::EQZ_I32_S, Convert_NoOperands, 0, {  }, },
     673             :   { 2450 /* i32.extend16_s */, WebAssembly::I32_EXTEND16_S_I32_S, Convert_NoOperands, Feature_HasSignExt, {  }, },
     674             :   { 2465 /* i32.extend8_s */, WebAssembly::I32_EXTEND8_S_I32_S, Convert_NoOperands, Feature_HasSignExt, {  }, },
     675             :   { 2479 /* i32.ge_s */, WebAssembly::GE_S_I32_S, Convert_NoOperands, 0, {  }, },
     676             :   { 2488 /* i32.ge_u */, WebAssembly::GE_U_I32_S, Convert_NoOperands, 0, {  }, },
     677             :   { 2497 /* i32.gt_s */, WebAssembly::GT_S_I32_S, Convert_NoOperands, 0, {  }, },
     678             :   { 2506 /* i32.gt_u */, WebAssembly::GT_U_I32_S, Convert_NoOperands, 0, {  }, },
     679             :   { 2515 /* i32.le_s */, WebAssembly::LE_S_I32_S, Convert_NoOperands, 0, {  }, },
     680             :   { 2524 /* i32.le_u */, WebAssembly::LE_U_I32_S, Convert_NoOperands, 0, {  }, },
     681             :   { 2533 /* i32.load */, WebAssembly::LOAD_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     682             :   { 2542 /* i32.load16_s */, WebAssembly::LOAD16_S_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     683             :   { 2555 /* i32.load16_u */, WebAssembly::LOAD16_U_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     684             :   { 2568 /* i32.load8_s */, WebAssembly::LOAD8_S_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     685             :   { 2580 /* i32.load8_u */, WebAssembly::LOAD8_U_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     686             :   { 2592 /* i32.lt_s */, WebAssembly::LT_S_I32_S, Convert_NoOperands, 0, {  }, },
     687             :   { 2601 /* i32.lt_u */, WebAssembly::LT_U_I32_S, Convert_NoOperands, 0, {  }, },
     688             :   { 2610 /* i32.mul */, WebAssembly::MUL_I32_S, Convert_NoOperands, 0, {  }, },
     689             :   { 2618 /* i32.ne */, WebAssembly::NE_I32_S, Convert_NoOperands, 0, {  }, },
     690             :   { 2625 /* i32.or */, WebAssembly::OR_I32_S, Convert_NoOperands, 0, {  }, },
     691             :   { 2632 /* i32.popcnt */, WebAssembly::POPCNT_I32_S, Convert_NoOperands, 0, {  }, },
     692             :   { 2643 /* i32.reinterpret/f32 */, WebAssembly::I32_REINTERPRET_F32_S, Convert_NoOperands, 0, {  }, },
     693             :   { 2663 /* i32.rem_s */, WebAssembly::REM_S_I32_S, Convert_NoOperands, 0, {  }, },
     694             :   { 2673 /* i32.rem_u */, WebAssembly::REM_U_I32_S, Convert_NoOperands, 0, {  }, },
     695             :   { 2683 /* i32.rotl */, WebAssembly::ROTL_I32_S, Convert_NoOperands, 0, {  }, },
     696             :   { 2692 /* i32.rotr */, WebAssembly::ROTR_I32_S, Convert_NoOperands, 0, {  }, },
     697             :   { 2701 /* i32.select */, WebAssembly::SELECT_I32_S, Convert_NoOperands, 0, {  }, },
     698             :   { 2712 /* i32.shl */, WebAssembly::SHL_I32_S, Convert_NoOperands, 0, {  }, },
     699             :   { 2720 /* i32.shr_s */, WebAssembly::SHR_S_I32_S, Convert_NoOperands, 0, {  }, },
     700             :   { 2730 /* i32.shr_u */, WebAssembly::SHR_U_I32_S, Convert_NoOperands, 0, {  }, },
     701             :   { 2740 /* i32.store */, WebAssembly::STORE_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     702             :   { 2750 /* i32.store16 */, WebAssembly::STORE16_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     703             :   { 2762 /* i32.store8 */, WebAssembly::STORE8_I32_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     704             :   { 2773 /* i32.sub */, WebAssembly::SUB_I32_S, Convert_NoOperands, 0, {  }, },
     705             :   { 2781 /* i32.trunc_s/f32 */, WebAssembly::I32_TRUNC_S_F32_S, Convert_NoOperands, 0, {  }, },
     706             :   { 2797 /* i32.trunc_s/f64 */, WebAssembly::I32_TRUNC_S_F64_S, Convert_NoOperands, 0, {  }, },
     707             :   { 2813 /* i32.trunc_s:sat/f32 */, WebAssembly::I32_TRUNC_S_SAT_F32_S, Convert_NoOperands, Feature_HasNontrappingFPToInt, {  }, },
     708             :   { 2833 /* i32.trunc_s:sat/f64 */, WebAssembly::I32_TRUNC_S_SAT_F64_S, Convert_NoOperands, Feature_HasNontrappingFPToInt, {  }, },
     709             :   { 2853 /* i32.trunc_u/f32 */, WebAssembly::I32_TRUNC_U_F32_S, Convert_NoOperands, 0, {  }, },
     710             :   { 2869 /* i32.trunc_u/f64 */, WebAssembly::I32_TRUNC_U_F64_S, Convert_NoOperands, 0, {  }, },
     711             :   { 2885 /* i32.trunc_u:sat/f32 */, WebAssembly::I32_TRUNC_U_SAT_F32_S, Convert_NoOperands, Feature_HasNontrappingFPToInt, {  }, },
     712             :   { 2905 /* i32.trunc_u:sat/f64 */, WebAssembly::I32_TRUNC_U_SAT_F64_S, Convert_NoOperands, Feature_HasNontrappingFPToInt, {  }, },
     713             :   { 2925 /* i32.wrap/i64 */, WebAssembly::I32_WRAP_I64_S, Convert_NoOperands, 0, {  }, },
     714             :   { 2938 /* i32.xor */, WebAssembly::XOR_I32_S, Convert_NoOperands, 0, {  }, },
     715             :   { 2946 /* i32x4.add */, WebAssembly::ADD_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     716             :   { 2956 /* i32x4.all_true */, WebAssembly::ALLTRUE_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     717             :   { 2971 /* i32x4.any_true */, WebAssembly::ANYTRUE_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     718             :   { 2986 /* i32x4.eq */, WebAssembly::EQ_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     719             :   { 2995 /* i32x4.extract_lane */, WebAssembly::EXTRACT_LANE_v4i32_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     720             :   { 3014 /* i32x4.ge_s */, WebAssembly::GE_S_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     721             :   { 3025 /* i32x4.ge_u */, WebAssembly::GE_U_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     722             :   { 3036 /* i32x4.gt_s */, WebAssembly::GT_S_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     723             :   { 3047 /* i32x4.gt_u */, WebAssembly::GT_U_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     724             :   { 3058 /* i32x4.le_s */, WebAssembly::LE_S_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     725             :   { 3069 /* i32x4.le_u */, WebAssembly::LE_U_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     726             :   { 3080 /* i32x4.lt_s */, WebAssembly::LT_S_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     727             :   { 3091 /* i32x4.lt_u */, WebAssembly::LT_U_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     728             :   { 3102 /* i32x4.mul */, WebAssembly::MUL_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     729             :   { 3112 /* i32x4.ne */, WebAssembly::NE_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     730             :   { 3121 /* i32x4.neg */, WebAssembly::NEG_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     731             :   { 3131 /* i32x4.replace_lane */, WebAssembly::REPLACE_LANE_v4i32_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     732             :   { 3150 /* i32x4.shl */, WebAssembly::SHL_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     733             :   { 3160 /* i32x4.shr_s */, WebAssembly::SHR_S_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     734             :   { 3172 /* i32x4.shr_u */, WebAssembly::SHR_U_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     735             :   { 3184 /* i32x4.splat */, WebAssembly::SPLAT_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     736             :   { 3196 /* i32x4.sub */, WebAssembly::SUB_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     737             :   { 3206 /* i32x4.trunc_sat_s/f32x4 */, WebAssembly::fp_to_sint_v4i32_v4f32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     738             :   { 3230 /* i32x4.trunc_sat_u/f32x4 */, WebAssembly::fp_to_uint_v4i32_v4f32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     739             :   { 3254 /* i64.add */, WebAssembly::ADD_I64_S, Convert_NoOperands, 0, {  }, },
     740             :   { 3262 /* i64.and */, WebAssembly::AND_I64_S, Convert_NoOperands, 0, {  }, },
     741             :   { 3270 /* i64.atomic.load */, WebAssembly::ATOMIC_LOAD_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     742             :   { 3286 /* i64.atomic.load16_u */, WebAssembly::ATOMIC_LOAD16_U_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     743             :   { 3306 /* i64.atomic.load32_u */, WebAssembly::ATOMIC_LOAD32_U_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     744             :   { 3326 /* i64.atomic.load8_u */, WebAssembly::ATOMIC_LOAD8_U_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     745             :   { 3345 /* i64.atomic.rmw.add */, WebAssembly::ATOMIC_RMW_ADD_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     746             :   { 3364 /* i64.atomic.rmw.and */, WebAssembly::ATOMIC_RMW_AND_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     747             :   { 3383 /* i64.atomic.rmw.cmpxchg */, WebAssembly::ATOMIC_RMW_CMPXCHG_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     748             :   { 3406 /* i64.atomic.rmw.or */, WebAssembly::ATOMIC_RMW_OR_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     749             :   { 3424 /* i64.atomic.rmw.sub */, WebAssembly::ATOMIC_RMW_SUB_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     750             :   { 3443 /* i64.atomic.rmw.xchg */, WebAssembly::ATOMIC_RMW_XCHG_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     751             :   { 3463 /* i64.atomic.rmw.xor */, WebAssembly::ATOMIC_RMW_XOR_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     752             :   { 3482 /* i64.atomic.rmw16_u.add */, WebAssembly::ATOMIC_RMW16_U_ADD_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     753             :   { 3505 /* i64.atomic.rmw16_u.and */, WebAssembly::ATOMIC_RMW16_U_AND_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     754             :   { 3528 /* i64.atomic.rmw16_u.cmpxchg */, WebAssembly::ATOMIC_RMW16_U_CMPXCHG_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     755             :   { 3555 /* i64.atomic.rmw16_u.or */, WebAssembly::ATOMIC_RMW16_U_OR_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     756             :   { 3577 /* i64.atomic.rmw16_u.sub */, WebAssembly::ATOMIC_RMW16_U_SUB_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     757             :   { 3600 /* i64.atomic.rmw16_u.xchg */, WebAssembly::ATOMIC_RMW16_U_XCHG_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     758             :   { 3624 /* i64.atomic.rmw16_u.xor */, WebAssembly::ATOMIC_RMW16_U_XOR_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     759             :   { 3647 /* i64.atomic.rmw32_u.add */, WebAssembly::ATOMIC_RMW32_U_ADD_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     760             :   { 3670 /* i64.atomic.rmw32_u.and */, WebAssembly::ATOMIC_RMW32_U_AND_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     761             :   { 3693 /* i64.atomic.rmw32_u.cmpxchg */, WebAssembly::ATOMIC_RMW32_U_CMPXCHG_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     762             :   { 3720 /* i64.atomic.rmw32_u.or */, WebAssembly::ATOMIC_RMW32_U_OR_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     763             :   { 3742 /* i64.atomic.rmw32_u.sub */, WebAssembly::ATOMIC_RMW32_U_SUB_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     764             :   { 3765 /* i64.atomic.rmw32_u.xchg */, WebAssembly::ATOMIC_RMW32_U_XCHG_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     765             :   { 3789 /* i64.atomic.rmw32_u.xor */, WebAssembly::ATOMIC_RMW32_U_XOR_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     766             :   { 3812 /* i64.atomic.rmw8_u.add */, WebAssembly::ATOMIC_RMW8_U_ADD_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     767             :   { 3834 /* i64.atomic.rmw8_u.and */, WebAssembly::ATOMIC_RMW8_U_AND_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     768             :   { 3856 /* i64.atomic.rmw8_u.cmpxchg */, WebAssembly::ATOMIC_RMW8_U_CMPXCHG_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     769             :   { 3882 /* i64.atomic.rmw8_u.or */, WebAssembly::ATOMIC_RMW8_U_OR_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     770             :   { 3903 /* i64.atomic.rmw8_u.sub */, WebAssembly::ATOMIC_RMW8_U_SUB_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     771             :   { 3925 /* i64.atomic.rmw8_u.xchg */, WebAssembly::ATOMIC_RMW8_U_XCHG_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     772             :   { 3948 /* i64.atomic.rmw8_u.xor */, WebAssembly::ATOMIC_RMW8_U_XOR_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     773             :   { 3970 /* i64.atomic.store */, WebAssembly::ATOMIC_STORE_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     774             :   { 3987 /* i64.atomic.store16 */, WebAssembly::ATOMIC_STORE16_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     775             :   { 4006 /* i64.atomic.store32 */, WebAssembly::ATOMIC_STORE32_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     776             :   { 4025 /* i64.atomic.store8 */, WebAssembly::ATOMIC_STORE8_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     777             :   { 4043 /* i64.atomic.wait */, WebAssembly::ATOMIC_WAIT_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     778             :   { 4059 /* i64.call */, WebAssembly::CALL_I64_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     779             :   { 4068 /* i64.call_indirect */, WebAssembly::CALL_INDIRECT_I64_S, Convert__Imm1_0__imm_95_0, 0, { MCK_Imm }, },
     780             :   { 4086 /* i64.catch */, WebAssembly::CATCH_I64_S, Convert__Imm1_0, Feature_HasExceptionHandling, { MCK_Imm }, },
     781             :   { 4096 /* i64.clz */, WebAssembly::CLZ_I64_S, Convert_NoOperands, 0, {  }, },
     782             :   { 4104 /* i64.const */, WebAssembly::CONST_I64_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     783             :   { 4114 /* i64.ctz */, WebAssembly::CTZ_I64_S, Convert_NoOperands, 0, {  }, },
     784             :   { 4122 /* i64.div_s */, WebAssembly::DIV_S_I64_S, Convert_NoOperands, 0, {  }, },
     785             :   { 4132 /* i64.div_u */, WebAssembly::DIV_U_I64_S, Convert_NoOperands, 0, {  }, },
     786             :   { 4142 /* i64.eq */, WebAssembly::EQ_I64_S, Convert_NoOperands, 0, {  }, },
     787             :   { 4149 /* i64.eqz */, WebAssembly::EQZ_I64_S, Convert_NoOperands, 0, {  }, },
     788             :   { 4157 /* i64.extend16_s */, WebAssembly::I64_EXTEND16_S_I64_S, Convert_NoOperands, Feature_HasSignExt, {  }, },
     789             :   { 4172 /* i64.extend32_s */, WebAssembly::I64_EXTEND32_S_I64_S, Convert_NoOperands, Feature_HasSignExt, {  }, },
     790             :   { 4187 /* i64.extend8_s */, WebAssembly::I64_EXTEND8_S_I64_S, Convert_NoOperands, Feature_HasSignExt, {  }, },
     791             :   { 4201 /* i64.extend_s/i32 */, WebAssembly::I64_EXTEND_S_I32_S, Convert_NoOperands, 0, {  }, },
     792             :   { 4218 /* i64.extend_u/i32 */, WebAssembly::I64_EXTEND_U_I32_S, Convert_NoOperands, 0, {  }, },
     793             :   { 4235 /* i64.ge_s */, WebAssembly::GE_S_I64_S, Convert_NoOperands, 0, {  }, },
     794             :   { 4244 /* i64.ge_u */, WebAssembly::GE_U_I64_S, Convert_NoOperands, 0, {  }, },
     795             :   { 4253 /* i64.gt_s */, WebAssembly::GT_S_I64_S, Convert_NoOperands, 0, {  }, },
     796             :   { 4262 /* i64.gt_u */, WebAssembly::GT_U_I64_S, Convert_NoOperands, 0, {  }, },
     797             :   { 4271 /* i64.le_s */, WebAssembly::LE_S_I64_S, Convert_NoOperands, 0, {  }, },
     798             :   { 4280 /* i64.le_u */, WebAssembly::LE_U_I64_S, Convert_NoOperands, 0, {  }, },
     799             :   { 4289 /* i64.load */, WebAssembly::LOAD_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     800             :   { 4298 /* i64.load16_s */, WebAssembly::LOAD16_S_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     801             :   { 4311 /* i64.load16_u */, WebAssembly::LOAD16_U_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     802             :   { 4324 /* i64.load32_s */, WebAssembly::LOAD32_S_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     803             :   { 4337 /* i64.load32_u */, WebAssembly::LOAD32_U_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     804             :   { 4350 /* i64.load8_s */, WebAssembly::LOAD8_S_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     805             :   { 4362 /* i64.load8_u */, WebAssembly::LOAD8_U_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     806             :   { 4374 /* i64.lt_s */, WebAssembly::LT_S_I64_S, Convert_NoOperands, 0, {  }, },
     807             :   { 4383 /* i64.lt_u */, WebAssembly::LT_U_I64_S, Convert_NoOperands, 0, {  }, },
     808             :   { 4392 /* i64.mul */, WebAssembly::MUL_I64_S, Convert_NoOperands, 0, {  }, },
     809             :   { 4400 /* i64.ne */, WebAssembly::NE_I64_S, Convert_NoOperands, 0, {  }, },
     810             :   { 4407 /* i64.or */, WebAssembly::OR_I64_S, Convert_NoOperands, 0, {  }, },
     811             :   { 4414 /* i64.popcnt */, WebAssembly::POPCNT_I64_S, Convert_NoOperands, 0, {  }, },
     812             :   { 4425 /* i64.reinterpret/f64 */, WebAssembly::I64_REINTERPRET_F64_S, Convert_NoOperands, 0, {  }, },
     813             :   { 4445 /* i64.rem_s */, WebAssembly::REM_S_I64_S, Convert_NoOperands, 0, {  }, },
     814             :   { 4455 /* i64.rem_u */, WebAssembly::REM_U_I64_S, Convert_NoOperands, 0, {  }, },
     815             :   { 4465 /* i64.rotl */, WebAssembly::ROTL_I64_S, Convert_NoOperands, 0, {  }, },
     816             :   { 4474 /* i64.rotr */, WebAssembly::ROTR_I64_S, Convert_NoOperands, 0, {  }, },
     817             :   { 4483 /* i64.select */, WebAssembly::SELECT_I64_S, Convert_NoOperands, 0, {  }, },
     818             :   { 4494 /* i64.shl */, WebAssembly::SHL_I64_S, Convert_NoOperands, 0, {  }, },
     819             :   { 4502 /* i64.shr_s */, WebAssembly::SHR_S_I64_S, Convert_NoOperands, 0, {  }, },
     820             :   { 4512 /* i64.shr_u */, WebAssembly::SHR_U_I64_S, Convert_NoOperands, 0, {  }, },
     821             :   { 4522 /* i64.store */, WebAssembly::STORE_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     822             :   { 4532 /* i64.store16 */, WebAssembly::STORE16_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     823             :   { 4544 /* i64.store32 */, WebAssembly::STORE32_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     824             :   { 4556 /* i64.store8 */, WebAssembly::STORE8_I64_S, Convert__Imm1_1__Imm1_0, 0, { MCK_Imm, MCK_Imm }, },
     825             :   { 4567 /* i64.sub */, WebAssembly::SUB_I64_S, Convert_NoOperands, 0, {  }, },
     826             :   { 4575 /* i64.trunc_s/f32 */, WebAssembly::I64_TRUNC_S_F32_S, Convert_NoOperands, 0, {  }, },
     827             :   { 4591 /* i64.trunc_s/f64 */, WebAssembly::I64_TRUNC_S_F64_S, Convert_NoOperands, 0, {  }, },
     828             :   { 4607 /* i64.trunc_s:sat/f32 */, WebAssembly::I64_TRUNC_S_SAT_F32_S, Convert_NoOperands, Feature_HasNontrappingFPToInt, {  }, },
     829             :   { 4627 /* i64.trunc_s:sat/f64 */, WebAssembly::I64_TRUNC_S_SAT_F64_S, Convert_NoOperands, Feature_HasNontrappingFPToInt, {  }, },
     830             :   { 4647 /* i64.trunc_u/f32 */, WebAssembly::I64_TRUNC_U_F32_S, Convert_NoOperands, 0, {  }, },
     831             :   { 4663 /* i64.trunc_u/f64 */, WebAssembly::I64_TRUNC_U_F64_S, Convert_NoOperands, 0, {  }, },
     832             :   { 4679 /* i64.trunc_u:sat/f32 */, WebAssembly::I64_TRUNC_U_SAT_F32_S, Convert_NoOperands, Feature_HasNontrappingFPToInt, {  }, },
     833             :   { 4699 /* i64.trunc_u:sat/f64 */, WebAssembly::I64_TRUNC_U_SAT_F64_S, Convert_NoOperands, Feature_HasNontrappingFPToInt, {  }, },
     834             :   { 4719 /* i64.xor */, WebAssembly::XOR_I64_S, Convert_NoOperands, 0, {  }, },
     835             :   { 4727 /* i64x2.add */, WebAssembly::ADD_v2i64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     836             :   { 4737 /* i64x2.all_true */, WebAssembly::ALLTRUE_v2i64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     837             :   { 4752 /* i64x2.any_true */, WebAssembly::ANYTRUE_v2i64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     838             :   { 4767 /* i64x2.extract_lane */, WebAssembly::EXTRACT_LANE_v2i64_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     839             :   { 4786 /* i64x2.neg */, WebAssembly::NEG_v2i64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     840             :   { 4796 /* i64x2.replace_lane */, WebAssembly::REPLACE_LANE_v2i64_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     841             :   { 4815 /* i64x2.shl */, WebAssembly::SHL_v2i64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     842             :   { 4825 /* i64x2.shr_s */, WebAssembly::SHR_S_v2i64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     843             :   { 4837 /* i64x2.shr_u */, WebAssembly::SHR_U_v2i64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     844             :   { 4849 /* i64x2.splat */, WebAssembly::SPLAT_v2i64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     845             :   { 4861 /* i64x2.sub */, WebAssembly::SUB_v2i64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     846             :   { 4871 /* i64x2.trunc_sat_s/f64x2 */, WebAssembly::fp_to_sint_v2i64_v2f64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     847             :   { 4895 /* i64x2.trunc_sat_u/f64x2 */, WebAssembly::fp_to_uint_v2i64_v2f64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     848             :   { 4919 /* i8x16.add */, WebAssembly::ADD_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     849             :   { 4929 /* i8x16.add_saturate_s */, WebAssembly::ADD_SAT_S_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     850             :   { 4950 /* i8x16.add_saturate_u */, WebAssembly::ADD_SAT_U_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     851             :   { 4971 /* i8x16.all_true */, WebAssembly::ALLTRUE_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     852             :   { 4986 /* i8x16.any_true */, WebAssembly::ANYTRUE_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     853             :   { 5001 /* i8x16.eq */, WebAssembly::EQ_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     854             :   { 5010 /* i8x16.extract_lane_s */, WebAssembly::EXTRACT_LANE_v16i8_s_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     855             :   { 5031 /* i8x16.extract_lane_u */, WebAssembly::EXTRACT_LANE_v16i8_u_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     856             :   { 5052 /* i8x16.ge_s */, WebAssembly::GE_S_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     857             :   { 5063 /* i8x16.ge_u */, WebAssembly::GE_U_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     858             :   { 5074 /* i8x16.gt_s */, WebAssembly::GT_S_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     859             :   { 5085 /* i8x16.gt_u */, WebAssembly::GT_U_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     860             :   { 5096 /* i8x16.le_s */, WebAssembly::LE_S_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     861             :   { 5107 /* i8x16.le_u */, WebAssembly::LE_U_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     862             :   { 5118 /* i8x16.lt_s */, WebAssembly::LT_S_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     863             :   { 5129 /* i8x16.lt_u */, WebAssembly::LT_U_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     864             :   { 5140 /* i8x16.mul */, WebAssembly::MUL_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     865             :   { 5150 /* i8x16.ne */, WebAssembly::NE_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     866             :   { 5159 /* i8x16.neg */, WebAssembly::NEG_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     867             :   { 5169 /* i8x16.replace_lane */, WebAssembly::REPLACE_LANE_v16i8_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     868             :   { 5188 /* i8x16.shl */, WebAssembly::SHL_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     869             :   { 5198 /* i8x16.shr_s */, WebAssembly::SHR_S_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     870             :   { 5210 /* i8x16.shr_u */, WebAssembly::SHR_U_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     871             :   { 5222 /* i8x16.splat */, WebAssembly::SPLAT_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     872             :   { 5234 /* i8x16.sub */, WebAssembly::SUB_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     873             :   { 5244 /* i8x16.sub_saturate_s */, WebAssembly::SUB_SAT_S_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     874             :   { 5265 /* i8x16.sub_saturate_u */, WebAssembly::SUB_SAT_U_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     875             :   { 5286 /* loop */, WebAssembly::LOOP_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     876             :   { 5291 /* mem.grow */, WebAssembly::MEM_GROW_I32_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     877             :   { 5300 /* mem.size */, WebAssembly::MEM_SIZE_I32_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     878             :   { 5309 /* memory.grow */, WebAssembly::MEMORY_GROW_I32_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     879             :   { 5321 /* memory.size */, WebAssembly::MEMORY_SIZE_I32_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     880             :   { 5333 /* nop */, WebAssembly::NOP_S, Convert_NoOperands, 0, {  }, },
     881             :   { 5337 /* rethrow */, WebAssembly::RETHROW_S, Convert__Imm1_0, Feature_HasExceptionHandling, { MCK_Imm }, },
     882             :   { 5345 /* return */, WebAssembly::RETURN_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     883             :   { 5345 /* return */, WebAssembly::RETURN_v2f64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     884             :   { 5345 /* return */, WebAssembly::RETURN_v2i64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     885             :   { 5345 /* return */, WebAssembly::RETURN_v4f32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     886             :   { 5345 /* return */, WebAssembly::RETURN_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     887             :   { 5345 /* return */, WebAssembly::RETURN_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     888             :   { 5345 /* return */, WebAssembly::RETURN_EXCEPT_REF_S, Convert_NoOperands, 0, {  }, },
     889             :   { 5345 /* return */, WebAssembly::RETURN_F32_S, Convert_NoOperands, 0, {  }, },
     890             :   { 5345 /* return */, WebAssembly::RETURN_F64_S, Convert_NoOperands, 0, {  }, },
     891             :   { 5345 /* return */, WebAssembly::RETURN_I32_S, Convert_NoOperands, 0, {  }, },
     892             :   { 5345 /* return */, WebAssembly::RETURN_I64_S, Convert_NoOperands, 0, {  }, },
     893             :   { 5345 /* return */, WebAssembly::RETURN_VOID_S, Convert_NoOperands, 0, {  }, },
     894             :   { 5352 /* set_global */, WebAssembly::SET_GLOBAL_EXCEPT_REF_S, Convert__Imm1_0, Feature_HasExceptionHandling, { MCK_Imm }, },
     895             :   { 5352 /* set_global */, WebAssembly::SET_GLOBAL_V128_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     896             :   { 5352 /* set_global */, WebAssembly::SET_GLOBAL_F32_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     897             :   { 5352 /* set_global */, WebAssembly::SET_GLOBAL_F64_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     898             :   { 5352 /* set_global */, WebAssembly::SET_GLOBAL_I32_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     899             :   { 5352 /* set_global */, WebAssembly::SET_GLOBAL_I64_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     900             :   { 5363 /* set_local */, WebAssembly::SET_LOCAL_EXCEPT_REF_S, Convert__Imm1_0, Feature_HasExceptionHandling, { MCK_Imm }, },
     901             :   { 5363 /* set_local */, WebAssembly::SET_LOCAL_V128_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     902             :   { 5363 /* set_local */, WebAssembly::SET_LOCAL_F32_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     903             :   { 5363 /* set_local */, WebAssembly::SET_LOCAL_F64_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     904             :   { 5363 /* set_local */, WebAssembly::SET_LOCAL_I32_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     905             :   { 5363 /* set_local */, WebAssembly::SET_LOCAL_I64_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     906             :   { 5373 /* tee_local */, WebAssembly::TEE_LOCAL_EXCEPT_REF_S, Convert__Imm1_0, Feature_HasExceptionHandling, { MCK_Imm }, },
     907             :   { 5373 /* tee_local */, WebAssembly::TEE_LOCAL_V128_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     908             :   { 5373 /* tee_local */, WebAssembly::TEE_LOCAL_F32_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     909             :   { 5373 /* tee_local */, WebAssembly::TEE_LOCAL_F64_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     910             :   { 5373 /* tee_local */, WebAssembly::TEE_LOCAL_I32_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     911             :   { 5373 /* tee_local */, WebAssembly::TEE_LOCAL_I64_S, Convert__Imm1_0, 0, { MCK_Imm }, },
     912             :   { 5383 /* throw */, WebAssembly::THROW_I32_S, Convert__Imm1_0, Feature_HasExceptionHandling, { MCK_Imm }, },
     913             :   { 5383 /* throw */, WebAssembly::THROW_I64_S, Convert__Imm1_0, Feature_HasExceptionHandling, { MCK_Imm }, },
     914             :   { 5389 /* try */, WebAssembly::TRY_S, Convert__Imm1_0, Feature_HasExceptionHandling, { MCK_Imm }, },
     915             :   { 5393 /* unreachable */, WebAssembly::UNREACHABLE_S, Convert_NoOperands, 0, {  }, },
     916             :   { 5405 /* v128.and */, WebAssembly::AND_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     917             :   { 5405 /* v128.and */, WebAssembly::AND_v2i64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     918             :   { 5405 /* v128.and */, WebAssembly::AND_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     919             :   { 5405 /* v128.and */, WebAssembly::AND_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     920             :   { 5414 /* v128.bitselect */, WebAssembly::BITSELECT_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     921             :   { 5414 /* v128.bitselect */, WebAssembly::BITSELECT_v2f64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     922             :   { 5414 /* v128.bitselect */, WebAssembly::BITSELECT_v2i64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     923             :   { 5414 /* v128.bitselect */, WebAssembly::BITSELECT_v4f32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     924             :   { 5414 /* v128.bitselect */, WebAssembly::BITSELECT_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     925             :   { 5414 /* v128.bitselect */, WebAssembly::BITSELECT_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     926             :   { 5429 /* v128.call */, WebAssembly::CALL_v16i8_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     927             :   { 5429 /* v128.call */, WebAssembly::CALL_v2f64_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     928             :   { 5429 /* v128.call */, WebAssembly::CALL_v2i64_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     929             :   { 5429 /* v128.call */, WebAssembly::CALL_v4f32_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     930             :   { 5429 /* v128.call */, WebAssembly::CALL_v4i32_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     931             :   { 5429 /* v128.call */, WebAssembly::CALL_v8i16_S, Convert__Imm1_0, Feature_HasSIMD128, { MCK_Imm }, },
     932             :   { 5439 /* v128.call_indirect */, WebAssembly::CALL_INDIRECT_v16i8_S, Convert__Imm1_0__imm_95_0, Feature_HasSIMD128, { MCK_Imm }, },
     933             :   { 5439 /* v128.call_indirect */, WebAssembly::CALL_INDIRECT_v2f64_S, Convert__Imm1_0__imm_95_0, Feature_HasSIMD128, { MCK_Imm }, },
     934             :   { 5439 /* v128.call_indirect */, WebAssembly::CALL_INDIRECT_v2i64_S, Convert__Imm1_0__imm_95_0, Feature_HasSIMD128, { MCK_Imm }, },
     935             :   { 5439 /* v128.call_indirect */, WebAssembly::CALL_INDIRECT_v4f32_S, Convert__Imm1_0__imm_95_0, Feature_HasSIMD128, { MCK_Imm }, },
     936             :   { 5439 /* v128.call_indirect */, WebAssembly::CALL_INDIRECT_v4i32_S, Convert__Imm1_0__imm_95_0, Feature_HasSIMD128, { MCK_Imm }, },
     937             :   { 5439 /* v128.call_indirect */, WebAssembly::CALL_INDIRECT_v8i16_S, Convert__Imm1_0__imm_95_0, Feature_HasSIMD128, { MCK_Imm }, },
     938             :   { 5458 /* v128.const */, WebAssembly::CONST_V128_v2f64_S, Convert__Imm1_0__Imm1_1, Feature_HasSIMD128, { MCK_Imm, MCK_Imm }, },
     939             :   { 5458 /* v128.const */, WebAssembly::CONST_V128_v2i64_S, Convert__Imm1_0__Imm1_1, Feature_HasSIMD128, { MCK_Imm, MCK_Imm }, },
     940             :   { 5458 /* v128.const */, WebAssembly::CONST_V128_v4f32_S, Convert__Imm1_0__Imm1_1__Imm1_2__Imm1_3, Feature_HasSIMD128, { MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm }, },
     941             :   { 5458 /* v128.const */, WebAssembly::CONST_V128_v4i32_S, Convert__Imm1_0__Imm1_1__Imm1_2__Imm1_3, Feature_HasSIMD128, { MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm }, },
     942             :   { 5458 /* v128.const */, WebAssembly::CONST_V128_v8i16_S, Convert__Imm1_0__Imm1_1__Imm1_2__Imm1_3__Imm1_4__Imm1_5__Imm1_6__Imm1_7, Feature_HasSIMD128, { MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm }, },
     943             :   { 5458 /* v128.const */, WebAssembly::CONST_V128_v16i8_S, Convert__Imm1_0__Imm1_1__Imm1_2__Imm1_3__Imm1_4__Imm1_5__Imm1_6__Imm1_7__Imm1_8__Imm1_9__Imm1_10__Imm1_11__Imm1_12__Imm1_13__Imm1_14__Imm1_15, Feature_HasSIMD128, { MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm }, },
     944             :   { 5469 /* v128.load */, WebAssembly::LOAD_v16i8_S, Convert__Imm1_1__Imm1_0, Feature_HasSIMD128, { MCK_Imm, MCK_Imm }, },
     945             :   { 5469 /* v128.load */, WebAssembly::LOAD_v2f64_S, Convert__Imm1_1__Imm1_0, Feature_HasSIMD128, { MCK_Imm, MCK_Imm }, },
     946             :   { 5469 /* v128.load */, WebAssembly::LOAD_v2i64_S, Convert__Imm1_1__Imm1_0, Feature_HasSIMD128, { MCK_Imm, MCK_Imm }, },
     947             :   { 5469 /* v128.load */, WebAssembly::LOAD_v4f32_S, Convert__Imm1_1__Imm1_0, Feature_HasSIMD128, { MCK_Imm, MCK_Imm }, },
     948             :   { 5469 /* v128.load */, WebAssembly::LOAD_v4i32_S, Convert__Imm1_1__Imm1_0, Feature_HasSIMD128, { MCK_Imm, MCK_Imm }, },
     949             :   { 5469 /* v128.load */, WebAssembly::LOAD_v8i16_S, Convert__Imm1_1__Imm1_0, Feature_HasSIMD128, { MCK_Imm, MCK_Imm }, },
     950             :   { 5479 /* v128.not */, WebAssembly::NOT_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     951             :   { 5479 /* v128.not */, WebAssembly::NOT_v2i64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     952             :   { 5479 /* v128.not */, WebAssembly::NOT_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     953             :   { 5479 /* v128.not */, WebAssembly::NOT_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     954             :   { 5488 /* v128.or */, WebAssembly::OR_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     955             :   { 5488 /* v128.or */, WebAssembly::OR_v2i64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     956             :   { 5488 /* v128.or */, WebAssembly::OR_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     957             :   { 5488 /* v128.or */, WebAssembly::OR_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     958             :   { 5496 /* v128.store */, WebAssembly::STORE_v16i8_S, Convert__Imm1_1__Imm1_0, Feature_HasSIMD128, { MCK_Imm, MCK_Imm }, },
     959             :   { 5496 /* v128.store */, WebAssembly::STORE_v2f64_S, Convert__Imm1_1__Imm1_0, Feature_HasSIMD128, { MCK_Imm, MCK_Imm }, },
     960             :   { 5496 /* v128.store */, WebAssembly::STORE_v2i64_S, Convert__Imm1_1__Imm1_0, Feature_HasSIMD128, { MCK_Imm, MCK_Imm }, },
     961             :   { 5496 /* v128.store */, WebAssembly::STORE_v4f32_S, Convert__Imm1_1__Imm1_0, Feature_HasSIMD128, { MCK_Imm, MCK_Imm }, },
     962             :   { 5496 /* v128.store */, WebAssembly::STORE_v4i32_S, Convert__Imm1_1__Imm1_0, Feature_HasSIMD128, { MCK_Imm, MCK_Imm }, },
     963             :   { 5496 /* v128.store */, WebAssembly::STORE_v8i16_S, Convert__Imm1_1__Imm1_0, Feature_HasSIMD128, { MCK_Imm, MCK_Imm }, },
     964             :   { 5507 /* v128.xor */, WebAssembly::XOR_v16i8_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     965             :   { 5507 /* v128.xor */, WebAssembly::XOR_v2i64_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     966             :   { 5507 /* v128.xor */, WebAssembly::XOR_v4i32_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     967             :   { 5507 /* v128.xor */, WebAssembly::XOR_v8i16_S, Convert_NoOperands, Feature_HasSIMD128, {  }, },
     968             :   { 5516 /* v8x16.shuffle */, WebAssembly::SHUFFLE_v16i8_S, Convert__Imm1_0__Imm1_1__Imm1_2__Imm1_3__Imm1_4__Imm1_5__Imm1_6__Imm1_7__Imm1_8__Imm1_9__Imm1_10__Imm1_11__Imm1_12__Imm1_13__Imm1_14__Imm1_15, Feature_HasSIMD128, { MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm, MCK_Imm }, },
     969             : };
     970             : 
     971             : #include "llvm/Support/Debug.h"
     972             : #include "llvm/Support/Format.h"
     973             : 
     974         177 : unsigned WebAssemblyAsmParser::
     975             : MatchInstructionImpl(const OperandVector &Operands,
     976             :                      MCInst &Inst,
     977             :                      uint64_t &ErrorInfo,
     978             :                      bool matchingInlineAsm, unsigned VariantID) {
     979             :   // Eliminate obvious mismatches.
     980         177 :   if (Operands.size() > 17) {
     981           0 :     ErrorInfo = 17;
     982           0 :     return Match_InvalidOperand;
     983             :   }
     984             : 
     985             :   // Get the current feature set.
     986         177 :   uint64_t AvailableFeatures = getAvailableFeatures();
     987             : 
     988             :   // Get the instruction mnemonic, which is the first token.
     989         177 :   StringRef Mnemonic = ((WebAssemblyOperand&)*Operands[0]).getToken();
     990             : 
     991             :   // Some state to try to produce better error messages.
     992             :   bool HadMatchOtherThanFeatures = false;
     993             :   bool HadMatchOtherThanPredicate = false;
     994             :   unsigned RetCode = Match_InvalidOperand;
     995             :   uint64_t MissingFeatures = ~0ULL;
     996             :   // Set ErrorInfo to the operand that mismatches if it is
     997             :   // wrong for all instances of the instruction.
     998         177 :   ErrorInfo = ~0ULL;
     999             :   // Find the appropriate table for this asm variant.
    1000             :   const MatchEntry *Start, *End;
    1001         177 :   switch (VariantID) {
    1002           0 :   default: llvm_unreachable("invalid variant!");
    1003             :   case 0: Start = std::begin(MatchTable0); End = std::end(MatchTable0); break;
    1004             :   }
    1005             :   // Search the table.
    1006             :   auto MnemonicRange = std::equal_range(Start, End, Mnemonic, LessOpcode());
    1007             : 
    1008             :   DEBUG_WITH_TYPE("asm-matcher", dbgs() << "AsmMatcher: found " <<
    1009             :   std::distance(MnemonicRange.first, MnemonicRange.second) << 
    1010             :   " encodings with mnemonic '" << Mnemonic << "'\n");
    1011             : 
    1012             :   // Return a more specific error code if no mnemonics match.
    1013         177 :   if (MnemonicRange.first == MnemonicRange.second)
    1014             :     return Match_MnemonicFail;
    1015             : 
    1016          29 :   for (const MatchEntry *it = MnemonicRange.first, *ie = MnemonicRange.second;
    1017         206 :        it != ie; ++it) {
    1018         206 :     bool HasRequiredFeatures =
    1019         206 :       (AvailableFeatures & it->RequiredFeatures) == it->RequiredFeatures;
    1020             :     DEBUG_WITH_TYPE("asm-matcher", dbgs() << "Trying to match opcode "
    1021             :                                           << MII.getName(it->Opcode) << "\n");
    1022             :     // equal_range guarantees that instruction mnemonic matches.
    1023             :     assert(Mnemonic == it->getMnemonic());
    1024             :     bool OperandsValid = true;
    1025         395 :     for (unsigned FormalIdx = 0, ActualIdx = 1; FormalIdx != 16; ++FormalIdx) {
    1026         392 :       auto Formal = static_cast<MatchClassKind>(it->Classes[FormalIdx]);
    1027             :       DEBUG_WITH_TYPE("asm-matcher",
    1028             :                       dbgs() << "  Matching formal operand class " << getMatchClassName(Formal)
    1029             :                              << " against actual operand at index " << ActualIdx);
    1030         392 :       if (ActualIdx < Operands.size())
    1031             :         DEBUG_WITH_TYPE("asm-matcher", dbgs() << " (";
    1032             :                         Operands[ActualIdx]->print(dbgs()); dbgs() << "): ");
    1033             :       else
    1034             :         DEBUG_WITH_TYPE("asm-matcher", dbgs() << ": ");
    1035         392 :       if (ActualIdx >= Operands.size()) {
    1036             :         DEBUG_WITH_TYPE("asm-matcher", dbgs() << "actual operand index out of range ");
    1037         183 :         OperandsValid = (Formal == InvalidMatchClass) || isSubclass(Formal, OptionalMatchClass);
    1038           0 :         if (!OperandsValid) ErrorInfo = ActualIdx;
    1039             :         break;
    1040             :       }
    1041             :       MCParsedAsmOperand &Actual = *Operands[ActualIdx];
    1042             :       unsigned Diag = validateOperandClass(Actual, Formal);
    1043             :       if (Diag == Match_Success) {
    1044             :         DEBUG_WITH_TYPE("asm-matcher",
    1045             :                         dbgs() << "match success using generic matcher\n");
    1046         189 :         ++ActualIdx;
    1047         189 :         continue;
    1048             :       }
    1049             :       // If the generic handler indicates an invalid operand
    1050             :       // failure, check for a special case.
    1051             :       if (Diag != Match_Success) {
    1052          20 :         unsigned TargetDiag = validateTargetOperandClass(Actual, Formal);
    1053          20 :         if (TargetDiag == Match_Success) {
    1054             :           DEBUG_WITH_TYPE("asm-matcher",
    1055             :                           dbgs() << "match success using target matcher\n");
    1056           0 :           ++ActualIdx;
    1057           0 :           continue;
    1058             :         }
    1059             :         // If the target matcher returned a specific error code use
    1060             :         // that, else use the one from the generic matcher.
    1061          20 :         if (TargetDiag != Match_InvalidOperand && HasRequiredFeatures)
    1062             :           Diag = TargetDiag;
    1063             :       }
    1064             :       // If current formal operand wasn't matched and it is optional
    1065             :       // then try to match next formal operand
    1066          20 :       if (Diag == Match_InvalidOperand && isSubclass(Formal, OptionalMatchClass)) {
    1067             :         DEBUG_WITH_TYPE("asm-matcher", dbgs() << "ignoring optional operand\n");
    1068             :         continue;
    1069             :       }
    1070             :       // If this operand is broken for all of the instances of this
    1071             :       // mnemonic, keep track of it so we can report loc info.
    1072             :       // If we already had a match that only failed due to a
    1073             :       // target predicate, that diagnostic is preferred.
    1074          20 :       if (!HadMatchOtherThanPredicate &&
    1075          15 :           (it == MnemonicRange.first || ErrorInfo <= ActualIdx)) {
    1076          20 :         if (HasRequiredFeatures && (ErrorInfo != ActualIdx || Diag != Match_InvalidOperand))
    1077             :           RetCode = Diag;
    1078          20 :         ErrorInfo = ActualIdx;
    1079             :       }
    1080             :       // Otherwise, just reject this instance of the mnemonic.
    1081             :       OperandsValid = false;
    1082             :       break;
    1083             :     }
    1084             : 
    1085         206 :     if (!OperandsValid) {
    1086             :       DEBUG_WITH_TYPE("asm-matcher", dbgs() << "Opcode result: multiple "
    1087             :                                                "operand mismatches, ignoring "
    1088             :                                                "this opcode\n");
    1089             :       continue;
    1090             :     }
    1091         186 :     if (!HasRequiredFeatures) {
    1092             :       HadMatchOtherThanFeatures = true;
    1093           9 :       uint64_t NewMissingFeatures = it->RequiredFeatures & ~AvailableFeatures;
    1094             :       DEBUG_WITH_TYPE("asm-matcher", dbgs() << "Missing target features: "
    1095             :                                             << format_hex(NewMissingFeatures, 18)
    1096             :                                             << "\n");
    1097           9 :       if (countPopulation(NewMissingFeatures) <=
    1098             :           countPopulation(MissingFeatures))
    1099             :         MissingFeatures = NewMissingFeatures;
    1100           9 :       continue;
    1101             :     }
    1102             : 
    1103             :     Inst.clear();
    1104             : 
    1105         177 :     Inst.setOpcode(it->Opcode);
    1106             :     // We have a potential match but have not rendered the operands.
    1107             :     // Check the target predicate to handle any context sensitive
    1108             :     // constraints.
    1109             :     // For example, Ties that are referenced multiple times must be
    1110             :     // checked here to ensure the input is the same for each match
    1111             :     // constraints. If we leave it any later the ties will have been
    1112             :     // canonicalized
    1113             :     unsigned MatchResult;
    1114         177 :     if ((MatchResult = checkEarlyTargetMatchPredicate(Inst, Operands)) != Match_Success) {
    1115             :       Inst.clear();
    1116             :       DEBUG_WITH_TYPE(
    1117             :           "asm-matcher",
    1118             :           dbgs() << "Early target match predicate failed with diag code "
    1119             :                  << MatchResult << "\n");
    1120             :       RetCode = MatchResult;
    1121             :       HadMatchOtherThanPredicate = true;
    1122             :       continue;
    1123             :     }
    1124             : 
    1125         177 :     if (matchingInlineAsm) {
    1126           0 :       convertToMapAndConstraints(it->ConvertFn, Operands);
    1127           0 :       if (!checkAsmTiedOperandConstraints(*this, it->ConvertFn, Operands, ErrorInfo))
    1128             :         return Match_InvalidTiedOperand;
    1129             : 
    1130           0 :       return Match_Success;
    1131             :     }
    1132             : 
    1133             :     // We have selected a definite instruction, convert the parsed
    1134             :     // operands into the appropriate MCInst.
    1135         177 :     convertToMCInst(it->ConvertFn, Inst, it->Opcode, Operands);
    1136             : 
    1137             :     // We have a potential match. Check the target predicate to
    1138             :     // handle any context sensitive constraints.
    1139         177 :     if ((MatchResult = checkTargetMatchPredicate(Inst)) != Match_Success) {
    1140             :       DEBUG_WITH_TYPE("asm-matcher",
    1141             :                       dbgs() << "Target match predicate failed with diag code "
    1142             :                              << MatchResult << "\n");
    1143             :       Inst.clear();
    1144             :       RetCode = MatchResult;
    1145             :       HadMatchOtherThanPredicate = true;
    1146           0 :       continue;
    1147             :     }
    1148             : 
    1149         177 :     if (!checkAsmTiedOperandConstraints(*this, it->ConvertFn, Operands, ErrorInfo))
    1150           0 :       return Match_InvalidTiedOperand;
    1151             : 
    1152             :     DEBUG_WITH_TYPE(
    1153             :         "asm-matcher",
    1154             :         dbgs() << "Opcode result: complete match, selecting this opcode\n");
    1155             :     return Match_Success;
    1156             :   }
    1157             : 
    1158             :   // Okay, we had no match.  Try to return a useful error code.
    1159           0 :   if (HadMatchOtherThanPredicate || !HadMatchOtherThanFeatures)
    1160             :     return RetCode;
    1161             : 
    1162             :   // Missing feature matches return which features were missing
    1163           0 :   ErrorInfo = MissingFeatures;
    1164           0 :   return Match_MissingFeature;
    1165             : }
    1166             : 
    1167             : #endif // GET_MATCHER_IMPLEMENTATION
    1168             : 
    1169             : 
    1170             : #ifdef GET_MNEMONIC_SPELL_CHECKER
    1171             : #undef GET_MNEMONIC_SPELL_CHECKER
    1172             : 
    1173             : static std::string WebAssemblyMnemonicSpellCheck(StringRef S, uint64_t FBS, unsigned VariantID) {
    1174             :   const unsigned MaxEditDist = 2;
    1175             :   std::vector<StringRef> Candidates;
    1176             :   StringRef Prev = "";
    1177             : 
    1178             :   // Find the appropriate table for this asm variant.
    1179             :   const MatchEntry *Start, *End;
    1180             :   switch (VariantID) {
    1181             :   default: llvm_unreachable("invalid variant!");
    1182             :   case 0: Start = std::begin(MatchTable0); End = std::end(MatchTable0); break;
    1183             :   }
    1184             : 
    1185             :   for (auto I = Start; I < End; I++) {
    1186             :     // Ignore unsupported instructions.
    1187             :     if ((FBS & I->RequiredFeatures) != I->RequiredFeatures)
    1188             :       continue;
    1189             : 
    1190             :     StringRef T = I->getMnemonic();
    1191             :     // Avoid recomputing the edit distance for the same string.
    1192             :     if (T.equals(Prev))
    1193             :       continue;
    1194             : 
    1195             :     Prev = T;
    1196             :     unsigned Dist = S.edit_distance(T, false, MaxEditDist);
    1197             :     if (Dist <= MaxEditDist)
    1198             :       Candidates.push_back(T);
    1199             :   }
    1200             : 
    1201             :   if (Candidates.empty())
    1202             :     return "";
    1203             : 
    1204             :   std::string Res = ", did you mean: ";
    1205             :   unsigned i = 0;
    1206             :   for( ; i < Candidates.size() - 1; i++)
    1207             :     Res += Candidates[i].str() + ", ";
    1208             :   return Res + Candidates[i].str() + "?";
    1209             : }
    1210             : 
    1211             : #endif // GET_MNEMONIC_SPELL_CHECKER
    1212             : 

Generated by: LCOV version 1.13