mirror of
https://github.com/fluencelabs/wasmer
synced 2025-06-24 14:11:32 +00:00
Fix more spectests
This commit is contained in:
@ -648,10 +648,10 @@ impl<'environment> FuncEnvironmentTrait for FuncEnvironment<'environment> {
|
||||
call_conv: self.module.config.default_call_conv,
|
||||
// Paramters types.
|
||||
params: vec![
|
||||
// Param for new size.
|
||||
AbiParam::new(I32),
|
||||
// Param for memory index.
|
||||
AbiParam::new(I32),
|
||||
// Param for new size.
|
||||
AbiParam::new(I32),
|
||||
// Param for VMcontext.
|
||||
AbiParam::special(self.pointer_type(), ArgumentPurpose::VMContext),
|
||||
],
|
||||
@ -677,7 +677,7 @@ impl<'environment> FuncEnvironmentTrait for FuncEnvironment<'environment> {
|
||||
.expect("missing vmctx parameter");
|
||||
|
||||
// Insert call instructions for `grow_memory`.
|
||||
let call_inst = pos.ins().call(grow_mem_func, &[val, memory_index, vmctx]);
|
||||
let call_inst = pos.ins().call(grow_mem_func, &[memory_index, val, vmctx]);
|
||||
|
||||
// Return value.
|
||||
Ok(*pos.func.dfg.inst_results(call_inst).first().unwrap())
|
||||
@ -721,13 +721,13 @@ impl<'environment> FuncEnvironmentTrait for FuncEnvironment<'environment> {
|
||||
});
|
||||
|
||||
// Create a memory index value.
|
||||
let memory_index_value = pos.ins().iconst(I32, to_imm64(index.index()));
|
||||
let memory_index = pos.ins().iconst(I32, to_imm64(index.index()));
|
||||
|
||||
// Create a VMContext value.
|
||||
let vmctx = pos.func.special_param(ArgumentPurpose::VMContext).unwrap();
|
||||
|
||||
// Insert call instructions for `current_memory`.
|
||||
let call_inst = pos.ins().call(cur_mem_func, &[memory_index_value, vmctx]);
|
||||
let call_inst = pos.ins().call(cur_mem_func, &[memory_index, vmctx]);
|
||||
|
||||
// Return value.
|
||||
Ok(*pos.func.dfg.inst_results(call_inst).first().unwrap())
|
||||
|
@ -36,7 +36,7 @@ const TESTS: &[&str] = &[
|
||||
"spectests/f64_bitwise.wast",
|
||||
"spectests/f64_cmp.wast",
|
||||
"spectests/fac.wast",
|
||||
// "spectests/float_exprs.wast",
|
||||
"spectests/float_exprs.wast",
|
||||
"spectests/float_literals.wast",
|
||||
"spectests/float_memory.wast",
|
||||
"spectests/float_misc.wast",
|
||||
|
@ -53,7 +53,7 @@ impl LinearMemory {
|
||||
debug!("Instantiate LinearMemory(mem: {:?})", mem);
|
||||
|
||||
let (mmap_size, initial_pages, offset_guard_size, requires_signal_catch) =
|
||||
if mem.is_static_heap() {
|
||||
if /*mem.is_static_heap()*/ true {
|
||||
(Self::DEFAULT_SIZE, mem.min, Self::DEFAULT_GUARD_SIZE, true)
|
||||
// This is a static heap
|
||||
} else {
|
||||
@ -170,8 +170,8 @@ impl LinearMemory {
|
||||
}
|
||||
|
||||
pub(crate) fn grow_static(&mut self, add_pages: u32) -> Option<i32> {
|
||||
debug!("grow_memory_static called!");
|
||||
assert!(self.max.is_some());
|
||||
// debug!("grow_memory_static called!");
|
||||
// assert!(self.max.is_some());
|
||||
if add_pages == 0 {
|
||||
return Some(self.current as _);
|
||||
}
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -36,6 +36,8 @@ mod f64_bitwise;
|
||||
#[cfg(not(feature = "fast-tests"))]
|
||||
mod f64_cmp;
|
||||
mod fac;
|
||||
#[cfg(not(feature = "fast-tests"))]
|
||||
mod float_exprs;
|
||||
mod float_literals;
|
||||
mod float_memory;
|
||||
#[cfg(not(feature = "fast-tests"))]
|
||||
|
Reference in New Issue
Block a user