Struct wasmer_types::VMOffsets

source ·
pub struct VMOffsets { /* private fields */ }
Expand description

This class computes offsets to fields within VMContext and other related structs that JIT code accesses directly.

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.

Number of local tables defined in the module

Number of local memories defined in the module

Offsets for VMFunctionImport.

The offset of the body field.

The offset of the vmctx field.

The offset of the handle field.

Return the size of 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.

The offset of the definition field.

The offset of the handle field.

Return the size of 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.

The offset of the from field.

The offset of the handle field.

Return the size of 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 handle 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 VMSharedSignatureIndex.

Return the size of VMSharedSignatureIndex.

Offsets for VMCallerCheckedAnyfunc.

The offset of the func_ptr field.

The offset of the type_index field.

The offset of the vmctx field.

The offset of the call_trampoline 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. Remember updating precompute upon changes

Return the offset to the vmctx field in *const VMFunctionBody index index. Remember updating precompute upon changes

Return the offset to the definition field in VMTableImport index index. Remember updating precompute upon changes

Return the offset to the base field in VMTableDefinition index index. Remember updating precompute upon changes

Return the offset to the current_elements field in VMTableDefinition index index. Remember updating precompute upon changes

Return the offset to the from field in VMMemoryImport index index. Remember updating precompute upon changes

Return the offset to the vmctx field in VMMemoryImport index index. Remember updating precompute upon changes

Return the offset to the base field in VMMemoryDefinition index index. Remember updating precompute upon changes

Return the offset to the current_length field in VMMemoryDefinition index index. Remember updating precompute upon changes

Return the offset to the from field in VMGlobalImport index index. Remember updating precompute upon changes

Return the offset to builtin function in VMBuiltinFunctionsArray index index. Remember updating precompute upon changes

Trait Implementations§

Returns a copy of the value. Read more
Performs copy-assignment from source. Read more
Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
The archived version of the pointer metadata for this type.
Converts some archived metadata to the pointer metadata for itself.
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more
Deserializes using the given deserializer

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type for metadata in pointers and references to Self.
The resulting type after obtaining ownership.
Creates owned data from borrowed data, usually by cloning. Read more
Uses borrowed data to replace owned data, usually by cloning. Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.