Struct wasmedge_sdk::config::CommonConfigOptions
source · pub struct CommonConfigOptions { /* private fields */ }
Expand description
Defines the common configuration options.
CommonConfigOptions is used to set the common configuration options, which are
-
ImportExportMutGlobals
supports mutable imported and exported globals.Also see Import/Export Mutable Globals Proposal.
-
NonTrapFloatToIntConversions
supports the non-trapping float-to-int conversion. -
SignExtensionOperators
supports new integer instructions for sign-extending 8-bit, 16-bit, and 32-bit values.Also see Sign-extension Operators Proposal.
-
MultiValue
supports functions and instructions with multiple return values, and blocks with inputs.Also see Multi-value Extension.
-
BulkMemoryOperations
supports bulk memory operations.Also see Bulk Memory Operations Proposal.
-
ReferenceTypes
supports reference types.Also see Reference Types Proposal.
-
SIMD
supports 128-bit packed SIMD extension to WebAssembly.Also see SIMD Proposal.
Implementations§
source§impl CommonConfigOptions
impl CommonConfigOptions
sourcepub fn new() -> Self
pub fn new() -> Self
Creates a new instance of CommonConfigOptions.
The default options are:
- mutable_globals: true,
- non_trap_conversions: true,
- sign_extension_operators: true,
- multi_value: true,
- bulk_memory_operations: true,
- reference_types: true,
- simd: true,
- multi_memories: false,
- threads: false,
- tail_call: false,
- function_references: false,
- interpreter_mode: false,
sourcepub fn mutable_globals(self, enable: bool) -> Self
pub fn mutable_globals(self, enable: bool) -> Self
Enables or disables the ImportExportMutGlobals option.
Argument
enable
specifies if the option turns on or not.
sourcepub fn non_trap_conversions(self, enable: bool) -> Self
pub fn non_trap_conversions(self, enable: bool) -> Self
Enables or disables the NonTrapFloatToIntConversions option.
Argument
enable
specifies if the option turns on or not.
sourcepub fn sign_extension_operators(self, enable: bool) -> Self
pub fn sign_extension_operators(self, enable: bool) -> Self
Enables or disables the SignExtensionOperators option.
Argument
enable
specifies if the option turns on or not.
sourcepub fn multi_value(self, enable: bool) -> Self
pub fn multi_value(self, enable: bool) -> Self
sourcepub fn bulk_memory_operations(self, enable: bool) -> Self
pub fn bulk_memory_operations(self, enable: bool) -> Self
Enables or disables the BulkMemoryOperations option.
Argument
enable
specifies if the option turns on or not.
sourcepub fn reference_types(self, enable: bool) -> Self
pub fn reference_types(self, enable: bool) -> Self
Enables or disables the ReferenceTypes option.
Argument
enable
specifies if the option turns on or not.
sourcepub fn multi_memories(self, enable: bool) -> Self
pub fn multi_memories(self, enable: bool) -> Self
Enables or disables the MultiMemories option.
Argument
enable
specifies if the option turns on or not.
sourcepub fn function_references(self, enable: bool) -> Self
pub fn function_references(self, enable: bool) -> Self
Enables or disables the FunctionReferences option.
Argument
enable
- Whether the option turns on or not.
sourcepub fn interpreter_mode(self, enable: bool) -> Self
pub fn interpreter_mode(self, enable: bool) -> Self
Enables or disables the ForceInterpreter
option.
Argument
enable
- Whether the option turns on or not.
Trait Implementations§
source§impl Clone for CommonConfigOptions
impl Clone for CommonConfigOptions
source§fn clone(&self) -> CommonConfigOptions
fn clone(&self) -> CommonConfigOptions
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for CommonConfigOptions
impl Debug for CommonConfigOptions
source§impl Default for CommonConfigOptions
impl Default for CommonConfigOptions
source§fn default() -> Self
fn default() -> Self
Creates a new default instance of CommonConfigOptions.
The default options are:
- mutable_globals: true,
- non_trap_conversions: true,
- sign_extension_operators: true,
- multi_value: true,
- bulk_memory_operations: true,
- reference_types: true,
- simd: true,
- multi_memories: false,
- threads: false,
- tail_call: false,
- function_references: false,
- interpreter_mode: false,