[−][src]Struct iced_x86::InstructionInfo
Contains information about an instruction, eg. read/written registers, read/written RFLAGS
bits, CPUID
feature bit, etc.
Created by an InstructionInfoFactory
.
Implementations
impl InstructionInfo
[src]
#[must_use]pub fn used_registers(&self) -> &[UsedRegister]
[src]
Gets all accessed registers. This method doesn't return all accessed registers if is_save_restore_instruction()
is true
.
Some instructions have a r16
/r32
operand but only use the low 8 bits of the register. In that case
this method returns the 8-bit register even if it's SPL
, BPL
, SIL
, DIL
and the
instruction was decoded in 16 or 32-bit mode. This is more accurate than returning the r16
/r32
register. Example instructions that do this: PINSRB
, ARPL
#[must_use]pub fn used_memory(&self) -> &[UsedMemory]
[src]
Gets all accessed memory locations
#[must_use]pub fn is_privileged(&self) -> bool
[src]
true
if it's a privileged instruction (all CPL=0 instructions (except VMCALL
) and IOPL instructions IN
, INS
, OUT
, OUTS
, CLI
, STI
)
#[must_use]pub fn is_stack_instruction(&self) -> bool
[src]
true
if this is an instruction that implicitly uses the stack pointer (SP
/ESP
/RSP
), eg. CALL
, PUSH
, POP
, RET
, etc.
See also Instruction::stack_pointer_increment()
#[must_use]pub fn is_save_restore_instruction(&self) -> bool
[src]
true
if it's an instruction that saves or restores too many registers (eg. FXRSTOR
, XSAVE
, etc).
used_registers()
won't return all accessed registers.
#[must_use]pub fn encoding(&self) -> EncodingKind
[src]
Instruction encoding, eg. Legacy, 3DNow!, VEX, EVEX, XOP
#[must_use]pub fn cpuid_features(&self) -> &'static [CpuidFeature]
[src]
Gets the CPU or CPUID feature flags
#[must_use]pub fn flow_control(&self) -> FlowControl
[src]
Control flow info
#[must_use]pub fn op0_access(&self) -> OpAccess
[src]
Operand #0 access
#[must_use]pub fn op1_access(&self) -> OpAccess
[src]
Operand #1 access
#[must_use]pub fn op2_access(&self) -> OpAccess
[src]
Operand #2 access
#[must_use]pub fn op3_access(&self) -> OpAccess
[src]
Operand #3 access
#[must_use]pub fn op4_access(&self) -> OpAccess
[src]
Operand #4 access
#[must_use]pub fn op_access(&self, operand: u32) -> OpAccess
[src]
#[must_use]pub fn rflags_read(&self) -> u32
[src]
All flags that are read by the CPU when executing the instruction.
This method returns a RflagsBits
value. See also rflags_modified()
.
#[must_use]pub fn rflags_written(&self) -> u32
[src]
All flags that are written by the CPU, except those flags that are known to be undefined, always set or always cleared.
This method returns a RflagsBits
value. See also rflags_modified()
.
#[must_use]pub fn rflags_cleared(&self) -> u32
[src]
All flags that are always cleared by the CPU.
This method returns a RflagsBits
value. See also rflags_modified()
.
#[must_use]pub fn rflags_set(&self) -> u32
[src]
All flags that are always set by the CPU.
This method returns a RflagsBits
value. See also rflags_modified()
.
#[must_use]pub fn rflags_undefined(&self) -> u32
[src]
All flags that are undefined after executing the instruction.
This method returns a RflagsBits
value. See also rflags_modified()
.
#[must_use]pub fn rflags_modified(&self) -> u32
[src]
All flags that are modified by the CPU. This is rflags_written() + rflags_cleared() + rflags_set() + rflags_undefined()
. This method returns a RflagsBits
value.
Trait Implementations
impl Clone for InstructionInfo
[src]
pub fn clone(&self) -> InstructionInfo
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Debug for InstructionInfo
[src]
Auto Trait Implementations
impl RefUnwindSafe for InstructionInfo
impl Send for InstructionInfo
impl Sync for InstructionInfo
impl Unpin for InstructionInfo
impl UnwindSafe for InstructionInfo
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,