Commit Graph

2482 Commits

Author SHA1 Message Date
Mark McCaskey
811acd7e68 probably actually fix the wasi ptr array bug now 2019-06-06 16:19:15 -07:00
Mark McCaskey
d7ea46bab7 add wasmptr memory abstraction to emscripten; update wasi array access 2019-06-06 15:45:19 -07:00
bors[bot]
4913cfaff4 Merge #481
481: Added context trampoline into runtime r=losfair a=syrusakbary

Based on #450 

Co-authored-by: losfair <zhy20000919@hotmail.com>
2019-06-05 11:36:54 +00:00
losfair
66dcec91c4 Add comments for trampoline_x64. 2019-06-05 01:59:20 +08:00
losfair
f4df568e41 Naming fixes and documentation for trampoline API. 2019-06-05 01:38:35 +08:00
losfair
f1b27d5774 Cargo fmt 2019-06-05 01:26:35 +08:00
losfair
669f76025c Add callinfo trampoline into the C API. 2019-06-05 01:25:37 +08:00
losfair
b2869e181c Cargo fmt 2019-06-05 01:11:54 +08:00
losfair
8a74399c6e Add callinfo trampoline support. 2019-06-05 01:11:10 +08:00
losfair
06280e225e Fix unused_imports error on lazy_static. 2019-06-03 15:31:42 -07:00
losfair
0a44add31c Fix clippy errors. 2019-06-03 15:31:42 -07:00
losfair
d70cb9695e Add trampoline-related functions to C API. 2019-06-03 15:31:42 -07:00
losfair
7808c68cb2 Cargo fmt 2019-06-03 15:31:42 -07:00
losfair
ae19e7f71b Trampoline for calling with context. 2019-06-03 15:31:42 -07:00
bors[bot]
df486b7beb Merge #437
437: Use the new code generator API for Cranelift backend. r=bjfish a=bjfish

Refactor for Cranelift backend to use new code generator API
- [x] Add initial stubbed code generators
- [x] Implement code generators
- [x] Remove old compiler code
- [x] Re-enable warnings
- [x] Cleanup expect/unwrap debug usages

Co-authored-by: Brandon Fish <brandon.j.fish@gmail.com>
Co-authored-by: Brandon Fish <bjfish@users.noreply.github.com>
2019-06-02 04:51:48 +00:00
Brandon Fish
6a5e7051b2 Fix workaround 2019-06-01 23:39:43 -05:00
Brandon Fish
6acf854052 Try workaround to force cranelift_wasm to rebuild to try to fix CI issue 2019-06-01 23:26:17 -05:00
Brandon Fish
910653750c Re-enable cache 2019-06-01 19:12:23 -05:00
Brandon Fish
a56e0f22ad Resetting Cargo.lock 2019-06-01 18:22:23 -05:00
Brandon Fish
5fd8598fd1 Temporary disable cache for test 2019-06-01 18:14:03 -05:00
Brandon Fish
3a00f779e8 Try using dependency git revision to see if it fixes CI dependency error 2019-06-01 15:29:49 -05:00
Brandon Fish
2860c4996c
Merge branch 'master' into feature/clif-cgapi 2019-06-01 12:04:20 -05:00
bors[bot]
8b9b0d9041 Merge #478
478: Add cache store, load, and execute test for cranelift and llvm r=bjfish a=bjfish



Co-authored-by: Brandon Fish <brandon.j.fish@gmail.com>
2019-06-01 16:54:28 +00:00
Brandon Fish
fd373dbf63 Add cache store, load, and execute test for cranelift and llvm 2019-06-01 11:35:26 -05:00
Brandon Fish
0567032bef
Merge branch 'master' into feature/clif-cgapi 2019-05-31 23:40:42 -05:00
bors[bot]
ecadbe1cf8 Merge #476
476: fix bug in wasi::environ_get, fix off by one error in env_size_get r=MarkMcCaskey a=MarkMcCaskey

adds `--env` flag (resolves #475)
fixes other wasi env bugs
adds wasi envvar test

Co-authored-by: Mark McCaskey <mark@wasmer.io>
2019-05-30 19:36:24 +00:00
Mark McCaskey
6a9515d13d improve wasi envvar test 2019-05-30 12:25:14 -07:00
Mark McCaskey
2a94a6933f add envvar opt, add test, rm binaries from wasitests, clean up 2019-05-30 11:58:52 -07:00
Brandon Fish
b2e37cecfa
Merge branch 'master' into feature/clif-cgapi 2019-05-29 22:45:31 -05:00
Mark McCaskey
792ebc06fc fix bug in wasi::environ_get, fix off by one error in env_size_get 2019-05-29 18:04:55 -07:00
Syrus Akbary
5d63c96d96
Update ARCHITECTURE.md 2019-05-29 15:12:45 -07:00
bors[bot]
f0544e9e7a Merge #470
470: add mapdir for emscripten; implement getdents, etc. r=MarkMcCaskey a=MarkMcCaskey



Co-authored-by: Mark McCaskey <mark@wasmer.io>
2019-05-29 21:36:29 +00:00
Mark McCaskey
4c8915efd8 add mapdir pr to changelog 2019-05-29 14:35:58 -07:00
Mark McCaskey
281c5ff45d fix bugs in em mapdir, improve it for relative paths, use it more 2019-05-29 14:20:52 -07:00
Syrus Akbary
b627fbf8bb
Added support for Go 2019-05-29 12:36:09 -07:00
Mark McCaskey
7a7aa4608a fix emscripten regression tests 2019-05-29 11:41:29 -07:00
bors[bot]
3e1fde6d67 Merge #474
474: fix(runtime-c-api) Set the install name of the dylib to `@rpath`. r=Hywan a=Hywan

```sh
$ objdump -macho -dylib-id libwasmer_runtime_c_api.dylib
libwasmer_runtime_c_api.dylib:
/Users/distiller/project/target/release/deps/libwasmer_runtime_c_api.dylib
```

we observe that the dylib ID (aka install name) is set to
`/Users/distiller/project/target/release/deps/libwasmer_runtime_c_api.dylib`,
which is valid only in the context of CircleCI.

This patch changes the dylib ID to
`@rpath/libwasmer_runtime_c_api.dylib`, which can be then changed by
the linker option `-rpath` (use `-Wl,-rpath,$value` with the compiler
to send the `-rpath` value to the linker).

This is super useful when dynamically linking libraries against
another language. Having the dylib ID already set to `@rpath` avoid any
build system to call `install_name_tool` manually, which isn't always
possible (e.g. in Go with cgo where we can only pass options to the
compiler with `LDFLAGS`, it's impossible to run any arbitrary command).

Co-authored-by: Ivan Enderlin <ivan.enderlin@hoa-project.net>
2019-05-29 14:44:44 +00:00
Ivan Enderlin
ff5d50b273 fix(runtime-c-api) Set the install name of the dylib to @rpath.
```sh
$ objdump -macho -dylib-id libwasmer_runtime_c_api.dylib
libwasmer_runtime_c_api.dylib:
/Users/distiller/project/target/release/deps/libwasmer_runtime_c_api.dylib
```

we observe that the dylib ID (aka install name) is set to
`/Users/distiller/project/target/release/deps/libwasmer_runtime_c_api.dylib`,
which is valid only in the context of CircleCI.

This patch changes the dylib ID to
`@rpath/libwasmer_runtime_c_api.dylib`, which can be then changed by
the linker option `-rpath` (use `-Wl,-rpath,$value` with the compiler
to send the `-rpath` value to the linker).

This is super useful when dynamically linking libraries against
another language.
2019-05-29 16:14:04 +02:00
Syrus Akbary
e0d4c9e1b7
Trying to make ghr always to pass in CircleCI 2019-05-29 01:03:51 -07:00
Syrus Akbary
74fb26cf24
Upload artifacts always (when possible) 2019-05-28 18:15:48 -07:00
Syrus
dd2735d0dc Fixed macos build 2019-05-28 15:31:19 -07:00
Syrus
5791583228 Create dynamic libraries for different platforms per release 2019-05-28 15:04:58 -07:00
Mark McCaskey
6606a7c7b0 silence clippy on pointer alignment 2019-05-28 14:06:24 -07:00
Mark McCaskey
f8b94b7469 Merge remote-tracking branch 'origin/master' into feature/add-mapdir-for-emscripten 2019-05-28 13:48:12 -07:00
Syrus Akbary
b0d73917af
Merge pull request #472 from styfle/patch-1
Add 🦀 to the Rust language
2019-05-28 12:22:00 -07:00
Steven
4b2092d613
Add 🦀 to the Rust language 2019-05-28 14:41:12 -04:00
Mark McCaskey
3a4517d5d6 clean up code, verify it behaves the same as emscripten with js 2019-05-28 10:06:22 -07:00
Syrus Akbary
ef4908d3bc
Fix security contact 2019-05-27 14:41:18 -07:00
Syrus Akbary
df03fc1fd3
Added Security Policy. Fixed #468 2019-05-27 13:57:17 -07:00
bors[bot]
813b57b40e Merge #465
465: Running jq r=syrusakbary a=syrusakbary

This PR does:
* Add the functions needed to run jq
* Refactor how varargs strings are handled (to simplify them)

Co-authored-by: Syrus <me@syrusakbary.com>
Co-authored-by: Syrus Akbary <me@syrusakbary.com>
2019-05-27 20:25:25 +00:00