Class: OneGadget::Emulators::ArmFamily
- Defined in:
- lib/one_gadget/emulators/arm_family.rb
Overview
Behaviour shared by the two ARM-architecture emulators, Arm (AArch32) and
AArch64: the condition-code table plus the parts of the calling convention
and memory model that are identical in 32- and 64-bit mode. The common base
each inherits (the ARM counterpart of X86); everything that genuinely
differs (instruction set, register width, pc handling) stays in the
individual classes.
Constant Summary collapse
- COND =
ARM condition-code suffix (the
<cc>inb<cc>/b.<cc>) mapped to a shared Conditional::RELATION predicate. (x86 uses X86::JCC.) { 'eq' => :eq, 'ne' => :ne, 'hs' => :uge, 'cs' => :uge, 'lo' => :ult, 'cc' => :ult, 'hi' => :ugt, 'ls' => :ule, 'ge' => :sge, 'lt' => :slt, 'gt' => :sgt, 'le' => :sle, 'mi' => :slt, 'pl' => :sge }.freeze
- COMPARES =
This arch family's flag-setting compare mnemonics, mapped to the ALU op whose result their flags reflect (see Conditional::COMPARE_OPS). x86 has its own X86::COMPARES.
{ 'cmp' => :sub, 'cmn' => :add, 'tst' => :and }.freeze
Constants inherited from Processor
Constants included from Constraints
Constraints::ADDRESS_TYPES, Constraints::CLOBBERED, Constraints::NULLABLE_REQUIREMENTS, Constraints::POINTER_REQUIREMENTS
Constants included from Conditional
Conditional::COMPARE_OPS, Conditional::NEGATE, Conditional::RELATION, Conditional::ZERO
Instance Attribute Summary
Attributes inherited from Processor
#bp, #pc, #refused_line, #registers, #sp
Method Summary
Methods inherited from Processor
#argument, bits, #initialize, instruction_table, #instructions, line_memo, #parse, #process, #process!, #reach_terminal_call, #terminal_call?
Methods included from TrackedMemory
#bp_based_stack, #get_corresponding_stack, #resolve_address, #setup_frame_pointer, #sp_based_stack, #writes_through
Methods included from Constraints
#address_deref0?, #closed_fds, #constraint_key, #constraints, #drop_implied_nonzero, #drop_restated_null, #render_constraint
Methods included from Conditional
#branch_on_bit, #branch_on_compare, #branch_on_zero, #comparisons_on, #mnemonic, #operand_str, #record_compare, #resolve_pending_branch, #satisfiable?, #value_str
Constructor Details
This class inherits a constructor from OneGadget::Emulators::Processor