summaryrefslogtreecommitdiff
path: root/benches/selfhosted.rs
diff options
context:
space:
mode:
authorHenry Gressmann <mail@henrygressmann.de>2024-01-29 20:39:31 +0100
committerHenry Gressmann <mail@henrygressmann.de>2024-01-29 20:39:31 +0100
commitf8651619e576ac97209b72660144568b54eb965c (patch)
tree6bbf232f2b7444d02ef6cb2192759f628ce2ab8f /benches/selfhosted.rs
parent4c9385df1bcc0098c7e1db7a2f7c7e3dbeb00c8b (diff)
feat: pre-processed wasm
Signed-off-by: Henry Gressmann <mail@henrygressmann.de>
Diffstat (limited to 'benches/selfhosted.rs')
-rw-r--r--benches/selfhosted.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/benches/selfhosted.rs b/benches/selfhosted.rs
index f78d958..b9df1af 100644
--- a/benches/selfhosted.rs
+++ b/benches/selfhosted.rs
@@ -10,7 +10,7 @@ fn run_tinywasm(module: TinyWasmModule) {
let mut imports = Imports::default();
imports.define("env", "printi32", Extern::typed_func(|_: FuncContext<'_>, _: i32| Ok(()))).expect("define");
let instance = ModuleInstance::instantiate(&mut store, module, Some(imports)).expect("instantiate");
- let hello = instance.exported_func::<(), ()>(&mut store, "hello").expect("exported_func");
+ let hello = instance.exported_func::<(), ()>(&store, "hello").expect("exported_func");
hello.call(&mut store, ()).expect("call");
}
@@ -32,7 +32,7 @@ fn criterion_benchmark(c: &mut Criterion) {
let mut group = c.benchmark_group("selfhosted");
group.bench_function("tinywasm", |b| b.iter(|| run_tinywasm(module.clone())));
- group.bench_function("wasmi", |b| b.iter(|| run_wasmi()));
+ group.bench_function("wasmi", |b| b.iter(run_wasmi));
}
criterion_group!(