Skip to content

Commit

Permalink
Expose additional wasmtime configs. (#63)
Browse files Browse the repository at this point in the history
  • Loading branch information
Daniel9z authored Dec 12, 2024
1 parent 780eeba commit 7ad1984
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions include/wasmtime.hh
Original file line number Diff line number Diff line change
Expand Up @@ -346,6 +346,27 @@ public:
wasmtime_config_wasm_multi_value_set(ptr.get(), enable);
}

/// \brief Configures whether the WebAssembly Garbage Collection proposal will be enabled
///
/// https://docs.wasmtime.dev/api/wasmtime/struct.Config.html#method.wasm_gc
void wasm_gc(bool enable) {
wasmtime_config_wasm_gc_set(ptr.get(), enable);
}

/// \brief Configures whether the WebAssembly function references proposal will be enabled
///
/// https://docs.wasmtime.dev/api/wasmtime/struct.Config.html#method.wasm_function_references
void wasm_function_references(bool enable) {
wasmtime_config_wasm_function_references_set(ptr.get(), enable);
}

/// \brief Configure whether wasmtime should compile a module using multiple threads.
///
/// https://docs.wasmtime.dev/api/wasmtime/struct.Config.html#method.parallel_compilation
void parallel_compilation(bool enable) {
wasmtime_config_parallel_compilation_set(ptr.get(), enable);
}

/// \brief Configures compilation strategy for wasm code.
///
/// https://docs.wasmtime.dev/api/wasmtime/struct.Config.html#method.strategy
Expand Down

0 comments on commit 7ad1984

Please sign in to comment.