From 73bfa49dde1a51e0f786b1337d9125ccf0e69c81 Mon Sep 17 00:00:00 2001 From: vms Date: Wed, 29 Dec 2021 20:05:33 +0300 Subject: [PATCH] print memory.grow --- lib/runtime-core/src/vmcalls.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/runtime-core/src/vmcalls.rs b/lib/runtime-core/src/vmcalls.rs index 3f378300d..b77c08f61 100644 --- a/lib/runtime-core/src/vmcalls.rs +++ b/lib/runtime-core/src/vmcalls.rs @@ -37,6 +37,8 @@ pub unsafe extern "C" fn local_static_memory_grow( Err(_) => -1, }; + println!("local static memory grow: delta {:?}, ret {}", delta, ret); + ctx.internal.memory_base = (*local_memory).base; ctx.internal.memory_bound = (*local_memory).bound; @@ -82,6 +84,8 @@ pub unsafe extern "C" fn local_dynamic_memory_grow( Err(_) => -1, }; + println!("local dynamic memory grow: delta {:?}, ret {}", delta, ret); + ctx.internal.memory_base = (*local_memory).base; ctx.internal.memory_bound = (*local_memory).bound;