pub trait FrameWalker {
    // Required methods
    fn get_instruction(&self) -> u64;
    fn has_grand_callee(&self) -> bool;
    fn get_grand_callee_parameter_size(&self) -> u32;
    fn get_register_at_address(&self, address: u64) -> Option<u64>;
    fn get_callee_register(&self, name: &str) -> Option<u64>;
    fn set_caller_register(&mut self, name: &str, val: u64) -> Option<()>;
    fn clear_caller_register(&mut self, name: &str);
    fn set_cfa(&mut self, val: u64) -> Option<()>;
    fn set_ra(&mut self, val: u64) -> Option<()>;
}

Required Methods§

source

fn get_instruction(&self) -> u64

Get the instruction address that we’re trying to unwind from.

source

fn has_grand_callee(&self) -> bool

Check whether the callee has a callee of its own.

source

fn get_grand_callee_parameter_size(&self) -> u32

Get the number of bytes the callee’s callee’s parameters take up on the stack (or 0 if unknown/invalid). This is needed for STACK WIN unwinding.

source

fn get_register_at_address(&self, address: u64) -> Option<u64>

Get a register-sized value stored at this address.

source

fn get_callee_register(&self, name: &str) -> Option<u64>

Get the value of a register from the callee’s frame.

source

fn set_caller_register(&mut self, name: &str, val: u64) -> Option<()>

Set the value of a register for the caller’s frame.

source

fn clear_caller_register(&mut self, name: &str)

Explicitly mark one of the caller’s registers as invalid.

source

fn set_cfa(&mut self, val: u64) -> Option<()>

Set whatever registers in the caller should be set based on the cfa (e.g. rsp).

source

fn set_ra(&mut self, val: u64) -> Option<()>

Set whatever registers in the caller should be set based on the return address (e.g. rip).

Implementors§