Skip to main content

CallGraph

Struct CallGraph 

Source
pub struct CallGraph {
Show 14 fields pub entry: u64, pub direct_calls: BTreeMap<u64, u32>, pub call_sites: Vec<CallSite>, pub tail_calls: BTreeSet<u64>, pub indirect_calls: u32, pub indirect_jumps: u32, pub vcall_slots: BTreeSet<u64>, pub iat_calls: BTreeSet<u64>, pub field_offsets: BTreeSet<u64>, pub globals: BTreeSet<u64>, pub imm_addrs: BTreeSet<u64>, pub max_end: u64, pub decode_errors: u32, pub decode_error_samples: Vec<(u64, Vec<u8>)>,
}

Fields§

§entry: u64§direct_calls: BTreeMap<u64, u32>

Direct CALL targets → number of call sites hitting that target.

§call_sites: Vec<CallSite>

Per-call-site recovered argument shapes (one entry per direct CALL instruction).

§tail_calls: BTreeSet<u64>

Direct JMP rel targets that leave the walked body (tail calls).

§indirect_calls: u32§indirect_jumps: u32§vcall_slots: BTreeSet<u64>

vtable slot displacements seen in CALL/JMP [reg+0xNN].

§iat_calls: BTreeSet<u64>

IAT import slot addresses seen in CALL [0x00a28xxx].

§field_offsets: BTreeSet<u64>

Struct-field displacements off a non-stack base register.

§globals: BTreeSet<u64>

Absolute data addresses referenced as memory operands (globals).

§imm_addrs: BTreeSet<u64>

In-image immediate values (vtable VAs, fn pointers, string addresses).

§max_end: u64

Highest instruction-end VA reached — the function’s apparent extent.

§decode_errors: u32§decode_error_samples: Vec<(u64, Vec<u8>)>

First few decode failures as (ip, raw_bytes). Decoders hitting invalid opcodes is normal at padding/alignment/data boundaries, but a long run inside what is supposed to be a function usually means the entry VA is wrong, or the function crosses into embedded data. The hex bytes here are enough to tell which.

Implementations§

Source§

impl CallGraph

Source

pub fn call_targets(&self) -> BTreeSet<u64>

Source

pub fn footprint(&self) -> BTreeSet<u64>

Every in-image address this function references — call targets, tail-call JMPs, IAT slots, global data refs and baked immediates (vtable VAs / fn pointers / string addresses). Used to detect inlining: if callee C’s whole footprint also appears in caller F’s footprint, the binary pasted C’s body into F, so a Rust call F→C is faithful (un-inlined), not hallucinated.

Trait Implementations§

Source§

impl Debug for CallGraph

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for CallGraph

Source§

fn default() -> Self

Returns the “default value” for a type. Read more

Auto Trait Implementations§

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>,

Source§

type Error = !

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

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

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

Source§

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.