Merge branch 'master' into test-runtime-core-typed_func

This commit is contained in:
Ivan Enderlin 2019-11-19 14:34:53 +01:00 committed by GitHub
commit b856e111b6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
27 changed files with 373 additions and 213 deletions

View File

@ -2,7 +2,10 @@
## **[Unreleased]**
## 0.10.2 - 2019-11-18
- [#968](https://github.com/wasmerio/wasmer/pull/968) Added `--invoke` option to the command
- [#964](https://github.com/wasmerio/wasmer/pull/964) Enable cross-compilation for specific target
- [#971](https://github.com/wasmerio/wasmer/pull/971) In LLVM backend, use unaligned loads and stores for non-atomic accesses to wasmer memory.
- [#960](https://github.com/wasmerio/wasmer/pull/960) Fix `runtime-c-api` header files when compiled by clang.
- [#925](https://github.com/wasmerio/wasmer/pull/925) Host functions can be closures with a captured environment.

146
Cargo.lock generated
View File

@ -720,8 +720,8 @@ version = "0.1.0"
dependencies = [
"rayon 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
"time 0.1.42 (registry+https://github.com/rust-lang/crates.io-index)",
"wasmer-runtime 0.10.1",
"wasmer-runtime-core 0.10.1",
"wasmer-runtime 0.10.2",
"wasmer-runtime-core 0.10.2",
]
[[package]]
@ -1333,7 +1333,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
[[package]]
name = "wasmer"
version = "0.10.1"
version = "0.10.2"
dependencies = [
"byteorder 1.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
"errno 0.2.4 (registry+https://github.com/rust-lang/crates.io-index)",
@ -1343,24 +1343,24 @@ dependencies = [
"structopt 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
"typetag 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
"wabt 0.9.2 (registry+https://github.com/rust-lang/crates.io-index)",
"wasmer-clif-backend 0.10.1",
"wasmer-dev-utils 0.10.1",
"wasmer-emscripten 0.10.1",
"wasmer-emscripten-tests 0.10.1",
"wasmer-clif-backend 0.10.2",
"wasmer-dev-utils 0.10.2",
"wasmer-emscripten 0.10.2",
"wasmer-emscripten-tests 0.10.2",
"wasmer-kernel-loader 0.1.0",
"wasmer-llvm-backend 0.10.1",
"wasmer-middleware-common 0.10.1",
"wasmer-middleware-common-tests 0.10.1",
"wasmer-runtime 0.10.1",
"wasmer-runtime-core 0.10.1",
"wasmer-singlepass-backend 0.10.1",
"wasmer-wasi 0.10.1",
"wasmer-wasi-tests 0.10.1",
"wasmer-llvm-backend 0.10.2",
"wasmer-middleware-common 0.10.2",
"wasmer-middleware-common-tests 0.10.2",
"wasmer-runtime 0.10.2",
"wasmer-runtime-core 0.10.2",
"wasmer-singlepass-backend 0.10.2",
"wasmer-wasi 0.10.2",
"wasmer-wasi-tests 0.10.2",
]
[[package]]
name = "wasmer-clif-backend"
version = "0.10.1"
version = "0.10.2"
dependencies = [
"byteorder 1.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
"cranelift-codegen 0.44.0 (registry+https://github.com/rust-lang/crates.io-index)",
@ -1376,8 +1376,8 @@ dependencies = [
"target-lexicon 0.8.1 (registry+https://github.com/rust-lang/crates.io-index)",
"wasmer-clif-fork-frontend 0.44.0 (registry+https://github.com/rust-lang/crates.io-index)",
"wasmer-clif-fork-wasm 0.44.0 (registry+https://github.com/rust-lang/crates.io-index)",
"wasmer-runtime-core 0.10.1",
"wasmer-win-exception-handler 0.10.1",
"wasmer-runtime-core 0.10.2",
"wasmer-win-exception-handler 0.10.2",
"wasmparser 0.39.2 (registry+https://github.com/rust-lang/crates.io-index)",
"winapi 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)",
]
@ -1409,35 +1409,35 @@ dependencies = [
[[package]]
name = "wasmer-dev-utils"
version = "0.10.1"
version = "0.10.2"
dependencies = [
"libc 0.2.65 (registry+https://github.com/rust-lang/crates.io-index)",
]
[[package]]
name = "wasmer-emscripten"
version = "0.10.1"
version = "0.10.2"
dependencies = [
"byteorder 1.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
"getrandom 0.1.13 (registry+https://github.com/rust-lang/crates.io-index)",
"lazy_static 1.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
"libc 0.2.65 (registry+https://github.com/rust-lang/crates.io-index)",
"time 0.1.42 (registry+https://github.com/rust-lang/crates.io-index)",
"wasmer-runtime-core 0.10.1",
"wasmer-runtime-core 0.10.2",
]
[[package]]
name = "wasmer-emscripten-tests"
version = "0.10.1"
version = "0.10.2"
dependencies = [
"glob 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
"wabt 0.9.2 (registry+https://github.com/rust-lang/crates.io-index)",
"wasmer-clif-backend 0.10.1",
"wasmer-dev-utils 0.10.1",
"wasmer-emscripten 0.10.1",
"wasmer-llvm-backend 0.10.1",
"wasmer-runtime-core 0.10.1",
"wasmer-singlepass-backend 0.10.1",
"wasmer-clif-backend 0.10.2",
"wasmer-dev-utils 0.10.2",
"wasmer-emscripten 0.10.2",
"wasmer-llvm-backend 0.10.2",
"wasmer-runtime-core 0.10.2",
"wasmer-singlepass-backend 0.10.2",
]
[[package]]
@ -1445,12 +1445,12 @@ name = "wasmer-kernel-loader"
version = "0.1.0"
dependencies = [
"libc 0.2.65 (registry+https://github.com/rust-lang/crates.io-index)",
"wasmer-runtime-core 0.10.1",
"wasmer-runtime-core 0.10.2",
]
[[package]]
name = "wasmer-llvm-backend"
version = "0.10.1"
version = "0.10.2"
dependencies = [
"byteorder 1.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
"cc 1.0.46 (registry+https://github.com/rust-lang/crates.io-index)",
@ -1464,60 +1464,60 @@ dependencies = [
"semver 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)",
"smallvec 0.6.12 (registry+https://github.com/rust-lang/crates.io-index)",
"wabt 0.9.2 (registry+https://github.com/rust-lang/crates.io-index)",
"wasmer-runtime-core 0.10.1",
"wasmer-runtime-core 0.10.2",
"wasmparser 0.39.2 (registry+https://github.com/rust-lang/crates.io-index)",
"winapi 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)",
]
[[package]]
name = "wasmer-middleware-common"
version = "0.10.1"
version = "0.10.2"
dependencies = [
"wasmer-runtime-core 0.10.1",
"wasmer-runtime-core 0.10.2",
]
[[package]]
name = "wasmer-middleware-common-tests"
version = "0.10.1"
version = "0.10.2"
dependencies = [
"criterion 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
"wabt 0.9.2 (registry+https://github.com/rust-lang/crates.io-index)",
"wasmer-clif-backend 0.10.1",
"wasmer-llvm-backend 0.10.1",
"wasmer-middleware-common 0.10.1",
"wasmer-runtime-core 0.10.1",
"wasmer-singlepass-backend 0.10.1",
"wasmer-clif-backend 0.10.2",
"wasmer-llvm-backend 0.10.2",
"wasmer-middleware-common 0.10.2",
"wasmer-runtime-core 0.10.2",
"wasmer-singlepass-backend 0.10.2",
]
[[package]]
name = "wasmer-runtime"
version = "0.10.1"
version = "0.10.2"
dependencies = [
"criterion 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
"lazy_static 1.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
"memmap 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)",
"tempfile 3.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"wabt 0.9.2 (registry+https://github.com/rust-lang/crates.io-index)",
"wasmer-clif-backend 0.10.1",
"wasmer-llvm-backend 0.10.1",
"wasmer-runtime-core 0.10.1",
"wasmer-singlepass-backend 0.10.1",
"wasmer-clif-backend 0.10.2",
"wasmer-llvm-backend 0.10.2",
"wasmer-runtime-core 0.10.2",
"wasmer-singlepass-backend 0.10.2",
]
[[package]]
name = "wasmer-runtime-c-api"
version = "0.10.1"
version = "0.10.2"
dependencies = [
"cbindgen 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)",
"libc 0.2.65 (registry+https://github.com/rust-lang/crates.io-index)",
"wasmer-runtime 0.10.1",
"wasmer-runtime-core 0.10.1",
"wasmer-wasi 0.10.1",
"wasmer-runtime 0.10.2",
"wasmer-runtime-core 0.10.2",
"wasmer-wasi 0.10.2",
]
[[package]]
name = "wasmer-runtime-core"
version = "0.10.1"
version = "0.10.2"
dependencies = [
"bincode 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
"blake2b_simd 0.5.8 (registry+https://github.com/rust-lang/crates.io-index)",
@ -1543,18 +1543,18 @@ dependencies = [
[[package]]
name = "wasmer-runtime-core-tests"
version = "0.10.1"
version = "0.10.2"
dependencies = [
"wabt 0.9.2 (registry+https://github.com/rust-lang/crates.io-index)",
"wasmer-clif-backend 0.10.1",
"wasmer-llvm-backend 0.10.1",
"wasmer-runtime-core 0.10.1",
"wasmer-singlepass-backend 0.10.1",
"wasmer-clif-backend 0.10.2",
"wasmer-llvm-backend 0.10.2",
"wasmer-runtime-core 0.10.2",
"wasmer-singlepass-backend 0.10.2",
]
[[package]]
name = "wasmer-singlepass-backend"
version = "0.10.1"
version = "0.10.2"
dependencies = [
"byteorder 1.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
"dynasm 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
@ -1563,24 +1563,24 @@ dependencies = [
"libc 0.2.65 (registry+https://github.com/rust-lang/crates.io-index)",
"nix 0.15.0 (registry+https://github.com/rust-lang/crates.io-index)",
"smallvec 0.6.12 (registry+https://github.com/rust-lang/crates.io-index)",
"wasmer-runtime-core 0.10.1",
"wasmer-runtime-core 0.10.2",
]
[[package]]
name = "wasmer-spectests"
version = "0.10.1"
version = "0.10.2"
dependencies = [
"glob 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
"wabt 0.9.2 (registry+https://github.com/rust-lang/crates.io-index)",
"wasmer-clif-backend 0.10.1",
"wasmer-llvm-backend 0.10.1",
"wasmer-runtime-core 0.10.1",
"wasmer-singlepass-backend 0.10.1",
"wasmer-clif-backend 0.10.2",
"wasmer-llvm-backend 0.10.2",
"wasmer-runtime-core 0.10.2",
"wasmer-singlepass-backend 0.10.2",
]
[[package]]
name = "wasmer-wasi"
version = "0.10.1"
version = "0.10.2"
dependencies = [
"bincode 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
"byteorder 1.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
@ -1591,31 +1591,31 @@ dependencies = [
"serde 1.0.102 (registry+https://github.com/rust-lang/crates.io-index)",
"time 0.1.42 (registry+https://github.com/rust-lang/crates.io-index)",
"typetag 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
"wasmer-runtime-core 0.10.1",
"wasmer-runtime-core 0.10.2",
"winapi 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)",
]
[[package]]
name = "wasmer-wasi-tests"
version = "0.10.1"
version = "0.10.2"
dependencies = [
"glob 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
"wasmer-clif-backend 0.10.1",
"wasmer-dev-utils 0.10.1",
"wasmer-llvm-backend 0.10.1",
"wasmer-runtime 0.10.1",
"wasmer-runtime-core 0.10.1",
"wasmer-singlepass-backend 0.10.1",
"wasmer-wasi 0.10.1",
"wasmer-clif-backend 0.10.2",
"wasmer-dev-utils 0.10.2",
"wasmer-llvm-backend 0.10.2",
"wasmer-runtime 0.10.2",
"wasmer-runtime-core 0.10.2",
"wasmer-singlepass-backend 0.10.2",
"wasmer-wasi 0.10.2",
]
[[package]]
name = "wasmer-win-exception-handler"
version = "0.10.1"
version = "0.10.2"
dependencies = [
"cmake 0.1.42 (registry+https://github.com/rust-lang/crates.io-index)",
"libc 0.2.65 (registry+https://github.com/rust-lang/crates.io-index)",
"wasmer-runtime-core 0.10.1",
"wasmer-runtime-core 0.10.2",
"winapi 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)",
]

View File

@ -1,6 +1,6 @@
[package]
name = "wasmer"
version = "0.10.1"
version = "0.10.2"
authors = ["The Wasmer Engineering Team <engineering@wasmer.io>"]
edition = "2018"
repository = "https://github.com/wasmerio/wasmer"

View File

@ -205,7 +205,7 @@ jobs:
dependsOn:
- Build_CLI
- Build_Library
condition: eq(variables['Build.SourceBranch'], 'refs/heads/master')
condition: or(eq(variables['Build.SourceBranch'], 'refs/heads/master'), startsWith(variables['Build.SourceBranch'], 'refs/tags'))
steps:
# - download: current
- task: DownloadPipelineArtifact@1
@ -259,3 +259,4 @@ trigger:
- master
- staging
- trying
- refs/tags/*

View File

@ -1,6 +1,6 @@
[package]
name = "wasmer-clif-backend"
version = "0.10.1"
version = "0.10.2"
description = "Wasmer runtime Cranelift compiler backend"
license = "MIT"
authors = ["The Wasmer Engineering Team <engineering@wasmer.io>"]
@ -11,7 +11,7 @@ edition = "2018"
readme = "README.md"
[dependencies]
wasmer-runtime-core = { path = "../runtime-core", version = "0.10.1" }
wasmer-runtime-core = { path = "../runtime-core", version = "0.10.2" }
cranelift-native = "0.44.0"
cranelift-codegen = "0.44.0"
cranelift-entity = "0.44.0"
@ -37,7 +37,7 @@ version = "0.0.7"
[target.'cfg(windows)'.dependencies]
winapi = { version = "0.3", features = ["errhandlingapi", "minwindef", "minwinbase", "winnt"] }
wasmer-win-exception-handler = { path = "../win-exception-handler", version = "0.10.1" }
wasmer-win-exception-handler = { path = "../win-exception-handler", version = "0.10.2" }
[features]
debug = ["wasmer-runtime-core/debug"]

View File

@ -1,6 +1,6 @@
[package]
name = "wasmer-dev-utils"
version = "0.10.1"
version = "0.10.2"
description = "Wasmer runtime core library"
license = "MIT"
authors = ["The Wasmer Engineering Team <engineering@wasmer.io>"]

View File

@ -1,6 +1,6 @@
[package]
name = "wasmer-emscripten-tests"
version = "0.10.1"
version = "0.10.2"
description = "Tests for our Emscripten implementation"
license = "MIT"
authors = ["The Wasmer Engineering Team <engineering@wasmer.io>"]
@ -9,15 +9,15 @@ publish = false
build = "build/mod.rs"
[dependencies]
wasmer-emscripten = { path = "../emscripten", version = "0.10.1" }
wasmer-runtime-core = { path = "../runtime-core", version = "0.10.1" }
wasmer-clif-backend = { path = "../clif-backend", version = "0.10.1" }
wasmer-llvm-backend = { path = "../llvm-backend", version = "0.10.1", optional = true }
wasmer-singlepass-backend = { path = "../singlepass-backend", version = "0.10.1", optional = true }
wasmer-emscripten = { path = "../emscripten", version = "0.10.2" }
wasmer-runtime-core = { path = "../runtime-core", version = "0.10.2" }
wasmer-clif-backend = { path = "../clif-backend", version = "0.10.2" }
wasmer-llvm-backend = { path = "../llvm-backend", version = "0.10.2", optional = true }
wasmer-singlepass-backend = { path = "../singlepass-backend", version = "0.10.2", optional = true }
[dev-dependencies]
wabt = "0.9.1"
wasmer-dev-utils = { path = "../dev-utils", version = "0.10.1"}
wasmer-dev-utils = { path = "../dev-utils", version = "0.10.2"}
[build-dependencies]
glob = "0.3"

View File

@ -1,6 +1,6 @@
[package]
name = "wasmer-emscripten"
version = "0.10.1"
version = "0.10.2"
description = "Wasmer runtime emscripten implementation library"
license = "MIT"
authors = ["The Wasmer Engineering Team <engineering@wasmer.io>"]
@ -14,7 +14,7 @@ byteorder = "1.3"
lazy_static = "1.4"
libc = "0.2.60"
time = "0.1"
wasmer-runtime-core = { path = "../runtime-core", version = "0.10.1" }
wasmer-runtime-core = { path = "../runtime-core", version = "0.10.2" }
[target.'cfg(windows)'.dependencies]
getrandom = "0.1"

View File

@ -1,6 +1,6 @@
[package]
name = "wasmer-llvm-backend"
version = "0.10.1"
version = "0.10.2"
license = "MIT"
authors = ["The Wasmer Engineering Team <engineering@wasmer.io>"]
repository = "https://github.com/wasmerio/wasmer"
@ -10,7 +10,7 @@ edition = "2018"
readme = "README.md"
[dependencies]
wasmer-runtime-core = { path = "../runtime-core", version = "0.10.1" }
wasmer-runtime-core = { path = "../runtime-core", version = "0.10.2" }
wasmparser = "0.39.1"
smallvec = "0.6"
goblin = "0.0.24"

View File

@ -1,6 +1,6 @@
[package]
name = "wasmer-middleware-common-tests"
version = "0.10.1"
version = "0.10.2"
authors = ["The Wasmer Engineering Team <engineering@wasmer.io>"]
edition = "2018"
repository = "https://github.com/wasmerio/wasmer"
@ -8,11 +8,11 @@ license = "MIT"
publish = false
[dependencies]
wasmer-runtime-core = { path = "../runtime-core", version = "0.10.1" }
wasmer-middleware-common = { path = "../middleware-common", version = "0.10.1" }
wasmer-clif-backend = { path = "../clif-backend", version = "0.10.1" }
wasmer-llvm-backend = { path = "../llvm-backend", version = "0.10.1", optional = true }
wasmer-singlepass-backend = { path = "../singlepass-backend", version = "0.10.1", optional = true }
wasmer-runtime-core = { path = "../runtime-core", version = "0.10.2" }
wasmer-middleware-common = { path = "../middleware-common", version = "0.10.2" }
wasmer-clif-backend = { path = "../clif-backend", version = "0.10.2" }
wasmer-llvm-backend = { path = "../llvm-backend", version = "0.10.2", optional = true }
wasmer-singlepass-backend = { path = "../singlepass-backend", version = "0.10.2", optional = true }
[features]
clif = []

View File

@ -1,6 +1,6 @@
[package]
name = "wasmer-middleware-common"
version = "0.10.1"
version = "0.10.2"
repository = "https://github.com/wasmerio/wasmer"
description = "Wasmer runtime common middlewares"
license = "MIT"
@ -10,4 +10,4 @@ categories = ["wasm"]
edition = "2018"
[dependencies]
wasmer-runtime-core = { path = "../runtime-core", version = "0.10.1" }
wasmer-runtime-core = { path = "../runtime-core", version = "0.10.2" }

View File

@ -1,6 +1,6 @@
[package]
name = "wasmer-runtime-c-api"
version = "0.10.1"
version = "0.10.2"
description = "Wasmer C API library"
license = "MIT"
authors = ["The Wasmer Engineering Team <engineering@wasmer.io>"]
@ -19,17 +19,17 @@ libc = "0.2.60"
[dependencies.wasmer-runtime]
default-features = false
path = "../runtime"
version = "0.10.1"
version = "0.10.2"
[dependencies.wasmer-runtime-core]
default-features = false
path = "../runtime-core"
version = "0.10.1"
version = "0.10.2"
[dependencies.wasmer-wasi]
default-features = false
path = "../wasi"
version = "0.10.1"
version = "0.10.2"
optional = true
[features]

View File

@ -1,6 +1,6 @@
[package]
name = "wasmer-runtime-core-tests"
version = "0.10.1"
version = "0.10.2"
description = "Tests for the Wasmer runtime core crate"
license = "MIT"
authors = ["The Wasmer Engineering Team <engineering@wasmer.io>"]
@ -9,10 +9,10 @@ publish = false
[dependencies]
wabt = "0.9.1"
wasmer-runtime-core = { path = "../runtime-core", version = "0.10.1" }
wasmer-clif-backend = { path = "../clif-backend", version = "0.10.1", optional = true }
wasmer-singlepass-backend = { path = "../singlepass-backend", version = "0.10.1", optional = true }
wasmer-llvm-backend = { path = "../llvm-backend", version = "0.10.1", optional = true }
wasmer-runtime-core = { path = "../runtime-core", version = "0.10.2" }
wasmer-clif-backend = { path = "../clif-backend", version = "0.10.2", optional = true }
wasmer-singlepass-backend = { path = "../singlepass-backend", version = "0.10.2", optional = true }
wasmer-llvm-backend = { path = "../llvm-backend", version = "0.10.2", optional = true }
[features]
default = ["backend-cranelift"]

View File

@ -1,6 +1,6 @@
[package]
name = "wasmer-runtime-core"
version = "0.10.1"
version = "0.10.2"
description = "Wasmer runtime core library"
license = "MIT"
authors = ["The Wasmer Engineering Team <engineering@wasmer.io>"]

View File

@ -1,6 +1,6 @@
[package]
name = "wasmer-runtime"
version = "0.10.1"
version = "0.10.2"
description = "Wasmer runtime library"
license = "MIT"
authors = ["The Wasmer Engineering Team <engineering@wasmer.io>"]
@ -11,17 +11,17 @@ edition = "2018"
readme = "README.md"
[dependencies]
wasmer-singlepass-backend = { path = "../singlepass-backend", version = "0.10.1", optional = true }
wasmer-singlepass-backend = { path = "../singlepass-backend", version = "0.10.2", optional = true }
lazy_static = "1.4"
memmap = "0.7"
[dependencies.wasmer-runtime-core]
path = "../runtime-core"
version = "0.10.1"
version = "0.10.2"
[dependencies.wasmer-clif-backend]
path = "../clif-backend"
version = "0.10.1"
version = "0.10.2"
optional = true
[dev-dependencies]

View File

@ -1,6 +1,6 @@
[package]
name = "wasmer-singlepass-backend"
version = "0.10.1"
version = "0.10.2"
repository = "https://github.com/wasmerio/wasmer"
description = "Wasmer runtime single pass compiler backend"
license = "MIT"
@ -11,7 +11,7 @@ edition = "2018"
readme = "README.md"
[dependencies]
wasmer-runtime-core = { path = "../runtime-core", version = "0.10.1" }
wasmer-runtime-core = { path = "../runtime-core", version = "0.10.2" }
dynasm = "0.3.2"
dynasmrt = "0.3.1"
lazy_static = "1.4"

View File

@ -662,33 +662,35 @@ impl X64FunctionCode {
sz_dst: Size,
dst: Location,
) {
let tmp_src = m.acquire_temp_gpr().unwrap();
let tmp_dst = m.acquire_temp_gpr().unwrap();
match src {
Location::Imm32(_) | Location::Imm64(_) => {
a.emit_mov(Size::S64, src, Location::GPR(tmp_src));
src = Location::GPR(tmp_src);
}
Location::Memory(_, _) | Location::GPR(_) => {}
_ => unreachable!(),
}
match dst {
let inner = |m: &mut Machine, a: &mut Assembler, src: Location| match dst {
Location::Imm32(_) | Location::Imm64(_) => unreachable!(),
Location::Memory(_, _) => {
let tmp_dst = m.acquire_temp_gpr().unwrap();
op(a, sz_src, src, sz_dst, Location::GPR(tmp_dst));
a.emit_mov(Size::S64, Location::GPR(tmp_dst), dst);
m.release_temp_gpr(tmp_dst);
}
Location::GPR(_) => {
op(a, sz_src, src, sz_dst, dst);
}
_ => unreachable!(),
}
};
match src {
Location::Imm32(_) | Location::Imm64(_) => {
let tmp_src = m.acquire_temp_gpr().unwrap();
a.emit_mov(Size::S64, src, Location::GPR(tmp_src));
src = Location::GPR(tmp_src);
inner(m, a, src);
m.release_temp_gpr(tmp_dst);
m.release_temp_gpr(tmp_src);
}
Location::GPR(_) | Location::Memory(_, _) => inner(m, a, src),
_ => unreachable!(),
}
}
/// Moves `src` and `dst` to valid locations for generic instructions.
fn emit_relaxed_binop(
@ -2952,6 +2954,106 @@ impl FunctionCodeGenerator<CodegenError> for X64FunctionCode {
ret,
);
}
Operator::I32Extend8S => {
let loc =
get_location_released(a, &mut self.machine, self.value_stack.pop().unwrap());
let ret = self.machine.acquire_locations(
a,
&[(WpType::I32, MachineValue::WasmStack(self.value_stack.len()))],
false,
)[0];
self.value_stack.push(ret);
Self::emit_relaxed_zx_sx(
a,
&mut self.machine,
Assembler::emit_movsx,
Size::S8,
loc,
Size::S32,
ret,
);
}
Operator::I32Extend16S => {
let loc =
get_location_released(a, &mut self.machine, self.value_stack.pop().unwrap());
let ret = self.machine.acquire_locations(
a,
&[(WpType::I32, MachineValue::WasmStack(self.value_stack.len()))],
false,
)[0];
self.value_stack.push(ret);
Self::emit_relaxed_zx_sx(
a,
&mut self.machine,
Assembler::emit_movsx,
Size::S16,
loc,
Size::S32,
ret,
);
}
Operator::I64Extend8S => {
let loc =
get_location_released(a, &mut self.machine, self.value_stack.pop().unwrap());
let ret = self.machine.acquire_locations(
a,
&[(WpType::I64, MachineValue::WasmStack(self.value_stack.len()))],
false,
)[0];
self.value_stack.push(ret);
Self::emit_relaxed_zx_sx(
a,
&mut self.machine,
Assembler::emit_movsx,
Size::S8,
loc,
Size::S64,
ret,
);
}
Operator::I64Extend16S => {
let loc =
get_location_released(a, &mut self.machine, self.value_stack.pop().unwrap());
let ret = self.machine.acquire_locations(
a,
&[(WpType::I64, MachineValue::WasmStack(self.value_stack.len()))],
false,
)[0];
self.value_stack.push(ret);
Self::emit_relaxed_zx_sx(
a,
&mut self.machine,
Assembler::emit_movsx,
Size::S16,
loc,
Size::S64,
ret,
);
}
Operator::I64Extend32S => {
let loc =
get_location_released(a, &mut self.machine, self.value_stack.pop().unwrap());
let ret = self.machine.acquire_locations(
a,
&[(WpType::I64, MachineValue::WasmStack(self.value_stack.len()))],
false,
)[0];
self.value_stack.push(ret);
Self::emit_relaxed_zx_sx(
a,
&mut self.machine,
Assembler::emit_movsx,
Size::S32,
loc,
Size::S64,
ret,
);
}
Operator::I32WrapI64 => {
let loc =
get_location_released(a, &mut self.machine, self.value_stack.pop().unwrap());

View File

@ -1,6 +1,6 @@
[package]
name = "wasmer-spectests"
version = "0.10.1"
version = "0.10.2"
description = "Wasmer spectests library"
license = "MIT"
authors = ["The Wasmer Engineering Team <engineering@wasmer.io>"]
@ -9,10 +9,10 @@ edition = "2018"
[dependencies]
glob = "0.3"
wasmer-runtime-core = { path = "../runtime-core", version = "0.10.1" }
wasmer-clif-backend = { path = "../clif-backend", version = "0.10.1" }
wasmer-llvm-backend = { path = "../llvm-backend", version = "0.10.1", optional = true }
wasmer-singlepass-backend = { path = "../singlepass-backend", version = "0.10.1", optional = true }
wasmer-runtime-core = { path = "../runtime-core", version = "0.10.2" }
wasmer-clif-backend = { path = "../clif-backend", version = "0.10.2" }
wasmer-llvm-backend = { path = "../llvm-backend", version = "0.10.2", optional = true }
wasmer-singlepass-backend = { path = "../singlepass-backend", version = "0.10.2", optional = true }
[build-dependencies]
wabt = "0.9.1"

View File

@ -1,6 +1,11 @@
(module
(func (export "i64.extend_i32_s") (param $x i32) (result i64) (i64.extend_i32_s (local.get $x)))
(func (export "i64.extend_i32_u") (param $x i32) (result i64) (i64.extend_i32_u (local.get $x)))
(func (export "i64.extend32_s") (param $x i64) (result i64) (i64.extend32_s (local.get $x)))
(func (export "i64.extend16_s") (param $x i64) (result i64) (i64.extend16_s (local.get $x)))
(func (export "i64.extend8_s") (param $x i64) (result i64) (i64.extend8_s (local.get $x)))
(func (export "i32.extend16_s") (param $x i32) (result i32) (i32.extend16_s (local.get $x)))
(func (export "i32.extend8_s") (param $x i32) (result i32) (i32.extend8_s (local.get $x)))
(func (export "i32.wrap_i64") (param $x i64) (result i32) (i32.wrap_i64 (local.get $x)))
(func (export "i32.trunc_f32_s") (param $x f32) (result i32) (i32.trunc_f32_s (local.get $x)))
(func (export "i32.trunc_f32_u") (param $x f32) (result i32) (i32.trunc_f32_u (local.get $x)))
@ -497,3 +502,46 @@
(assert_invalid (module (func (result f64) (f64.convert_i64_u (i32.const 0)))) "type mismatch")
(assert_invalid (module (func (result f64) (f64.promote_f32 (i32.const 0)))) "type mismatch")
(assert_invalid (module (func (result f64) (f64.reinterpret_i64 (i32.const 0)))) "type mismatch")
(assert_return (invoke "i32.extend8_s" (i32.const 0)) (i32.const 0))
(assert_return (invoke "i32.extend8_s" (i32.const 0x7f)) (i32.const 127))
(assert_return (invoke "i32.extend8_s" (i32.const 0x80)) (i32.const -128))
(assert_return (invoke "i32.extend8_s" (i32.const 0xff)) (i32.const -1))
(assert_return (invoke "i32.extend8_s" (i32.const 0x012345_00)) (i32.const 0))
(assert_return (invoke "i32.extend8_s" (i32.const 0xfedcba_80)) (i32.const -0x80))
(assert_return (invoke "i32.extend8_s" (i32.const -1)) (i32.const -1))
(assert_return (invoke "i32.extend16_s" (i32.const 0)) (i32.const 0))
(assert_return (invoke "i32.extend16_s" (i32.const 0x7fff)) (i32.const 32767))
(assert_return (invoke "i32.extend16_s" (i32.const 0x8000)) (i32.const -32768))
(assert_return (invoke "i32.extend16_s" (i32.const 0xffff)) (i32.const -1))
(assert_return (invoke "i32.extend16_s" (i32.const 0x0123_0000)) (i32.const 0))
(assert_return (invoke "i32.extend16_s" (i32.const 0xfedc_8000)) (i32.const -0x8000))
(assert_return (invoke "i32.extend16_s" (i32.const -1)) (i32.const -1))
(assert_return (invoke "i64.extend8_s" (i64.const 0)) (i64.const 0))
(assert_return (invoke "i64.extend8_s" (i64.const 0x7f)) (i64.const 127))
(assert_return (invoke "i64.extend8_s" (i64.const 0x80)) (i64.const -128))
(assert_return (invoke "i64.extend8_s" (i64.const 0xff)) (i64.const -1))
(assert_return (invoke "i64.extend8_s" (i64.const 0x01234567_89abcd_00)) (i64.const 0))
(assert_return (invoke "i64.extend8_s" (i64.const 0xfedcba98_765432_80)) (i64.const -0x80))
(assert_return (invoke "i64.extend8_s" (i64.const -1)) (i64.const -1))
(assert_return (invoke "i64.extend16_s" (i64.const 0)) (i64.const 0))
(assert_return (invoke "i64.extend16_s" (i64.const 0x7fff)) (i64.const 32767))
(assert_return (invoke "i64.extend16_s" (i64.const 0x8000)) (i64.const -32768))
(assert_return (invoke "i64.extend16_s" (i64.const 0xffff)) (i64.const -1))
(assert_return (invoke "i64.extend16_s" (i64.const 0x12345678_9abc_0000)) (i64.const 0))
(assert_return (invoke "i64.extend16_s" (i64.const 0xfedcba98_7654_8000)) (i64.const -0x8000))
(assert_return (invoke "i64.extend16_s" (i64.const -1)) (i64.const -1))
(assert_return (invoke "i64.extend32_s" (i64.const 0)) (i64.const 0))
(assert_return (invoke "i64.extend32_s" (i64.const 0x7fff)) (i64.const 32767))
(assert_return (invoke "i64.extend32_s" (i64.const 0x8000)) (i64.const 32768))
(assert_return (invoke "i64.extend32_s" (i64.const 0xffff)) (i64.const 65535))
(assert_return (invoke "i64.extend32_s" (i64.const 0x7fffffff)) (i64.const 0x7fffffff))
(assert_return (invoke "i64.extend32_s" (i64.const 0x80000000)) (i64.const -0x80000000))
(assert_return (invoke "i64.extend32_s" (i64.const 0xffffffff)) (i64.const -1))
(assert_return (invoke "i64.extend32_s" (i64.const 0x01234567_00000000)) (i64.const 0))
(assert_return (invoke "i64.extend32_s" (i64.const 0xfedcba98_80000000)) (i64.const -0x80000000))
(assert_return (invoke "i64.extend32_s" (i64.const -1)) (i64.const -1))

View File

@ -396,73 +396,73 @@ singlepass:fail:call_indirect.wast:493 # AssertTrap - expected trap, got Runtime
singlepass:fail:call_indirect.wast:494 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:call_indirect.wast:500 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:call_indirect.wast:501 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:70 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:71 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:72 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:73 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:74 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:75 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:76 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:77 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:92 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:93 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:94 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:95 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:96 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:78 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:79 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:80 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:81 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:82 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:97 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:98 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:99 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:115 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:116 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:117 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:118 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:119 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:100 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:101 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:102 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:103 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:104 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:120 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:121 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:122 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:138 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:139 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:140 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:141 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:142 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:123 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:124 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:125 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:126 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:127 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:143 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:144 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:145 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:146 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:147 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:148 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:166 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:167 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:168 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:169 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:170 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:149 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:150 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:151 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:152 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:153 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:171 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:172 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:173 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:186 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:187 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:188 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:189 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:190 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:174 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:175 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:176 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:177 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:178 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:191 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:192 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:193 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:211 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:212 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:213 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:214 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:215 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:194 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:195 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:196 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:197 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:198 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:216 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:217 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:218 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:235 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:236 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:237 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:238 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:239 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:219 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:220 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:221 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:222 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:223 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:240 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:241 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:242 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:243 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:244 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:245 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:246 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:conversions.wast:247 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:elem.wast:353 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:func_ptrs.wast:78 # AssertTrap - expected trap, got Runtime:Error unknown error
singlepass:fail:func_ptrs.wast:79 # AssertTrap - expected trap, got Runtime:Error unknown error

View File

@ -186,6 +186,7 @@ mod tests {
let mut features = wabt::Features::new();
features.enable_simd();
features.enable_threads();
features.enable_sign_extension();
let mut parser: ScriptParser =
ScriptParser::from_source_and_name_with_features(&source, filename, features)
.expect(&format!("Failed to parse script {}", &filename));

View File

@ -1,6 +1,6 @@
[package]
name = "wasmer-wasi-tests"
version = "0.10.1"
version = "0.10.2"
description = "Tests for our WASI implementation"
license = "MIT"
authors = ["The Wasmer Engineering Team <engineering@wasmer.io>"]
@ -9,20 +9,20 @@ publish = false
build = "build/mod.rs"
[dependencies]
wasmer-runtime-core = { path = "../runtime-core", version = "0.10.1" }
wasmer-runtime = { path = "../runtime", version = "0.10.1" }
wasmer-wasi = { path = "../wasi", version = "0.10.1" }
wasmer-runtime-core = { path = "../runtime-core", version = "0.10.2" }
wasmer-runtime = { path = "../runtime", version = "0.10.2" }
wasmer-wasi = { path = "../wasi", version = "0.10.2" }
# hack to get tests to work
wasmer-singlepass-backend = { path = "../singlepass-backend", version = "0.10.1", optional = true }
wasmer-llvm-backend = { path = "../llvm-backend", version = "0.10.1", optional = true }
wasmer-singlepass-backend = { path = "../singlepass-backend", version = "0.10.2", optional = true }
wasmer-llvm-backend = { path = "../llvm-backend", version = "0.10.2", optional = true }
[build-dependencies]
glob = "0.3"
[dev-dependencies]
wasmer-clif-backend = { path = "../clif-backend", version = "0.10.1" }
wasmer-dev-utils = { path = "../dev-utils", version = "0.10.1"}
wasmer-clif-backend = { path = "../clif-backend", version = "0.10.2" }
wasmer-dev-utils = { path = "../dev-utils", version = "0.10.2"}
[features]
clif = []

View File

@ -1,6 +1,6 @@
[package]
name = "wasmer-wasi"
version = "0.10.1"
version = "0.10.2"
description = "Wasmer runtime WASI implementation library"
license = "MIT"
authors = ["The Wasmer Engineering Team <engineering@wasmer.io>"]
@ -19,7 +19,7 @@ getrandom = "0.1"
time = "0.1"
typetag = "0.1"
serde = { version = "1", features = ["derive"] }
wasmer-runtime-core = { path = "../runtime-core", version = "0.10.1" }
wasmer-runtime-core = { path = "../runtime-core", version = "0.10.2" }
[target.'cfg(windows)'.dependencies]
winapi = "0.3"

View File

@ -1,6 +1,6 @@
[package]
name = "wasmer-win-exception-handler"
version = "0.10.1"
version = "0.10.2"
description = "Wasmer runtime exception handling for Windows"
license = "MIT"
authors = ["The Wasmer Engineering Team <engineering@wasmer.io>"]
@ -8,7 +8,7 @@ repository = "https://github.com/wasmerio/wasmer"
edition = "2018"
[target.'cfg(windows)'.dependencies]
wasmer-runtime-core = { path = "../runtime-core", version = "0.10.1" }
wasmer-runtime-core = { path = "../runtime-core", version = "0.10.2" }
winapi = { version = "0.3.8", features = ["winbase", "errhandlingapi", "minwindef", "minwinbase", "winnt"] }
libc = "0.2.60"

View File

@ -1,5 +1,5 @@
PREVIOUS_VERSION='0.10.0'
NEXT_VERSION='0.10.1'
PREVIOUS_VERSION='0.10.1'
NEXT_VERSION='0.10.2'
# quick hack
fd Cargo.toml --exec sed -i '' "s/version = \"$PREVIOUS_VERSION\"/version = \"$NEXT_VERSION\"/"

View File

@ -96,6 +96,29 @@ struct PrestandardFeatures {
all: bool,
}
impl PrestandardFeatures {
/// Generate [`wabt::Features`] struct from CLI options
pub fn into_wabt_features(&self) -> wabt::Features {
let mut features = wabt::Features::new();
if self.simd || self.all {
features.enable_simd();
}
if self.threads || self.all {
features.enable_threads();
}
features.enable_sign_extension();
features
}
/// Generate [`Features`] struct from CLI options
pub fn into_backend_features(&self) -> Features {
Features {
simd: self.simd || self.all,
threads: self.threads || self.all,
}
}
}
#[cfg(feature = "backend-llvm")]
#[derive(Debug, StructOpt, Clone)]
/// LLVM backend flags.
@ -393,13 +416,7 @@ fn execute_wasm(options: &Run) -> Result<(), String> {
}
if !utils::is_wasm_binary(&wasm_binary) {
let mut features = wabt::Features::new();
if options.features.simd || options.features.all {
features.enable_simd();
}
if options.features.threads || options.features.all {
features.enable_threads();
}
let features = options.features.into_wabt_features();
wasm_binary = wabt::wat2wasm_with_features(wasm_binary, features)
.map_err(|e| format!("Can't convert from wast to wasm: {:?}", e))?;
}
@ -443,10 +460,7 @@ fn execute_wasm(options: &Run) -> Result<(), String> {
memory_bound_check_mode: MemoryBoundCheckMode::Disable,
enforce_stack_check: true,
track_state,
features: Features {
simd: options.features.simd || options.features.all,
threads: options.features.threads || options.features.all,
},
features: options.features.into_backend_features(),
..Default::default()
},
&*compiler,
@ -458,10 +472,7 @@ fn execute_wasm(options: &Run) -> Result<(), String> {
CompilerConfig {
symbol_map: em_symbol_map.clone(),
track_state,
features: Features {
simd: options.features.simd || options.features.all,
threads: options.features.threads || options.features.all,
},
features: options.features.into_backend_features(),
..Default::default()
},
&*compiler,
@ -506,10 +517,7 @@ fn execute_wasm(options: &Run) -> Result<(), String> {
CompilerConfig {
symbol_map: em_symbol_map.clone(),
track_state,
features: Features {
simd: options.features.simd || options.features.all,
threads: options.features.threads || options.features.all,
},
features: options.features.into_backend_features(),
..Default::default()
},
&*compiler,
@ -807,10 +815,7 @@ fn validate_wasm(validate: Validate) -> Result<(), String> {
wasmer_runtime_core::validate_and_report_errors_with_features(
&wasm_binary,
Features {
simd: validate.features.simd || validate.features.all,
threads: validate.features.threads || validate.features.all,
},
validate.features.into_backend_features(),
)
.map_err(|err| format!("Validation failed: {}", err))?;

View File

@ -1,6 +1,6 @@
[Setup]
AppName=Wasmer
AppVersion=0.10.1
AppVersion=0.10.2
DefaultDirName={pf}\Wasmer
DefaultGroupName=Wasmer
Compression=lzma2