pub struct RegisterInterfaceMap {
pub inputs: Vec<VarnodeId>,
pub outputs: Vec<VarnodeId>,
pub returns: usize,
pub projections: Vec<DerivedOutput>,
}Expand description
The ordered, machine-readable register interface of a materialized
function: which register each by-value input parameter binds, and which
register each return-pack slot stores back. Slot i of inputs is the
i-th register param; slot i of outputs is the i-th pack field.
Both the register channel’s own rewrite (regpure calls) and the emulator’s
implicit (zero-arg) convention read this: implicitly, param i is seeded
from inputs[i] at entry and pack slot i is stored back to outputs[i]
on return.
A third category sits alongside those two: a register that is neither an
input nor packed, because it is derived — see
projections.
Fields§
§inputs: Vec<VarnodeId>Register bound by each by-value input parameter, in parameter order.
outputs: Vec<VarnodeId>Register written back by each return-pack slot, in pack order. Ordered
returns-first: slots ..returns carry real computed values, the rest
are clobbers (undefined — poison — at a rewritten call site).
returns: usizeHow many leading outputs slots are return values (the rest are
clobbers). A bodied function replays every slot as a real store, so its
returns == outputs.len(); a prototyped external returns only its ABI
return register(s) and clobbers the caller-saved tail.
projections: Vec<DerivedOutput>Registers whose returned value is computed by a linked projection rather
than carried in the pack (see DerivedOutput). Unordered and disjoint
from outputs; a consumer that needs such a register’s value evaluates
its projection instead of reading a pack field.
#[serde(default)] (→ empty) covers self-describing formats only. A
.harbinger session payload is positional bincode under a hard version
lock with no migration path, so adding this field changed the payload
layout and required a harbinger_session::session::FORMAT_VERSION bump —
old sessions are rejected, not defaulted.
Trait Implementations§
Source§impl Clone for RegisterInterfaceMap
impl Clone for RegisterInterfaceMap
Source§fn clone(&self) -> RegisterInterfaceMap
fn clone(&self) -> RegisterInterfaceMap
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more