Commit Graph

3132 Commits

Author SHA1 Message Date
2e532fa66d Preserve fault.ip when calling middleware. 2019-10-14 20:23:27 +08:00
a525907c60 Emit state information for internal breakpoints. 2019-10-14 20:23:10 +08:00
5611bec3eb Update README.md 2019-10-13 21:52:10 -07:00
b0b0983eb8 Allow accessing execution state in middleware breakpoint handlers. 2019-10-13 20:51:39 +08:00
128b006bf7 Add a BlockTrace middleware. 2019-10-13 20:51:03 +08:00
5499a69ddc Run cargo fmt on everything. 2019-10-13 20:02:47 +08:00
c18bdd52cc Fix inline breakpoints on macOS. 2019-10-13 20:02:28 +08:00
e9f476c93b doc: add link to SO in C api example 2019-10-13 10:30:02 +02:00
36f95fc660 Support emitting inline breakpoints in singlepass. 2019-10-11 21:05:42 +08:00
94f97109ff Include backend metadata in tiering module. 2019-10-11 21:05:17 +08:00
db59127f71 Inline breakpoint support in core. 2019-10-11 21:04:53 +08:00
2e1fb7abca Update call_trace middleware to include a counter. 2019-10-11 21:04:09 +08:00
c3ff8eb540 fix(runtime-c-api) Replace unsafe code by safe code. 2019-10-11 09:26:05 +02:00
01c209fe96 feat(runtime-c-api) Move the wasi module into its own file. 2019-10-11 09:19:46 +02:00
bd8e864656 Add functions import object to get import fns and free them 2019-10-10 16:07:56 -07:00
51f619a132 Change pointer that's not modified to be const in C API 2019-10-10 11:22:45 -07:00
8ee4b7f7b0 Replace brk with undefined instruction. 2019-10-10 22:08:52 +08:00
420bfa570e Merge branch 'master' into deterministic 2019-10-10 15:55:35 +03:00
913354adb3 Add function to get export from ns/name via ImportObject to C API 2019-10-09 17:29:27 -07:00
2695093a03 Merge #863
863: Rewrite Min/Max to handle all cases correctly. Fixes 545 spectest failures. r=nlewycky a=nlewycky

# Description
The llvm backend was not quite following the Wasm spec for {F32,F64,F32x4xF64x2}{Min,Max}. We used the `@llvm.minnum` and `@llvm.maxnum` intrinsics which don't handle the corner cases the same. When we tried to use `@llvm.minimum` and `@llvm.maximum` which do, we get an internal error from the x86 backend. I was hoping that crash would go away with the upgrade to LLVM 9, but it does not.

Reimplement these operations using plain LLVM instructions.

# Review

- [x] Add a short description of the the change to the CHANGELOG.md file


Co-authored-by: Nick Lewycky <nick@wasmer.io>
2019-10-09 22:24:07 +00:00
88f126a00b Merge #870
870: Fix unused value warning due to inkwell API change. NFC. r=nlewycky a=nlewycky

# Description
Fix unused value warning due to inkwell API change. No functionality change.

Co-authored-by: Nick Lewycky <nick@wasmer.io>
2019-10-08 23:56:10 +00:00
c61cbf6c0b Add a comment. 2019-10-08 11:25:10 -07:00
bd06aa02ba x 2019-10-08 19:07:38 +08:00
c337999c5c x 2019-10-08 18:43:39 +08:00
b5bb3fa764 Move {push,pop}_code_version to caller side for non-mananged execution. 2019-10-08 18:41:22 +08:00
afddbb2b2a Remove unused value warning due to inkwell API change. NFC. 2019-10-07 17:16:52 -07:00
8f734c5b04 Merge #869
869: Remove exclusions for tests that appear to be passing right now. r=nlewycky a=nlewycky

# Description
Remove exclusions for tests that appear to be passing right now.

Co-authored-by: Nick Lewycky <nick@wasmer.io>
2019-10-08 00:13:56 +00:00
9cdfb48d0c The i1 argument is actually named "is_zero_undef" which we want to be false.
Fixes the test failures that showed up on mac.
2019-10-07 17:11:59 -07:00
158db4cee1 Remove exclusions for tests that appear to be passing right now. 2019-10-07 15:11:45 -07:00
3489bfb9b9 renamed feature flag deterministic to deterministic-execution 2019-10-07 23:07:20 +03:00
7ce5ec4df9 fixes to PR comments 2019-10-07 22:34:32 +03:00
4d99963640 Replace "be the i32 type" with "be an i32" in error messages. 2019-10-07 12:11:10 -07:00
e0e7d58313 Make state mapping work on non-x86 architectures. 2019-10-07 23:00:37 +08:00
6ca5812798 When deterministic feature will be enabled (turned-off by default) it'll guarantee deterministic
execution of wasm programs across different hardware/circumstances.
This is very useful for Blockchain projects having wasm smart-contracts

This is critical for Blockchain projects that require execution to be deterministic
in order to reach a consensus of the state transition of each smart-contract transaction.
2019-10-07 16:58:58 +03:00
ed615c4878 fix build error docs 2019-10-07 12:56:55 +02:00
80d6c4cbc0 Implement get_fault_info for aarch64. 2019-10-06 18:27:35 +08:00
749691ca2a Add a comment explaining why we don't use the intrinsics for these. 2019-10-04 11:50:11 -07:00
1a7f00f0af Rewrite Min/Max to handle all cases correctly.
Fixes 545 spectest failures.
2019-10-03 18:19:12 -07:00
bfb9d3849c Fix merge 2019-10-03 11:58:06 -07:00
689bdd08a1 Merge branch 'master' into feature/wasi-in-c-api 2019-10-03 11:56:37 -07:00
70b55b801d Check argument pointers for null to WASI calls 2019-10-03 10:50:07 -07:00
4b3880c88b add details when calling unimplemented! 2019-10-03 11:26:54 +02:00
f63c706abc Merge branch 'master' into feature/singlepass-atomicops 2019-10-02 16:46:59 -07:00
ab76c2357f Delete dead (commented out) code. NFC. 2019-10-02 16:31:11 -07:00
8e63d54fdb cargo fmt 2019-10-02 16:31:11 -07:00
83b678bc36 Give this function a better name. 2019-10-02 16:31:11 -07:00
11c5e0d71d Make the panics a bit more descriptive. 2019-10-02 16:31:11 -07:00
ba68cfc2c6 Finish atomic operations for singlepass, excluding wait and notify. 2019-10-02 16:31:11 -07:00
bc7e017188 Add atomic.rmw operations, excluding xchg and cmpxchg.
Sizes are now ordered, to facilitate an assertion that one size is less (smaller) than another.

panic! error messages are provided for remaining emitter functions.
2019-10-02 16:31:11 -07:00
f021d59a0b Refactor out a compare-and-swap loop function. 2019-10-02 16:31:11 -07:00