Struct wasmer_vm::VMOffsets [−][src]
pub struct VMOffsets { pub pointer_size: u8, pub num_signature_ids: u32, pub num_imported_functions: u32, pub num_imported_tables: u32, pub num_imported_memories: u32, pub num_imported_globals: u32, pub num_local_tables: u32, pub num_local_memories: u32, pub num_local_globals: u32, }
Expand description
This class computes offsets to fields within VMContext
and other
related structs that JIT code accesses directly.
Fields
pointer_size: u8
The size in bytes of a pointer on the target.
num_signature_ids: u32
The number of signature declarations in the module.
num_imported_functions: u32
The number of imported functions in the module.
num_imported_tables: u32
The number of imported tables in the module.
num_imported_memories: u32
The number of imported memories in the module.
num_imported_globals: u32
The number of imported globals in the module.
num_local_tables: u32
The number of defined tables in the module.
num_local_memories: u32
The number of defined memories in the module.
num_local_globals: u32
The number of defined globals in the module.
Implementations
Return a new VMOffsets
instance, for a given pointer size.
Return a new VMOffsets
instance, for a given pointer size
skipping the ModuleInfo
.
Note: This should only when generating code for trampolines.
Offsets for VMFunctionImport
.
Offsets for VMDynamicFunctionContext
.
The offset of the address
field.
The offset of the ctx
field.
Return the size of VMDynamicFunctionContext
.
Offsets for *const VMFunctionBody
.
The size of the current_elements
field.
Offsets for VMTableImport
.
Offsets for VMTableDefinition
.
The offset of the base
field.
The offset of the current_elements
field.
The size of the current_elements
field.
Return the size of VMTableDefinition
.
Offsets for VMMemoryImport
.
Offsets for VMMemoryDefinition
.
The offset of the base
field.
The offset of the current_length
field.
The size of the current_length
field.
Return the size of VMMemoryDefinition
.
Offsets for VMGlobalImport
.
The offset of the definition
field.
The offset of the from
field.
Return the size of VMGlobalImport
.
Offsets for a non-null pointer to a VMGlobalDefinition
used as a local global.
Return the size of a pointer to a VMGlobalDefinition
;
The underlying global itself is the size of the largest value type (i.e. a V128), however the size of this type is just the size of a pointer.
Offsets for VMCallerCheckedAnyfunc
.
The offset of the func_ptr
field.
The offset of the type_index
field.
The offset of the vmctx
field.
Return the size of VMCallerCheckedAnyfunc
.
Offsets for VMFuncRef
.
The offset to the pointer to the anyfunc inside the ref.
Return the size of VMFuncRef
.
Offsets for VMContext
.
The offset of the signature_ids
array.
The offset of the tables
array.
The offset of the tables
array.
The offset of the memories
array.
The offset of the globals
array.
The offset of the tables
array.
The offset of the memories
array.
The offset of the globals
array.
The offset of the builtin functions array.
Return the size of the VMContext
allocation.
Return the offset to VMSharedSignatureIndex
index index
.
Return the offset to VMFunctionImport
index index
.
Return the offset to VMTableImport
index index
.
Return the offset to VMMemoryImport
index index
.
Return the offset to VMGlobalImport
index index
.
Return the offset to VMTableDefinition
index index
.
Return the offset to VMMemoryDefinition
index index
.
Return the offset to the VMGlobalDefinition
index index
.
Return the offset to the body
field in *const VMFunctionBody
index index
.
Return the offset to the vmctx
field in *const VMFunctionBody
index index
.
Return the offset to the definition
field in VMTableImport
index index
.
Return the offset to the base
field in VMTableDefinition
index index
.
Return the offset to the current_elements
field in VMTableDefinition
index index
.
Return the offset to the from
field in VMMemoryImport
index index
.
Return the offset to the vmctx
field in VMMemoryImport
index index
.
Return the offset to the base
field in VMMemoryDefinition
index index
.
Return the offset to the current_length
field in VMMemoryDefinition
index index
.
Return the offset to the from
field in VMGlobalImport
index index
.
Return the offset to builtin function in VMBuiltinFunctionsArray
index index
.
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for VMOffsets
impl UnwindSafe for VMOffsets
Blanket Implementations
type ArchivedMetadata = ()
type ArchivedMetadata = ()
The archived version of the pointer metadata for this type.
pub fn pointer_metadata(
&<T as ArchivePointee>::ArchivedMetadata
) -> <T as Pointee>::Metadata
pub fn pointer_metadata(
&<T as ArchivePointee>::ArchivedMetadata
) -> <T as Pointee>::Metadata
Converts some archived metadata to the pointer metadata for itself.
Mutably borrows from an owned value. Read more