You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When building with singlepass, wasmer panics when attempting to find information about the native instruction mapping to an unreachable in the wasm.
With cranelift and LLVM:
$ ~/wasmer-reborn/target/debug/wasmer run --cranelift ~/x.wat
error: failed to run `/home/nicholas/x.wat`
╰─> 1: RuntimeError: unreachable
at <unnamed> (x.wat[0]:0x1a)
$ ~/wasmer-reborn/target/debug/wasmer run --llvm ~/x.wat
error: failed to run `/home/nicholas/x.wat`
╰─> 1: RuntimeError: unreachable
at <unnamed> (x.wat[0]:0xffffffff)
With singlepass:
$ ~/wasmer-reborn/target/debug/wasmer run --singlepass ~/x.wat
thread 'main' panicked at 'failed to find instruction for 7f75aa0ae01e', lib/engine/src/trap/frame_info.rs:151:9
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
I've just tested this and it doesn't happen in master with macos.
$ make build-wasmer-debug
$ ./target/debug/wasmer run --singlepass x.wat
error: failed to run `x.wat`
│ 1: RuntimeError: unreachable
╰─> 2: unreachable
1870: Added basic AddressMap support for singlepass r=syrusakbary a=syrusakbary
<!--
Prior to submitting a PR, review the CONTRIBUTING.md document for recommendations on how to test:
https://github.com/wasmerio/wasmer/blob/master/CONTRIBUTING.md#pull-requests
-->
# Description
This PR should fix#1856 and #1523 by adding address maps with the locations related to the traps.
The PR makes the following command to pass (in debug mode):
```
cargo test --features "singlepass" --features "test-singlepass test-jit"
```
<!--
Provide details regarding the change including motivation,
links to related issues, and the context of the PR.
-->
# Review
- [ ] Add a short description of the the change to the CHANGELOG.md file
Co-authored-by: Syrus <[email protected]>
Co-authored-by: Syrus Akbary <[email protected]>
Describe the bug
When building with singlepass, wasmer panics when attempting to find information about the native instruction mapping to an unreachable in the wasm.
With cranelift and LLVM:
With singlepass:
Steps to reproduce
Here's
x.wat
:Run it with singlepass and engine-jit.
Expected behavior
A
RuntimeError
reporting the execution of anunreachable
.Actual behavior
A panic while looking up the trap info.
The text was updated successfully, but these errors were encountered: