LLVM 20.0.0git
Classes | Macros | Typedefs | Functions | Variables
M68kDisassembler.cpp File Reference
#include "M68k.h"
#include "M68kRegisterInfo.h"
#include "M68kSubtarget.h"
#include "MCTargetDesc/M68kMCCodeEmitter.h"
#include "MCTargetDesc/M68kMCTargetDesc.h"
#include "TargetInfo/M68kTargetInfo.h"
#include "llvm/MC/MCAsmInfo.h"
#include "llvm/MC/MCContext.h"
#include "llvm/MC/MCDisassembler/MCDisassembler.h"
#include "llvm/MC/MCDecoderOps.h"
#include "llvm/MC/MCInst.h"
#include "llvm/MC/TargetRegistry.h"
#include "llvm/Support/Endian.h"
#include "llvm/Support/ErrorHandling.h"
#include "M68kGenDisassemblerTable.inc"

Go to the source code of this file.

Classes

struct  M68kDisassembler
 A disassembler class for M68k. More...
 

Macros

#define DEBUG_TYPE   "m68k-disassembler"
 
#define DecodeFPDR32RegisterClass   DecodeFPDRRegisterClass
 
#define DecodeFPDR64RegisterClass   DecodeFPDRRegisterClass
 
#define DecodeFPDR80RegisterClass   DecodeFPDRRegisterClass
 
#define DecodeFPICRegisterClass   DecodeFPCSCRegisterClass
 

Typedefs

typedef MCDisassembler::DecodeStatus DecodeStatus
 

Functions

static DecodeStatus DecodeRegisterClass (MCInst &Inst, uint64_t RegNo, uint64_t Address, const void *Decoder)
 
static DecodeStatus DecodeDR32RegisterClass (MCInst &Inst, uint64_t RegNo, uint64_t Address, const void *Decoder)
 
static DecodeStatus DecodeDR16RegisterClass (MCInst &Inst, uint64_t RegNo, uint64_t Address, const void *Decoder)
 
static DecodeStatus DecodeDR8RegisterClass (MCInst &Inst, uint64_t RegNo, uint64_t Address, const void *Decoder)
 
static DecodeStatus DecodeAR32RegisterClass (MCInst &Inst, uint64_t RegNo, uint64_t Address, const void *Decoder)
 
static DecodeStatus DecodeAR16RegisterClass (MCInst &Inst, uint64_t RegNo, uint64_t Address, const void *Decoder)
 
static DecodeStatus DecodeXR32RegisterClass (MCInst &Inst, uint64_t RegNo, uint64_t Address, const void *Decoder)
 
static DecodeStatus DecodeXR16RegisterClass (MCInst &Inst, uint64_t RegNo, uint64_t Address, const void *Decoder)
 
static DecodeStatus DecodeFPDRRegisterClass (MCInst &Inst, uint64_t RegNo, uint64_t Address, const void *Decoder)
 
static DecodeStatus DecodeFPCSCRegisterClass (MCInst &Inst, uint64_t RegNo, uint64_t Address, const void *Decoder)
 
static DecodeStatus DecodeCCRCRegisterClass (MCInst &Inst, APInt &Insn, uint64_t Address, const void *Decoder)
 
static DecodeStatus DecodeImm32 (MCInst &Inst, uint64_t Imm, uint64_t Address, const void *Decoder)
 
static MCDisassemblercreateM68kDisassembler (const Target &T, const MCSubtargetInfo &STI, MCContext &Ctx)
 
LLVM_EXTERNAL_VISIBILITY void LLVMInitializeM68kDisassembler ()
 

Variables

static const unsigned RegisterDecode []
 

Macro Definition Documentation

◆ DEBUG_TYPE

#define DEBUG_TYPE   "m68k-disassembler"

Definition at line 31 of file M68kDisassembler.cpp.

◆ DecodeFPDR32RegisterClass

#define DecodeFPDR32RegisterClass   DecodeFPDRRegisterClass

Definition at line 97 of file M68kDisassembler.cpp.

◆ DecodeFPDR64RegisterClass

#define DecodeFPDR64RegisterClass   DecodeFPDRRegisterClass

Definition at line 98 of file M68kDisassembler.cpp.

◆ DecodeFPDR80RegisterClass

#define DecodeFPDR80RegisterClass   DecodeFPDRRegisterClass

Definition at line 99 of file M68kDisassembler.cpp.

◆ DecodeFPICRegisterClass

#define DecodeFPICRegisterClass   DecodeFPCSCRegisterClass

Definition at line 106 of file M68kDisassembler.cpp.

Typedef Documentation

◆ DecodeStatus

Definition at line 33 of file M68kDisassembler.cpp.

Function Documentation

◆ createM68kDisassembler()

static MCDisassembler * createM68kDisassembler ( const Target T,
const MCSubtargetInfo STI,
MCContext Ctx 
)
static

Definition at line 165 of file M68kDisassembler.cpp.

Referenced by LLVMInitializeM68kDisassembler().

◆ DecodeAR16RegisterClass()

static DecodeStatus DecodeAR16RegisterClass ( MCInst Inst,
uint64_t  RegNo,
uint64_t  Address,
const void *  Decoder 
)
static

Definition at line 74 of file M68kDisassembler.cpp.

References DecodeRegisterClass().

◆ DecodeAR32RegisterClass()

static DecodeStatus DecodeAR32RegisterClass ( MCInst Inst,
uint64_t  RegNo,
uint64_t  Address,
const void *  Decoder 
)
static

Definition at line 68 of file M68kDisassembler.cpp.

References DecodeRegisterClass().

◆ DecodeCCRCRegisterClass()

static DecodeStatus DecodeCCRCRegisterClass ( MCInst Inst,
APInt Insn,
uint64_t  Address,
const void *  Decoder 
)
static

Definition at line 108 of file M68kDisassembler.cpp.

References llvm_unreachable.

◆ DecodeDR16RegisterClass()

static DecodeStatus DecodeDR16RegisterClass ( MCInst Inst,
uint64_t  RegNo,
uint64_t  Address,
const void *  Decoder 
)
static

Definition at line 56 of file M68kDisassembler.cpp.

References DecodeRegisterClass().

◆ DecodeDR32RegisterClass()

static DecodeStatus DecodeDR32RegisterClass ( MCInst Inst,
uint64_t  RegNo,
uint64_t  Address,
const void *  Decoder 
)
static

Definition at line 50 of file M68kDisassembler.cpp.

References DecodeRegisterClass().

◆ DecodeDR8RegisterClass()

static DecodeStatus DecodeDR8RegisterClass ( MCInst Inst,
uint64_t  RegNo,
uint64_t  Address,
const void *  Decoder 
)
static

Definition at line 62 of file M68kDisassembler.cpp.

References DecodeRegisterClass().

◆ DecodeFPCSCRegisterClass()

static DecodeStatus DecodeFPCSCRegisterClass ( MCInst Inst,
uint64_t  RegNo,
uint64_t  Address,
const void *  Decoder 
)
static

Definition at line 101 of file M68kDisassembler.cpp.

References DecodeRegisterClass().

◆ DecodeFPDRRegisterClass()

static DecodeStatus DecodeFPDRRegisterClass ( MCInst Inst,
uint64_t  RegNo,
uint64_t  Address,
const void *  Decoder 
)
static

Definition at line 92 of file M68kDisassembler.cpp.

References DecodeRegisterClass().

◆ DecodeImm32()

static DecodeStatus DecodeImm32 ( MCInst Inst,
uint64_t  Imm,
uint64_t  Address,
const void *  Decoder 
)
static

◆ DecodeRegisterClass()

static DecodeStatus DecodeRegisterClass ( MCInst Inst,
uint64_t  RegNo,
uint64_t  Address,
const void *  Decoder 
)
static

◆ DecodeXR16RegisterClass()

static DecodeStatus DecodeXR16RegisterClass ( MCInst Inst,
uint64_t  RegNo,
uint64_t  Address,
const void *  Decoder 
)
static

Definition at line 86 of file M68kDisassembler.cpp.

References DecodeRegisterClass().

◆ DecodeXR32RegisterClass()

static DecodeStatus DecodeXR32RegisterClass ( MCInst Inst,
uint64_t  RegNo,
uint64_t  Address,
const void *  Decoder 
)
static

Definition at line 80 of file M68kDisassembler.cpp.

References DecodeRegisterClass().

◆ LLVMInitializeM68kDisassembler()

LLVM_EXTERNAL_VISIBILITY void LLVMInitializeM68kDisassembler ( )

Variable Documentation

◆ RegisterDecode

const unsigned RegisterDecode[]
static
Initial value:
= {
M68k::D0, M68k::D1, M68k::D2, M68k::D3, M68k::D4, M68k::D5,
M68k::D6, M68k::D7, M68k::A0, M68k::A1, M68k::A2, M68k::A3,
M68k::A4, M68k::A5, M68k::A6, M68k::SP, M68k::FP0, M68k::FP1,
M68k::FP2, M68k::FP3, M68k::FP4, M68k::FP5, M68k::FP6, M68k::FP7,
M68k::FPIAR, M68k::FPS, M68k::FPC}

Definition at line 35 of file M68kDisassembler.cpp.

Referenced by DecodeRegisterClass().