mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-27 22:09:09 +00:00
wasm_interp: Make ValueStack a dumb Vec<Value> => Zig test 146.3->124.6ms
This commit is contained in:
parent
1f90286d64
commit
8c7d9dbff8
5 changed files with 156 additions and 304 deletions
|
@ -94,23 +94,26 @@ fn main() -> io::Result<()> {
|
|||
});
|
||||
|
||||
// Run
|
||||
// let end= 10000;
|
||||
let end = 1;
|
||||
for _ in 0..end {
|
||||
let result = inst.call_export_from_cli(&module, start_fn_name, &wasi_argv);
|
||||
|
||||
let result = inst.call_export_from_cli(&module, start_fn_name, &wasi_argv);
|
||||
// Print out return value, if any
|
||||
|
||||
// Print out return value, if any
|
||||
|
||||
match result {
|
||||
Ok(Some(val)) => {
|
||||
if is_hex_format {
|
||||
println!("{:#x?}", val)
|
||||
} else {
|
||||
println!("{:?}", val)
|
||||
match result {
|
||||
Ok(Some(val)) => {
|
||||
if is_hex_format {
|
||||
println!("{:#x?}", val)
|
||||
} else {
|
||||
println!("{:?}", val)
|
||||
}
|
||||
}
|
||||
Ok(None) => {}
|
||||
Err(e) => {
|
||||
eprintln!("{}", e);
|
||||
process::exit(3);
|
||||
}
|
||||
}
|
||||
Ok(None) => {}
|
||||
Err(e) => {
|
||||
eprintln!("{}", e);
|
||||
process::exit(3);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue