mirror of
https://github.com/fluencelabs/wasmer
synced 2025-06-24 22:21:32 +00:00
Improved syntax
This commit is contained in:
@ -7,10 +7,7 @@ mod tests {
|
||||
use wasmer_runtime_core::codegen::{MiddlewareChain, StreamingCompiler};
|
||||
use wasmer_runtime_core::fault::{pop_code_version, push_code_version};
|
||||
use wasmer_runtime_core::state::CodeVersion;
|
||||
use wasmer_runtime_core::{
|
||||
backend::Compiler,
|
||||
compile_with, imports, Func,
|
||||
};
|
||||
use wasmer_runtime_core::{backend::Compiler, compile_with, imports, Func};
|
||||
|
||||
#[cfg(feature = "llvm")]
|
||||
fn get_compiler(limit: u64) -> impl Compiler {
|
||||
|
@ -2,10 +2,7 @@
|
||||
//! serializing compiled wasm code to a binary format. The binary format can be persisted,
|
||||
//! and loaded to allow skipping compilation and fast startup.
|
||||
|
||||
use crate::{
|
||||
module::ModuleInfo,
|
||||
sys::Memory,
|
||||
};
|
||||
use crate::{module::ModuleInfo, sys::Memory};
|
||||
use blake2b_simd::blake2bp;
|
||||
use std::{io, mem, slice};
|
||||
|
||||
|
@ -240,12 +240,7 @@ impl<
|
||||
_ => MCG::new(),
|
||||
};
|
||||
let mut chain = (self.middleware_chain_generator)();
|
||||
let info = crate::parse::read_module(
|
||||
wasm,
|
||||
&mut mcg,
|
||||
&mut chain,
|
||||
&compiler_config,
|
||||
)?;
|
||||
let info = crate::parse::read_module(wasm, &mut mcg, &mut chain, &compiler_config)?;
|
||||
let (exec_context, cache_gen) =
|
||||
mcg.finalize(&info.read().unwrap())
|
||||
.map_err(|x| CompileError::InternalError {
|
||||
|
@ -11,11 +11,9 @@ use std::{
|
||||
path::PathBuf,
|
||||
};
|
||||
|
||||
use wasmer_runtime_core::cache::Error as CacheError;
|
||||
pub use wasmer_runtime_core::{
|
||||
cache::{Artifact, WasmHash},
|
||||
};
|
||||
pub use super::Backend;
|
||||
use wasmer_runtime_core::cache::Error as CacheError;
|
||||
pub use wasmer_runtime_core::cache::{Artifact, WasmHash};
|
||||
|
||||
/// A generic cache for storing and loading compiled wasm modules.
|
||||
///
|
||||
|
Reference in New Issue
Block a user