diff --git a/lib/dynasm-backend/src/codegen_x64.rs b/lib/dynasm-backend/src/codegen_x64.rs index ef056a695..30b5ea2bc 100644 --- a/lib/dynasm-backend/src/codegen_x64.rs +++ b/lib/dynasm-backend/src/codegen_x64.rs @@ -18,6 +18,7 @@ use wasmer_runtime_core::{ memory::MemoryType, module::{ModuleInfo, ModuleInner}, structures::{Map, TypedIndex}, + typed_func::Wasm, types::{ FuncIndex, FuncSig, ImportedMemoryIndex, LocalFuncIndex, LocalGlobalIndex, LocalMemoryIndex, LocalOrImport, MemoryIndex, SigIndex, Type, Value, @@ -459,6 +460,10 @@ impl ProtectedCaller for X64ExecutionContext { }) } + fn get_wasm_trampoline(&self, _module: &ModuleInner, _sig_index: SigIndex) -> Option { + unimplemented!() + } + fn get_early_trapper(&self) -> Box { pub struct Trapper; diff --git a/lib/emscripten/src/varargs.rs b/lib/emscripten/src/varargs.rs index cd9073cb9..3775d102c 100644 --- a/lib/emscripten/src/varargs.rs +++ b/lib/emscripten/src/varargs.rs @@ -20,4 +20,11 @@ impl VarArgs { unsafe impl WasmExternType for VarArgs { const TYPE: Type = Type::I32; + + fn to_bits(self) -> u64 { + self.pointer as u64 + } + fn from_bits(n: u64) -> Self { + Self { pointer: n as u32 } + } } diff --git a/lib/wasi/src/ptr.rs b/lib/wasi/src/ptr.rs index 56abb3b2d..da892d1bf 100644 --- a/lib/wasi/src/ptr.rs +++ b/lib/wasi/src/ptr.rs @@ -72,6 +72,16 @@ impl WasmPtr { unsafe impl WasmExternType for WasmPtr { const TYPE: Type = Type::I32; + + fn to_bits(self) -> u64 { + self.offset as u64 + } + fn from_bits(n: u64) -> Self { + Self { + offset: n as u32, + _phantom: PhantomData, + } + } } unsafe impl ValueType for WasmPtr {}