Struct frida_gum::CpuContext

source ·
pub struct CpuContext<'a> { /* private fields */ }
Expand description

Platform-dependent access to processor state.

Implementations§

source§

impl<'a> CpuContext<'a>

source

pub fn arg(&self, n: u32) -> usize

Get a numbered argument from the processor context, determined by the platform calling convention.

source

pub fn set_arg(&mut self, n: u32, value: usize)

Set a numbered argument in the processor context, determined by the platform calling convention.

source

pub fn return_value(&self) -> usize

Get the value of the register used for the platform calling convention’s return value.

source

pub fn set_return_value(&mut self, value: usize)

Set the value of the register used for the platform calling convention’s return value.

source

pub fn rip(&self) -> u64

source

pub fn set_rip(&mut self, rip: u64)

source

pub fn r15(&self) -> u64

source

pub fn set_r15(&mut self, r15: u64)

source

pub fn r14(&self) -> u64

source

pub fn set_r14(&mut self, r14: u64)

source

pub fn r13(&self) -> u64

source

pub fn set_r13(&mut self, r13: u64)

source

pub fn r12(&self) -> u64

source

pub fn set_r12(&mut self, r12: u64)

source

pub fn r11(&self) -> u64

source

pub fn set_r11(&mut self, r11: u64)

source

pub fn r10(&self) -> u64

source

pub fn set_r10(&mut self, r10: u64)

source

pub fn r9(&self) -> u64

source

pub fn set_r9(&mut self, r9: u64)

source

pub fn r8(&self) -> u64

source

pub fn set_r8(&mut self, r8: u64)

source

pub fn rdi(&self) -> u64

source

pub fn set_rdi(&mut self, rdi: u64)

source

pub fn rsi(&self) -> u64

source

pub fn set_rsi(&mut self, rsi: u64)

source

pub fn rbp(&self) -> u64

source

pub fn set_rbp(&mut self, rbp: u64)

source

pub fn rsp(&self) -> u64

source

pub fn set_rsp(&mut self, rsp: u64)

source

pub fn rbx(&self) -> u64

source

pub fn set_rbx(&mut self, rbx: u64)

source

pub fn rdx(&self) -> u64

source

pub fn set_rdx(&mut self, rdx: u64)

source

pub fn rcx(&self) -> u64

source

pub fn set_rcx(&mut self, rcx: u64)

source

pub fn rax(&self) -> u64

source

pub fn set_rax(&mut self, rax: u64)

Auto Trait Implementations§

§

impl<'a> Freeze for CpuContext<'a>

§

impl<'a> RefUnwindSafe for CpuContext<'a>

§

impl<'a> !Send for CpuContext<'a>

§

impl<'a> !Sync for CpuContext<'a>

§

impl<'a> Unpin for CpuContext<'a>

§

impl<'a> UnwindSafe for CpuContext<'a>

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.