blob: 3ff922b8225c91caac7096a50941b054afa8d229 [file] [log] [blame]
Sean Callanan8ed9f512009-12-19 02:59:52 +00001//===- X86DisassemblerShared.h - Emitter shared header ----------*- C++ -*-===//
2//
3// The LLVM Compiler Infrastructure
4//
5// This file is distributed under the University of Illinois Open Source
6// License. See LICENSE.TXT for details.
7//
8//===----------------------------------------------------------------------===//
9
10#ifndef X86DISASSEMBLERSHARED_H
11#define X86DISASSEMBLERSHARED_H
12
Nuno Lopes014dc702009-12-19 11:52:18 +000013#include <string.h>
Chandler Carruth4ffd89f2012-12-04 10:37:14 +000014#include <string>
Sean Callanan8ed9f512009-12-19 02:59:52 +000015
Daniel Dunbar87830872009-12-19 04:16:57 +000016#define INSTRUCTION_SPECIFIER_FIELDS \
Craig Topper5a2c6072012-08-01 07:39:18 +000017 struct OperandSpecifier operands[X86_MAX_OPERANDS]; \
Daniel Dunbar87830872009-12-19 04:16:57 +000018 bool filtered; \
19 InstructionContext insnContext; \
20 std::string name; \
21 \
22 InstructionSpecifier() { \
23 filtered = false; \
24 insnContext = IC; \
25 name = ""; \
26 modifierType = MODIFIER_NONE; \
27 modifierBase = 0; \
28 memset(operands, 0, sizeof(operands)); \
Sean Callanan8ed9f512009-12-19 02:59:52 +000029 }
30
31#define INSTRUCTION_IDS \
32 InstrUID instructionIDs[256];
33
34#include "../../lib/Target/X86/Disassembler/X86DisassemblerDecoderCommon.h"
35
36#undef INSTRUCTION_SPECIFIER_FIELDS
37#undef INSTRUCTION_IDS
38
39#endif