Commit Graph

578 Commits

Author SHA1 Message Date
Simon Warta
c41451a547 Replace wasmparser::Result with wasmer::WasmResult in middleware 2020-12-23 00:07:00 +01:00
Mark McCaskey
e3eb529c60 Merge branch 'master' into feature/clean-up-host-env-code 2020-12-18 07:56:55 -08:00
Mark McCaskey
fc9a8f87df Address feedback, clean up code 2020-12-18 07:54:30 -08:00
bors[bot]
8e343633df Merge #1948
1948: doc: Fix links r=Hywan a=Hywan

# Description

Since the `intra-doc-links` feature has been stabilized, we can see more clearly that we have many broken links. This PR is an attempt to fix them!

# Review

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


Co-authored-by: Ivan Enderlin <ivan@mnt.io>
2020-12-17 13:35:59 +00:00
Ivan Enderlin
78faa4fa25 doc: Fix links.
Since the `intra-doc-links` feature has been stabilized, we can see
more clearly that we have many broken links. This PR is an attempt to
fix them!
2020-12-17 11:24:54 +01:00
Simon Warta
9d6fc4a4ba Expose wasmer::LLVMOptLevel 2020-12-17 10:13:07 +01:00
Simon Warta
85bb1039f8 Expose wasmer::CraneliftOptLevel
This is required to do something like

```rust
use wasmer::{Cranelift, CraneliftOptLevel};

let mut compiler = Cranelift::default();
compiler.opt_level(CraneliftOptLevel::None);
let engine = JIT::new(compiler).engine();
// ...
```
2020-12-17 10:13:07 +01:00
Mark McCaskey
4494bea70a Clean up host env code, add more Send, Sync bounds 2020-12-16 08:37:47 -08:00
Mark McCaskey
59df6917d8 Prepare for 1.0.0-beta2 release 2020-12-16 07:41:59 -08:00
Mark McCaskey
8081aaeee4 Add WasmerEnv: Sync 2020-12-15 13:43:37 -08:00
Mark McCaskey
6a2116917f Fix up tests, make WasmerEnv: Send 2020-12-15 13:35:19 -08:00
Mark McCaskey
62d15fae36 Merge branch 'master' into fix/host-func-env-memory-leak 2020-12-15 08:37:18 -08:00
bors[bot]
59431fade7 Merge #1924 #1934
1924: Export wasmer::{BaseTunables, Tunables} r=Hywan a=webmaster128

Closes #1872

ping @Hywan 

# Review

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


1934: Point to `native` versions of functions in Function docs r=Hywan a=MarkMcCaskey

It's not obvious from looking at the docs for `Function` that there are native variants.  This PR makes it clear that when users are figuring out how to make functions that they're shown the `native` variants.

Co-authored-by: Simon Warta <simon@warta.it>
Co-authored-by: Mark McCaskey <mark@wasmer.io>
2020-12-15 08:17:25 +00:00
bors[bot]
5b6c4de0ce Merge #1929
1929: fix(vm) Update doc', clarify type fields etc. r=Hywan a=Hywan

# Description

Sequel of https://github.com/wasmerio/wasmer/pull/1902. This PR updates the documentation, rename some variables, and clarify some type fields.

# Review

- ~[ ] Add a short description of the the change to the CHANGELOG.md file~ not necessary I guess


Co-authored-by: Ivan Enderlin <ivan@mnt.io>
2020-12-15 07:41:59 +00:00
Mark McCaskey
ad864912c7 Point to native versions of functions in Function docs 2020-12-14 14:41:10 -08:00
Simon Warta
69f834a9e8 Accept Into<FunctionType> as signatures 2020-12-14 13:08:15 +01:00
Ivan Enderlin
facd41412a feat(vm) Rename the instance_allocator fields to instance_ref. 2020-12-14 10:28:38 +01:00
Simon Warta
c0e7f194ad Export wasmer::{BaseTunables, Tunables} 2020-12-12 16:07:14 +01:00
Mark McCaskey
f798f34eef Merge branch 'master' into fix/host-func-env-memory-leak 2020-12-11 17:22:08 -08:00
Mark McCaskey
ec4d6e6d10 Address feedback, make code more explicit about the different cases 2020-12-11 13:00:20 -08:00
bors[bot]
c1402c810b Merge #1896
1896: Improve Wasmer API intro docs r=MarkMcCaskey a=MarkMcCaskey

Setting up our core docs to be easily accessible by new users.

Still a work in progress, but we should be able to ship these doc improvements to master at any time.

Here's what it looks like:

![image](https://user-images.githubusercontent.com/5770194/101407925-738d0580-3890-11eb-9a81-39004093c1bb.png)

# Review

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


Co-authored-by: Mark McCaskey <mark@wasmer.io>
2020-12-11 20:29:54 +00:00
Mark McCaskey
7e1274b0b5 Address feedback on API docs 2020-12-10 17:38:01 -08:00
jubianchi
c81ea9e4bb chore: Remove some warnings 2020-12-10 15:25:56 +01:00
Mark McCaskey
ff194f6251 Add example in the intro, reorder docs 2020-12-09 16:49:07 -08:00
Mark McCaskey
be3c381169 Make NativeFunc Clone 2020-12-09 12:26:53 -08:00
Mark McCaskey
99e035711c Merge branch 'master' into fix/host-func-env-memory-leak 2020-12-09 11:55:50 -08:00
Mark McCaskey
eb8b486388 Fix use-after free with NativeFunc 2020-12-08 12:13:17 -08:00
Mark McCaskey
6e95c50dc2 Address feedback 2020-12-08 11:02:26 -08:00
Mark McCaskey
d54a8b8676 Improve Wasmer API intro docs 2020-12-07 13:29:53 -08:00
Mark McCaskey
476e8d1cd6 Merge branch 'master' into fix/host-func-env-memory-leak 2020-12-07 11:06:01 -08:00
Mark McCaskey
ca4736cca9 Fix tests in C API and deprecated API 2020-12-04 17:40:37 -08:00
Mark McCaskey
4ec8c9e71a Fix issue with dynamic host env 2020-12-04 17:07:01 -08:00
Mark McCaskey
e43d9d2732 Experimental: clone host envs during construction 2020-12-04 16:04:03 -08:00
Syrus Akbary
b8eb7f9b59 Fix lint 2020-12-04 16:01:05 -08:00
Syrus Akbary
1ee0146954 Fix all compilation issues simplifying the code 2020-12-04 15:58:38 -08:00
Syrus Akbary
28c8b877fd Merge branch 'master' into compilerconfig-owned 2020-12-04 13:53:37 -08:00
Syrus
8481161cf9 Updated metering with remaining points implementation 2020-12-04 17:06:29 +01:00
Syrus
13e6f29c29 Set compiler config to be owned (following wasm-c-api) 2020-12-04 02:39:19 -08:00
Simon Warta
31cfa4941d Add missing re-exports CompileError, WasmError and ParseCpuFeatureError 2020-12-04 10:50:40 +01:00
Syrus Akbary
2fac4356a8 Added Cranelift x64 experimental feature flag 2020-12-02 23:02:24 -08:00
Mark McCaskey
1eaea6ecf1 Fix memory leak in host function envs 2020-12-02 16:56:05 -08:00
Mark McCaskey
5cd76521d5 Add #[track_caller] to panic helper function
This will make the line reported in the panic point to a useful
location instead of the helper function.
2020-12-02 14:03:47 -08:00
Mark McCaskey
e928a832a8 Update mentions of alpha to beta 2020-12-02 11:01:54 -08:00
Mark McCaskey
947e7d394f Prepare for 1.0.0-beta1 release 2020-12-01 17:15:46 -08:00
Syrus Akbary
11bf406a2b Merge pull request #1857 from wasmerio/fix/dynamic-fn-env-wasmer-env
Fix dynamic function envs not working with `WasmerEnv`
2020-12-01 17:06:05 -08:00
Mark McCaskey
46567a4bf8 Fix dynamic function envs not working with WasmerEnv 2020-12-01 15:59:14 -08:00
bors[bot]
5371543f4e Merge #1839
1839: Metering middleware. r=syrusakbary a=nlewycky

Based on https://github.com/wasmerio/wasmer-reborn/pull/129 . Original description:

- [x] Necessary APIs for modifying module info.
- [x] Global transformation.
- [x] Per-function transformation.
- [x] Testing and examples.


Co-authored-by: losfair <zhy20000919@hotmail.com>
Co-authored-by: Syrus <me@syrusakbary.com>
Co-authored-by: Nick Lewycky <nick@wasmer.io>
Co-authored-by: nlewycky <nick@wasmer.io>
Co-authored-by: Syrus Akbary <me@syrusakbary.com>
2020-12-01 19:48:44 +00:00
Ivan Enderlin
7973a965fb Merge branch 'master' into fix-vm-leak 2020-12-01 10:08:21 +01:00
Syrus Akbary
097bfeb479 Merge branch 'master' into feature/middleware 2020-11-30 21:31:56 -05:00
Mark McCaskey
4ef3286f2e Merge branch 'master' into feature/host-env-prototype 2020-11-30 16:52:34 -08:00