ROSE 0.11.145.192
Public Types | Public Member Functions | Public Attributes | List of all members
Rose::BinaryAnalysis::Disassembler::M68k::Decoder Class Referenceabstract

Description

Interface for disassembling a single instruction.

Each instruction (or in some cases groups of closely related instructions) will define a subclass whose operator() unparses a single instruction and returns a SgAsmM68kInstruction. These functors are allocated and inserted into a list. When an instruction is to be disassembled, the list is scanned to find the first entry that matches, and then its operator() is invoked. An entry matches if the instruction bits to be disassembled match any of the BitPattern objects.

An instruction decoder is enabled if the disassembler's family (see M68k constructors) bit-wise ANDed with the decoder family (see M68k constructor) is non-zero.

Definition at line 48 of file Disassembler/M68k.h.

#include <Rose/BinaryAnalysis/Disassembler/M68k.h>

Collaboration diagram for Rose::BinaryAnalysis::Disassembler::M68k::Decoder:
Collaboration graph
[legend]

Public Types

typedef M68k D
 

Public Member Functions

 Decoder (const std::string &name, unsigned family, const BitPattern< uint16_t > &pattern)
 
virtual SgAsmM68kInstructionoperator() (State &, const D *d, unsigned w0)=0
 

Public Attributes

std::string name
 
unsigned family
 
BitPattern< uint16_t > pattern
 

Member Typedef Documentation

◆ D

Definition at line 56 of file Disassembler/M68k.h.

Constructor & Destructor Documentation

◆ Decoder()

Rose::BinaryAnalysis::Disassembler::M68k::Decoder::Decoder ( const std::string &  name,
unsigned  family,
const BitPattern< uint16_t > &  pattern 
)
inline

Definition at line 50 of file Disassembler/M68k.h.

◆ ~Decoder()

virtual Rose::BinaryAnalysis::Disassembler::M68k::Decoder::~Decoder ( )
inlinevirtual

Definition at line 52 of file Disassembler/M68k.h.

Member Data Documentation

◆ name

std::string Rose::BinaryAnalysis::Disassembler::M68k::Decoder::name

Definition at line 53 of file Disassembler/M68k.h.

◆ family

unsigned Rose::BinaryAnalysis::Disassembler::M68k::Decoder::family

Definition at line 54 of file Disassembler/M68k.h.

◆ pattern

BitPattern<uint16_t> Rose::BinaryAnalysis::Disassembler::M68k::Decoder::pattern

Definition at line 55 of file Disassembler/M68k.h.


The documentation for this class was generated from the following file: