Struct wasmer::Artifact

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

A compiled wasm module, ready to be instantiated.

Implementations§

Compile a data buffer into a ArtifactBuild, which may then be instantiated.

Deserialize a ArtifactBuild

Safety

This function is unsafe because rkyv reads directly without validating the data.

Construct a ArtifactBuild from component parts.

Check if the provided bytes look like a serialized ArtifactBuild.

Register thie Artifact stack frame information into the global scope.

This is required to ensure that any traps can be properly symbolicated.

Returns the functions allocated in memory or this Artifact ready to be run.

Returns the function call trampolines allocated in memory of this Artifact, ready to be run.

Returns the dynamic function trampolines allocated in memory of this Artifact, ready to be run.

Returns the associated VM signatures for this Artifact.

Do preinstantiation logic that is executed before instantiating

Crate an Instance from this Artifact.

Safety

See InstanceHandle::new.

Finishes the instantiation of a just created InstanceHandle.

Safety

See InstanceHandle::finish_instantiation.

Compile a module into an object file, which can be statically linked against.

The prefixer returns the a String to prefix each of the functions in the static object generated by the so we can assure no collisions.

Deserialize a ArtifactBuild from an object file

Safety

The object must be a valid static object generated by wasmer.

Trait Implementations§

Create a ModuleInfo for instantiation
Returns the features for this Artifact
Returns the CPU features for this Artifact
Returns data initializers to pass to InstanceHandle::initialize
Returns the memory styles associated with this Artifact.
Returns the table plans associated with this Artifact.
Serializes an artifact into bytes
Serializes an artifact into a file path

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.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Calls U::from(self).

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

The alignment of pointer.
The type for initializers.
Initializes a with the given initializer. Read more
Dereferences the given pointer. Read more
Mutably dereferences the given pointer. Read more
Drops the object pointed to by the given pointer. Read more
The type for metadata in pointers and references to Self.
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.
upcast ref
upcast mut ref
upcast boxed dyn
Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more