blob: 218ae0d13189767b84b600f62ff34e791b5e4d45 [file] [log] [blame]
Andrew Scull5e1ddfa2018-08-14 10:06:54 +01001//===-- llvm/MC/MCFixedLenDisassembler.h - Decoder driver -------*- C++ -*-===//
2//
Andrew Walbran16937d02019-10-22 13:54:20 +01003// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
Andrew Scull5e1ddfa2018-08-14 10:06:54 +01006//
7//===----------------------------------------------------------------------===//
8// Fixed length disassembler decoder state machine driver.
9//===----------------------------------------------------------------------===//
10#ifndef LLVM_MC_MCFIXEDLENDISASSEMBLER_H
11#define LLVM_MC_MCFIXEDLENDISASSEMBLER_H
12
13namespace llvm {
14
15namespace MCD {
16// Disassembler state machine opcodes.
17enum DecoderOps {
18 OPC_ExtractField = 1, // OPC_ExtractField(uint8_t Start, uint8_t Len)
19 OPC_FilterValue, // OPC_FilterValue(uleb128 Val, uint16_t NumToSkip)
20 OPC_CheckField, // OPC_CheckField(uint8_t Start, uint8_t Len,
21 // uleb128 Val, uint16_t NumToSkip)
22 OPC_CheckPredicate, // OPC_CheckPredicate(uleb128 PIdx, uint16_t NumToSkip)
23 OPC_Decode, // OPC_Decode(uleb128 Opcode, uleb128 DIdx)
24 OPC_TryDecode, // OPC_TryDecode(uleb128 Opcode, uleb128 DIdx,
25 // uint16_t NumToSkip)
26 OPC_SoftFail, // OPC_SoftFail(uleb128 PMask, uleb128 NMask)
27 OPC_Fail // OPC_Fail()
28};
29
30} // namespace MCDecode
31} // namespace llvm
32
33#endif