Main Page | Class Hierarchy | Class List | File List | Class Members | File Members

PPCDisassembler Class Reference

#include <ppcdis.h>

Inheritance diagram for PPCDisassembler:

Disassembler Object List of all members.

Public Member Functions

 PPCDisassembler ()
virtual dis_insndecode (byte *code, int maxlen, CPU_ADDR addr)
virtual dis_insnduplicateInsn (dis_insn *disasm_insn)
virtual void getOpcodeMetrics (int &min_length, int &max_length, int &min_look_ahead, int &avg_look_ahead, int &addr_align)
virtual byte getSize (dis_insn *disasm_insn)
virtual char * getName ()
virtual char * str (dis_insn *disasm_insn, int style)
virtual char * strf (dis_insn *disasm_insn, int style, char *format)
virtual OBJECT_ID object_id () const
virtual bool validInsn (dis_insn *disasm_insn)

Protected Attributes

char insnstr [256]
ppcdis_insn insn

Constructor & Destructor Documentation

PPCDisassembler::PPCDisassembler  ) 
 

Definition at line 28 of file ppcdis.cc.


Member Function Documentation

dis_insn * PPCDisassembler::decode byte *  code,
int  maxlen,
CPU_ADDR  addr
[virtual]
 

Implements Disassembler.

Definition at line 32 of file ppcdis.cc.

References ppcdis_operand::abs, CPU_ADDR::addr32, big_endian, byte, create_host_int(), ppcdis_operand::creg, ppcdis_insn::data, dis_insn, ppcdis_operand::flags, ppcdis_operand::freg, ppcdis_operand::imm, insn, ppcdis_insn::name, NULL, ppcdis_operand::op, ppcdis_insn::op, ppcdis_insn::ops, powerpc_num_opcodes, powerpc_opcodes, powerpc_operands, PPC_OP, PPC_OPCODE_PPC, PPC_OPERAND_ABSOLUTE, PPC_OPERAND_CR, PPC_OPERAND_FAKE, PPC_OPERAND_FPR, PPC_OPERAND_GPR, PPC_OPERAND_NEXT, PPC_OPERAND_OPTIONAL, PPC_OPERAND_PARENS, PPC_OPERAND_RELATIVE, PPC_OPERAND_SIGNED, ppcdis_operand::reg, ppcdis_operand::rel, ppcdis_insn::size, uint32, ppcdis_insn::valid, and value.

dis_insn * PPCDisassembler::duplicateInsn dis_insn disasm_insn  )  [virtual]
 

Implements Disassembler.

Definition at line 178 of file ppcdis.cc.

References dis_insn, insn, and malloc().

char * PPCDisassembler::getName  )  [virtual]
 

Implements Disassembler.

Definition at line 195 of file ppcdis.cc.

void PPCDisassembler::getOpcodeMetrics int &  min_length,
int &  max_length,
int &  min_look_ahead,
int &  avg_look_ahead,
int &  addr_align
[virtual]
 

Implements Disassembler.

Definition at line 185 of file ppcdis.cc.

byte PPCDisassembler::getSize dis_insn disasm_insn  )  [virtual]
 

Implements Disassembler.

Definition at line 190 of file ppcdis.cc.

References byte, and dis_insn.

OBJECT_ID PPCDisassembler::object_id  )  const [virtual]
 

Returns:
unique object id.

Reimplemented from Object.

Definition at line 301 of file ppcdis.cc.

References ATOM_DISASM_PPC.

char * PPCDisassembler::str dis_insn disasm_insn,
int  style
[virtual]
 

Reimplemented from Disassembler.

Definition at line 200 of file ppcdis.cc.

References dis_insn, and strf().

char * PPCDisassembler::strf dis_insn disasm_insn,
int  style,
char *  format
[virtual]
 

Implements Disassembler.

Definition at line 205 of file ppcdis.cc.

References ppcdis_operand::abs, CPU_ADDR::addr32, addr_sym_func, addr_sym_func_context, powerpc_operand::bits, ppcdis_operand::creg, ppcdis_insn::data, dis_insn, DIS_STYLE_HIGHLIGHT, Disassembler::disable_highlighting(), dword, e_cs_default, e_cs_number, e_cs_symbol, Disassembler::enable_highlighting(), ppcdis_operand::flags, ppcdis_operand::freg, Disassembler::get_cs(), ppcdis_operand::imm, insnstr, ppcdis_operand::mem, ppcdis_insn::name, ppcdis_operand::op, ppcdis_insn::op, ppcdis_insn::ops, PPC_OPCODE_PPC, PPC_OPERAND_ABSOLUTE, PPC_OPERAND_CR, PPC_OPERAND_FPR, PPC_OPERAND_GPR, PPC_OPERAND_PARENS, PPC_OPERAND_RELATIVE, ppcdis_operand::reg, ppcdis_operand::rel, ppcdis_insn::size, and ppcdis_insn::valid.

Referenced by str().

bool PPCDisassembler::validInsn dis_insn disasm_insn  )  [virtual]
 

Implements Disassembler.

Definition at line 306 of file ppcdis.cc.

References dis_insn.


Member Data Documentation

ppcdis_insn PPCDisassembler::insn [protected]
 

Definition at line 61 of file ppcdis.h.

Referenced by decode(), and duplicateInsn().

char PPCDisassembler::insnstr[256] [protected]
 

Definition at line 60 of file ppcdis.h.

Referenced by strf().


The documentation for this class was generated from the following files:
Generated on Fri May 7 21:16:10 2004 by doxygen 1.3.5