pub struct DecodedModule {
pub functions: Vec<FunctionOps>,
pub memories: Vec<WasmMemory>,
pub data_segments: Vec<(u32, Vec<u8>)>,
pub imports: Vec<ImportEntry>,
pub num_imported_funcs: u32,
pub func_arg_counts: Vec<u32>,
pub type_arg_counts: Vec<u32>,
}Expand description
Decoded WASM module with functions and memory
Fields§
§functions: Vec<FunctionOps>Decoded functions
memories: Vec<WasmMemory>Linear memories
data_segments: Vec<(u32, Vec<u8>)>Data segments (offset, data) for memory initialization
imports: Vec<ImportEntry>Import entries (module name, field name, kind)
num_imported_funcs: u32Number of imported functions (for distinguishing import calls from local calls)
func_arg_counts: Vec<u32>AAPCS integer-argument count per function, indexed by the full WASM
function index (imported functions first, then locally-defined ones).
Used by the backend to marshal call arguments into R0–R3 (issue #195).
Counts every parameter as one slot (i64/f64 over-counted — see the
backend’s set_func_arg_counts scope note).
type_arg_counts: Vec<u32>AAPCS integer-argument count per function type, indexed by type index.
Used by call_indirect, whose callee arg count comes from the static
type index (issue #195).
Trait Implementations§
Source§impl Clone for DecodedModule
impl Clone for DecodedModule
Source§fn clone(&self) -> DecodedModule
fn clone(&self) -> DecodedModule
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for DecodedModule
impl RefUnwindSafe for DecodedModule
impl Send for DecodedModule
impl Sync for DecodedModule
impl Unpin for DecodedModule
impl UnsafeUnpin for DecodedModule
impl UnwindSafe for DecodedModule
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more