commit_hash
stringlengths
40
40
author
stringlengths
1
57
date
timestamp[s]date
2010-07-26 04:45:09
2026-04-14 18:21:10
message
stringlengths
8
1.39M
diff
stringlengths
68
51.2k
files_changed
int64
1
136
insertions
int64
0
2.35k
deletions
int64
0
1.9k
ab42f322d4ed4f3f047249eb9eba1e190a74b006
Benjamin Bouvier
2019-10-14T13:46:44
[bugpoint] Don't test for a crash when a mutation doesn't change anything;
diff --git a/cranelift/src/bugpoint.rs b/cranelift/src/bugpoint.rs index 0fc4f619e..cb5f6b58d 100644 --- a/cranelift/src/bugpoint.rs +++ b/cranelift/src/bugpoint.rs @@ -66,19 +66,23 @@ pub fn run( Ok(()) } -enum MutationKind { +enum ProgressStatus { /// The mutation raised or reduced the amount of instruct...
1
39
20
735d4c7aefa71a1e5b4d013bb2b38a9b203f2486
Benjamin Bouvier
2019-10-14T13:39:28
[bugpoint] Make the mutation_count non optional;
diff --git a/cranelift/src/bugpoint.rs b/cranelift/src/bugpoint.rs index f8c266fe4..0fc4f619e 100644 --- a/cranelift/src/bugpoint.rs +++ b/cranelift/src/bugpoint.rs @@ -77,7 +77,7 @@ enum MutationKind { trait Mutator { fn name(&self) -> &'static str; - fn mutation_count(&self, func: &Function) -> Option<usiz...
1
12
12
012fca61f9a07987e1844fccc6f5cf623ee03edb
Benjamin Bouvier
2019-10-14T13:37:28
[bugpoint] Use a unique progress bar and simplify Mutator trait;
diff --git a/cranelift/src/bugpoint.rs b/cranelift/src/bugpoint.rs index bc6826eef..f8c266fe4 100644 --- a/cranelift/src/bugpoint.rs +++ b/cranelift/src/bugpoint.rs @@ -77,68 +77,8 @@ enum MutationKind { trait Mutator { fn name(&self) -> &'static str; - fn mutation_count(&self, func: &Function) -> Option<u...
1
54
67
a5efd2a625bacd436ddcd6f6c985239f0314a05b
Benjamin Bouvier
2019-10-11T14:44:40
[bugpoint] Cosmetic improvements; - Mostly Rust improvements to make code look more idiomatic. - Also reuses the code memory accross compilation, to avoid many memory allocations.
diff --git a/cranelift/src/bugpoint.rs b/cranelift/src/bugpoint.rs index 90d475199..4091f1b9a 100644 --- a/cranelift/src/bugpoint.rs +++ b/cranelift/src/bugpoint.rs @@ -48,9 +48,7 @@ pub fn run( match reduce(isa, func, verbose) { Ok((func, crash_msg)) => { println!("Crash message:...
2
56
73
1ccf056baf7f847b2788f0bc22a39d11eb2c948a
Benjamin Bouvier
2019-10-15T08:25:12
[wasm] Make the ModuleTranslationState ctor public. It's useful for consumers which don't want to translate a whole module, but just need translation of functions.
diff --git a/cranelift/wasm/src/state/module_state.rs b/cranelift/wasm/src/state/module_state.rs index b2cbca77e..306b17a06 100644 --- a/cranelift/wasm/src/state/module_state.rs +++ b/cranelift/wasm/src/state/module_state.rs @@ -19,7 +19,8 @@ pub struct ModuleTranslationState { } impl ModuleTranslationState { - ...
1
2
1
968fb19f17ebbcb982939d77cdce7d2dd41964c9
Marcin Mielniczuk
2019-10-03T13:21:43
Add a typesafe enum for file type
diff --git a/src/hostcalls_impl/fs.rs b/src/hostcalls_impl/fs.rs index 619ed8cc5..c44525cdb 100644 --- a/src/hostcalls_impl/fs.rs +++ b/src/hostcalls_impl/fs.rs @@ -1062,3 +1062,23 @@ pub(crate) unsafe fn fd_prestat_dir_name( enc_slice_of(memory, path.as_bytes(), path_ptr) }) } + +#[allow(dead_co...
4
49
28
566a1436347593f1892c0b9551142191e9cf4e50
Benjamin Bouvier
2019-10-01T16:19:37
[meta] Add pub(crate) to more types; This caught one unused method, allowing us to remove it.
diff --git a/cranelift/codegen/meta/src/cdsl/instructions.rs b/cranelift/codegen/meta/src/cdsl/instructions.rs index 699e30cb3..0d27159cd 100644 --- a/cranelift/codegen/meta/src/cdsl/instructions.rs +++ b/cranelift/codegen/meta/src/cdsl/instructions.rs @@ -18,12 +18,12 @@ use crate::shared::types::{Bool, Float, Int, Re...
5
24
23
d3ef80147b02fc64795769348b46ad7ac8980dda
Benjamin Bouvier
2019-10-01T15:21:52
[meta] Simplify handling of variable arguments in legalization; If a legalization contains varargs, it defers creating the binding for the varargs, making the generated code easier to understand.
diff --git a/cranelift/codegen/meta/src/gen_legalizer.rs b/cranelift/codegen/meta/src/gen_legalizer.rs index d71f97b10..13c4351fb 100644 --- a/cranelift/codegen/meta/src/gen_legalizer.rs +++ b/cranelift/codegen/meta/src/gen_legalizer.rs @@ -44,6 +44,10 @@ fn unwrap_inst( .args .iter() .enumer...
1
14
13
687604d33a1132d552bfc627283c2248fca6fdde
Benjamin Bouvier
2019-07-04T17:48:10
[meta] Legalization: don't emit a spurious `if true` for transforms that always apply; This enhances readability of the generated legalizer code by replacing `if true { body }` with `body`.
diff --git a/cranelift/codegen/meta/src/cdsl/instructions.rs b/cranelift/codegen/meta/src/cdsl/instructions.rs index a62cf39e0..699e30cb3 100644 --- a/cranelift/codegen/meta/src/cdsl/instructions.rs +++ b/cranelift/codegen/meta/src/cdsl/instructions.rs @@ -1169,17 +1169,18 @@ impl InstructionPredicate { self ...
3
38
22
350b3b24064060225eed2f7579071de3f8ef0c06
Benjamin Bouvier
2019-07-04T16:28:12
[meta] Avoid unwrapping instructions several times during legalization; This avoids doing multiple unpacking of the InstructionData for a single legalization, improving readability and reducing size of the generated code. For instance, icmp had to unpack the format once per IntCC condition code.
diff --git a/cranelift/codegen/meta/src/cdsl/ast.rs b/cranelift/codegen/meta/src/cdsl/ast.rs index 9014c4df5..f047a74e5 100644 --- a/cranelift/codegen/meta/src/cdsl/ast.rs +++ b/cranelift/codegen/meta/src/cdsl/ast.rs @@ -63,7 +63,7 @@ impl Def { format!("({})", results.join(", ")) }; - fo...
5
131
57
5dad532a43621e2354069aba7d747b1325b1c643
Marcin Mielniczuk
2019-10-07T14:25:20
Use cvt from the cvt crate in winx
diff --git a/winx/Cargo.toml b/winx/Cargo.toml index cb75e33f0..7b41eb56b 100644 --- a/winx/Cargo.toml +++ b/winx/Cargo.toml @@ -9,3 +9,4 @@ description = "Windows API helper library" [dependencies] winapi = { version = "0.3", features = ["std", "errhandlingapi", "handleapi", "processthreadsapi", "securitybaseapi", "...
2
2
9
ca53090f1bc2ce61fa440576168e259a80eff121
Nick Fitzgerald
2019-10-11T19:37:17
cranelift-wasm: Create `ModuleTranslationState` and polish API a little (#1111) * cranelift-wasm: replace `WasmTypesMap` with `ModuleTranslationState` The `ModuleTranslationState` contains information decoded from the Wasm module that must be referenced during each Wasm function's translation. This is only for ...
diff --git a/cranelift/wasm/src/code_translator.rs b/cranelift/wasm/src/code_translator.rs index a6aa6a32d..bc75157a8 100644 --- a/cranelift/wasm/src/code_translator.rs +++ b/cranelift/wasm/src/code_translator.rs @@ -23,8 +23,8 @@ //! That is why `translate_function_body` takes an object having the `WasmRuntime` trait...
12
127
92
b19f804ed554992a358a80012df66048bebb829b
Andrew Brown
2019-10-02T21:02:58
Convert WASM logical operators to CLIF
diff --git a/cranelift/wasm/src/code_translator.rs b/cranelift/wasm/src/code_translator.rs index 4b6eb8ed3..a6aa6a32d 100644 --- a/cranelift/wasm/src/code_translator.rs +++ b/cranelift/wasm/src/code_translator.rs @@ -1083,6 +1083,22 @@ pub fn translate_operator<FE: FuncEnvironment + ?Sized>( let (a, b) = s...
1
16
4
4c56516d3f5f1d88fb64cbf0d3c6039e330f996e
Andrew Brown
2019-10-02T17:20:31
Allow creating constants in legalization AST This adds a `DummyConstant` structure that is converted to something like `let const0 = pos.func.dfg.constants.insert(...)` in `gen_legalizer.rs`. This allows us to create constants during legalization with something like `let ones = constant(vec![0xff; 16])` and then use `...
diff --git a/cranelift/codegen/meta/src/cdsl/ast.rs b/cranelift/codegen/meta/src/cdsl/ast.rs index 5618927bb..9014c4df5 100644 --- a/cranelift/codegen/meta/src/cdsl/ast.rs +++ b/cranelift/codegen/meta/src/cdsl/ast.rs @@ -54,7 +54,7 @@ impl Def { let results = self .defined_vars .iter(...
3
154
25
96d51cb1e8223137300bd2ef5f17074443e007d6
Andrew Brown
2019-09-30T18:27:29
Switch x86 SIMD bor from ORPS to POR encoding There are two reasons for this change: 1. it reduces confusion; using the `POR` encoding will match the future encodings of `band` and `bxor` and the `ORPS` encoding may be confusing as it is intended for floating-point operations 2. `POR` has slightly more throughput: i...
diff --git a/cranelift/codegen/meta/src/isa/x86/encodings.rs b/cranelift/codegen/meta/src/isa/x86/encodings.rs index c9b1ed8b4..a42c3872e 100644 --- a/cranelift/codegen/meta/src/isa/x86/encodings.rs +++ b/cranelift/codegen/meta/src/isa/x86/encodings.rs @@ -1874,13 +1874,6 @@ pub(crate) fn define<'defs>( e.enc_...
2
9
7
5e879962757e1f00545f25a502d9c3de5b97bdf5
Benjamin Bouvier
2019-10-10T19:19:53
[wasm] Make the WasmTypeMap constructor public; (#1125)
diff --git a/cranelift/wasm/src/environ/spec.rs b/cranelift/wasm/src/environ/spec.rs index 87607755e..499483116 100644 --- a/cranelift/wasm/src/environ/spec.rs +++ b/cranelift/wasm/src/environ/spec.rs @@ -115,8 +115,9 @@ pub struct WasmTypesMap { } impl WasmTypesMap { - pub(crate) fn new() -> Self { - Was...
1
3
2
872f6aa03dac57539863a92e9f1f6818366e8a4f
Artur Jamro
2019-10-10T19:14:45
Fix opt_level builder flag (#411)
diff --git a/src/bin/wasm2obj.rs b/src/bin/wasm2obj.rs index 6b8bd8287..50cc19529 100644 --- a/src/bin/wasm2obj.rs +++ b/src/bin/wasm2obj.rs @@ -225,7 +225,7 @@ fn handle_module( } if enable_optimize { - flag_builder.set("opt_level", "best").unwrap(); + flag_builder.set("opt_level", "speed").u...
2
2
2
9c159ac17c7fe9337722e17b063c190f08bdcce0
Benjamin Bouvier
2019-10-10T10:46:51
Cleanup: Mark ebb as unused in legalization;
diff --git a/cranelift/codegen/src/legalizer/mod.rs b/cranelift/codegen/src/legalizer/mod.rs index b0fdac9ea..77c67fb2a 100644 --- a/cranelift/codegen/src/legalizer/mod.rs +++ b/cranelift/codegen/src/legalizer/mod.rs @@ -161,7 +161,7 @@ pub fn legalize_function(func: &mut ir::Function, cfg: &mut ControlFlowGraph, is ...
1
1
1
f668869508b61ef190a6c9ecf2f798c57132c6a5
Benjamin Bouvier
2019-10-09T15:38:29
Share constants between codegen and the meta crate;
diff --git a/cranelift/codegen/meta/src/cdsl/regs.rs b/cranelift/codegen/meta/src/cdsl/regs.rs index 920b1f542..d60835ab3 100644 --- a/cranelift/codegen/meta/src/cdsl/regs.rs +++ b/cranelift/codegen/meta/src/cdsl/regs.rs @@ -1,3 +1,4 @@ +use cranelift_codegen_shared::constants; use cranelift_entity::{entity_impl, Enti...
7
77
53
097fa0c7b11a0c1f0ef43965a872d63548e3824f
Benjamin Bouvier
2019-10-09T15:29:01
Clarify a comment in constant_hash::generate_table;
diff --git a/cranelift/codegen/shared/src/constant_hash.rs b/cranelift/codegen/shared/src/constant_hash.rs index 668dc9f65..e16d58f5b 100644 --- a/cranelift/codegen/shared/src/constant_hash.rs +++ b/cranelift/codegen/shared/src/constant_hash.rs @@ -30,7 +30,8 @@ pub fn generate_table<'cont, T, I: iter::Iterator<Item = ...
1
2
1
d404368deac765e1549d295e8a679646e2bd2182
Benjamin Bouvier
2019-10-09T14:35:33
Share constant_hash code between the meta and codegen crates;
diff --git a/cranelift/codegen/meta/src/constant_hash.rs b/cranelift/codegen/meta/src/constant_hash.rs deleted file mode 100644 index ce6214efa..000000000 --- a/cranelift/codegen/meta/src/constant_hash.rs +++ /dev/null @@ -1,55 +0,0 @@ -use std::iter; - -pub(crate) fn simple_hash(s: &str) -> usize { - let mut h: u32...
8
94
84
19444649e7f5c230a22a1a3142003ab91a8b7d86
Ujjwal Sharma
2019-10-01T08:56:35
[codegen] add to_static_str method to IntCC Add a method to_static_str to objects of type IntCC which consumes the object to basically do the opposite of IntCC::new. Refs: https://github.com/CraneStation/cranelift/pull/1081#discussion_r329042331
diff --git a/cranelift/codegen/shared/src/condcodes.rs b/cranelift/codegen/shared/src/condcodes.rs index 1171eef2f..d151c4946 100644 --- a/cranelift/codegen/shared/src/condcodes.rs +++ b/cranelift/codegen/shared/src/condcodes.rs @@ -95,10 +95,11 @@ impl CondCode for IntCC { } } -impl Display for IntCC { - fn...
1
11
4
8e593506dcfa7a06ec14ac9fa9321a6023d63f52
Dan Gohman
2019-10-09T20:34:09
Don't run the spec_testsuite tests if the submodule isn't checked out. (#409) * Don't run the spec_testsuite tests if the submodule isn't checked out. This way, if someone checks out the repository without checking out the submodules, they can still run "cargo test". Also, fix a warning in the generated test ru...
diff --git a/build.rs b/build.rs index de13239e4..c6a8b3b3b 100644 --- a/build.rs +++ b/build.rs @@ -19,17 +19,27 @@ fn main() { #[cfg(feature = "lightbeam")] "Lightbeam", ] { + writeln!(out, "#[cfg(test)]").expect("generating tests"); writeln!(out, "#[allow(non_snake_case)]").exp...
1
16
6
fd3efad7819267ece58f2b155c6ab1030da45974
Dan Gohman
2019-10-09T20:32:52
Various clippy fixes. (#403)
diff --git a/lightbeam/src/backend.rs b/lightbeam/src/backend.rs index 77d351ea2..b77fdb9d3 100644 --- a/lightbeam/src/backend.rs +++ b/lightbeam/src/backend.rs @@ -1,3 +1,5 @@ +#![allow(clippy::float_cmp)] + use crate::error::Error; use crate::microwasm::{BrTarget, Ieee32, Ieee64, SignlessType, Type, Value, F32, F64...
25
144
160
946566819959424718de199eda40bb60c87eaa70
Dan Gohman
2019-10-09T16:33:41
Fix a TODO comment. (#405) The parameter to defined_func_index is in the defined-function space, so calling func_index on it works to translate it into module space.
diff --git a/lightbeam/src/module.rs b/lightbeam/src/module.rs index 207069590..f4b787c8c 100644 --- a/lightbeam/src/module.rs +++ b/lightbeam/src/module.rs @@ -357,9 +357,8 @@ pub trait ModuleContext { fn func_index(&self, defined_func_index: u32) -> u32; fn defined_func_index(&self, func_index: u32) -> Opti...
1
2
3
c8128539d07224cf46102db8945298d9ff17301c
Benjamin Bouvier
2019-10-09T11:59:12
cleanup: remove spurious macro_use in cranelift-bforest;
diff --git a/cranelift/bforest/src/lib.rs b/cranelift/bforest/src/lib.rs index 2f5c1060a..26e5b8efc 100644 --- a/cranelift/bforest/src/lib.rs +++ b/cranelift/bforest/src/lib.rs @@ -33,7 +33,6 @@ #![no_std] #[cfg(test)] -#[macro_use] extern crate alloc; #[macro_use]
1
0
1
c6ed6b7247ef4b9d19d95a54bf15bb4a52d8fe4f
Dan Gohman
2019-10-09T13:28:47
"std" builds need to enable the "std" feature in cranelift-codegen.
diff --git a/cranelift/preopt/Cargo.toml b/cranelift/preopt/Cargo.toml index 5d0d1ebd3..3f8c87be3 100644 --- a/cranelift/preopt/Cargo.toml +++ b/cranelift/preopt/Cargo.toml @@ -18,6 +18,11 @@ cranelift-entity = { path = "../cranelift-entity", version = "0.45.0" } # cranelift currently supports. # rustc_apfloat = { ve...
1
5
0
13676cafd1dbee3bff3cd0879f799e8666969572
julian-seward1
2019-10-08T16:13:35
RedundantReloadRemover::run: use cached state rather than allocating it new for each function. (#1118) RedundantReloadRemover participates in the state-recycling machinery implemented in cranelift-codegen/src/context.rs, whose goal it is to cache per-pass state so it can be used for compilation of multiple functions...
diff --git a/cranelift/codegen/src/redundant_reload_remover.rs b/cranelift/codegen/src/redundant_reload_remover.rs index 11f13f525..b1928f03b 100644 --- a/cranelift/codegen/src/redundant_reload_remover.rs +++ b/cranelift/codegen/src/redundant_reload_remover.rs @@ -887,7 +887,7 @@ impl RedundantReloadRemover { ...
1
1
1
292323229c9d27948a49cf2bc8c3195605131534
Dan Gohman
2019-10-03T19:45:27
Improve the workaround for what is now wabt issue #59. wabt's ScriptParser doesn't appear to handle paths containing directories, so just use basenames for now.
diff --git a/wasmtime-wast/src/wast.rs b/wasmtime-wast/src/wast.rs index 76fe18ae9..8616bfca3 100644 --- a/wasmtime-wast/src/wast.rs +++ b/wasmtime-wast/src/wast.rs @@ -198,7 +198,15 @@ impl WastContext { /// Run a wast script from a byte buffer. pub fn run_buffer(&mut self, filename: &str, wast: &[u8]) -> Re...
1
10
2
6ef46e0497e6bdd8bd5262052acbf1dacd26a1e2
Dan Gohman
2019-10-05T01:12:06
Use the Lightbeam cargo feature.
diff --git a/src/bin/wasm2obj.rs b/src/bin/wasm2obj.rs index b3b64bf95..6b8bd8287 100644 --- a/src/bin/wasm2obj.rs +++ b/src/bin/wasm2obj.rs @@ -51,6 +51,7 @@ use std::str::FromStr; use target_lexicon::Triple; use wasmtime::pick_compilation_strategy; use wasmtime_debug::{emit_debugsections, read_debuginfo}; +#[cfg(f...
1
1
0
692bb272090a23b28dda014d681dbb4dc4932730
Marcin Mielniczuk
2019-10-05T01:10:30
Correct the clippy::use_self lint where possible. (#114)
diff --git a/src/error.rs b/src/error.rs index 6b64dd847..723e8a0d8 100644 --- a/src/error.rs +++ b/src/error.rs @@ -1,3 +1,5 @@ +// Due to https://github.com/rust-lang/rust/issues/64247 +#![allow(clippy::use_self)] use crate::host; use failure::Fail; use std::convert::Infallible; diff --git a/src/fdentry.rs b/src/f...
5
17
18
fb2a89a1b10d3a266c00aed4ecb7eb6e7ff6967f
Dan Gohman
2019-10-05T00:36:14
Fix compilation error by bringing in Lightbeam.
diff --git a/src/bin/wasm2obj.rs b/src/bin/wasm2obj.rs index 7300771f4..b3b64bf95 100644 --- a/src/bin/wasm2obj.rs +++ b/src/bin/wasm2obj.rs @@ -51,6 +51,7 @@ use std::str::FromStr; use target_lexicon::Triple; use wasmtime::pick_compilation_strategy; use wasmtime_debug::{emit_debugsections, read_debuginfo}; +use was...
1
1
0
5ccdf13b1180b1dbf5d7710b73bc1f38cacf8dce
Dan Gohman
2019-10-05T00:02:31
Rename --always-cranelift to --cranelift. Also, enable use of Lightbeam in wasm2obj.
diff --git a/build.rs b/build.rs index d883e3961..9697d9903 100644 --- a/build.rs +++ b/build.rs @@ -15,9 +15,9 @@ fn main() { .expect("error generating test source file"); for strategy in &[ - "AlwaysCranelift", + "Cranelift", #[cfg(feature = "lightbeam")] - "AlwaysLightbe...
7
58
40
daa3c3aeefc2633f563c2f485b13fee679e355e4
Jakub Konka
2019-10-03T09:12:31
Update wasi-common version
diff --git a/Cargo.toml b/Cargo.toml index 08c11f417..6f5a04f27 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -25,7 +25,7 @@ wasmtime-obj = { path = "wasmtime-obj" } wasmtime-wast = { path = "wasmtime-wast" } wasmtime-wasi = { path = "wasmtime-wasi" } wasmtime-wasi-c = { path = "wasmtime-wasi-c", optional = true } -wa...
3
3
3
a6af10725709d1de90680681987936145ec825da
Nick Fitzgerald
2019-10-03T19:41:53
deps: bump wasmparser dependency to 0.39.2 (#1112) This has a bug fix for Wasm multi-value blocks that is necessary to getting the spec tests passing.
diff --git a/cranelift/wasm/Cargo.toml b/cranelift/wasm/Cargo.toml index c1e4bdd80..81266bd22 100644 --- a/cranelift/wasm/Cargo.toml +++ b/cranelift/wasm/Cargo.toml @@ -11,7 +11,7 @@ keywords = ["webassembly", "wasm"] edition = "2018" [dependencies] -wasmparser = { version = "0.39.1", default-features = false } +wa...
1
1
1
da59c95f0cda22bef1517615b8ded63c1d020919
Jakub Konka
2019-10-02T20:10:15
Update dependencies and use Once::new() instead of ONCE_INIT
diff --git a/Cargo.toml b/Cargo.toml index f7a17658d..f7215de0f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -27,11 +27,11 @@ winx = { path = "winx" } winapi = "0.3" [dev-dependencies] -wasmtime-runtime = { git = "https://github.com/cranestation/wasmtime", rev = "042c877" } -wasmtime-environ = { git = "https://githu...
2
7
7
b3cf7f911ba901b7a5b2268e31fb6af8725feb5b
Nick Fitzgerald
2019-10-02T22:41:43
clif-util: Make the `-t` flag work with the `wasm` subcommand (#1105) * clif-util: Make the `-t` flag work with the `wasm` subcommand The presence of the flag was checked in the code, so it was essentially already supported, but it was not properly configured when constructing the CLI arguments parser. * clif-...
diff --git a/cranelift/src/clif-util.rs b/cranelift/src/clif-util.rs index 676e9d334..0c6110f02 100755 --- a/cranelift/src/clif-util.rs +++ b/cranelift/src/clif-util.rs @@ -119,6 +119,18 @@ fn add_enable_multi_value<'a>() -> clap::Arg<'a, 'a> { .help("Enable WASM's multi-value support") } +fn add_just_decod...
1
15
11
1017cbbf6332543e6aef60cd82ec9315d501206a
Dan Gohman
2019-10-02T21:27:21
Update the compile fuzzer for Lightbeam changes.
diff --git a/fuzz/fuzz_targets/compile.rs b/fuzz/fuzz_targets/compile.rs index c0483f7c5..daf06c656 100644 --- a/fuzz/fuzz_targets/compile.rs +++ b/fuzz/fuzz_targets/compile.rs @@ -13,10 +13,10 @@ use std::cell::RefCell; use std::collections::HashMap; use std::rc::Rc; use wasmparser::validate; -use wasmtime_jit::{Co...
1
28
7
8d89c3b4796fd6ca4b1e3d2661772f8111ac63b2
Dan Gohman
2019-10-02T20:59:49
Add options to wasmtime and wasm2obj to pick compilation strategy.
diff --git a/src/bin/wasm2obj.rs b/src/bin/wasm2obj.rs index 768101a2c..c79663675 100644 --- a/src/bin/wasm2obj.rs +++ b/src/bin/wasm2obj.rs @@ -63,7 +63,7 @@ The translation is dependent on the environment chosen. The default is a dummy environment that produces placeholder values. Usage: - wasm2obj [--target T...
6
72
24
d4353f03cb63c6e6e5e08f26895a393528154386
Dan Gohman
2019-10-02T20:42:26
Don't check `assert_trap` tests when Lightbeam is enabled. Lightbeam doesn't yet produce trap metadata, so it can't yet match the expected `assert_trap` messages. Disable them for now.
diff --git a/Cargo.toml b/Cargo.toml index 08c11f417..4b9cac2e8 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -52,5 +52,5 @@ members = [ [features] # Enable all supported architectures by default. default = ["cranelift-codegen/all-arch"] -lightbeam = ["wasmtime-environ/lightbeam", "wasmtime-jit/lightbeam"] +lightbeam ...
5
12
25
7092499c10ddfcb04ff285cdb6c79b9162600dff
Dan Gohman
2019-10-02T19:52:44
Update wasmtime-rust for new API.
diff --git a/misc/wasmtime-rust/macro/src/lib.rs b/misc/wasmtime-rust/macro/src/lib.rs index 0cdce6d91..dd9a9f945 100644 --- a/misc/wasmtime-rust/macro/src/lib.rs +++ b/misc/wasmtime-rust/macro/src/lib.rs @@ -56,7 +56,10 @@ fn generate_load(item: &syn::ItemTrait) -> syn::Result<TokenStream> { isa_build...
1
4
1
c43803b19c5d5e96127231520c3d1db36f09cab4
Dan Gohman
2019-10-02T19:32:31
Update dependencies.
diff --git a/lightbeam/Cargo.toml b/lightbeam/Cargo.toml index e92ab9fe0..1113ee61d 100644 --- a/lightbeam/Cargo.toml +++ b/lightbeam/Cargo.toml @@ -11,8 +11,8 @@ edition = "2018" [dependencies] smallvec = "0.6" -dynasm = "0.3" -dynasmrt = "0.3" +dynasm = "0.5.1" +dynasmrt = "0.5.1" wasmparser = "0.39.1" memoffse...
3
6
5
5bf2fc0ffacb4379b509f7ac922fedc8a3e5f2c5
Dan Gohman
2019-10-02T19:06:00
Don't enable Lightbeam tests if Lightbeam isn't enabled.
diff --git a/build.rs b/build.rs index 1debf375c..50c38277f 100644 --- a/build.rs +++ b/build.rs @@ -14,7 +14,11 @@ fn main() { let mut out = File::create(out_dir.join("wast_testsuite_tests.rs")) .expect("error generating test source file"); - for strategy in &["AlwaysCranelift", "AlwaysLightbeam"] {...
2
8
1
65b8afabe686e46f7b305af427f1f113a0dddb27
Dan Gohman
2019-10-02T18:54:06
Make use of Lightbeam configurable. This adds a `--always-lightbeam` option as well as an `--always-cranelift` option, to allow the compilation strategy to be selected via the command-line. This also enables regular testing for Lightbeam.
diff --git a/build.rs b/build.rs index 56cd2fb8a..1debf375c 100644 --- a/build.rs +++ b/build.rs @@ -14,12 +14,24 @@ fn main() { let mut out = File::create(out_dir.join("wast_testsuite_tests.rs")) .expect("error generating test source file"); - test_directory(&mut out, "misc_testsuite").expect("gener...
9
162
59
f9d802fb1dfad597af98767cdfe7e24f26dd0ebb
Dan Gohman
2019-10-02T18:22:40
Format with rustfmt.
diff --git a/cranelift/bforest/src/map.rs b/cranelift/bforest/src/map.rs index 7d7e45662..79ac018a9 100644 --- a/cranelift/bforest/src/map.rs +++ b/cranelift/bforest/src/map.rs @@ -3,10 +3,10 @@ use super::{Comparator, Forest, Node, NodeData, NodePool, Path, INNER_SIZE}; use crate::packed_option::PackedOption; #[cfg...
1
2
2
277d9810416762088b28f0a8950f90c37f192df1
Dan Gohman
2019-10-02T18:13:33
Rewrite another `std::string::String` to `alloc`.
diff --git a/cranelift/bforest/src/map.rs b/cranelift/bforest/src/map.rs index fb7d4d9dd..7d7e45662 100644 --- a/cranelift/bforest/src/map.rs +++ b/cranelift/bforest/src/map.rs @@ -6,7 +6,7 @@ use crate::packed_option::PackedOption; use core::fmt; use core::marker::PhantomData; #[cfg(test)] -use std::string::String;...
1
1
1
9037e7a6012788e7117842baf93a6ca32640cc96
bjorn3
2019-09-28T13:59:08
Remove std feature from cranelift-preopt
diff --git a/cranelift/preopt/Cargo.toml b/cranelift/preopt/Cargo.toml index c18188cf7..6dc55e143 100644 --- a/cranelift/preopt/Cargo.toml +++ b/cranelift/preopt/Cargo.toml @@ -18,11 +18,6 @@ cranelift-entity = { path = "../cranelift-entity", version = "0.44.0" } # cranelift currently supports. # rustc_apfloat = { ve...
2
0
12
1a99ac6b4a378bac654cffb0061c96a3b5f2254a
bjorn3
2019-09-28T13:57:43
Always use extern crate std in cranelift-frontend
diff --git a/cranelift/frontend/src/frontend.rs b/cranelift/frontend/src/frontend.rs index 620407161..15488f7c2 100644 --- a/cranelift/frontend/src/frontend.rs +++ b/cranelift/frontend/src/frontend.rs @@ -13,7 +13,7 @@ use cranelift_codegen::ir::{ }; use cranelift_codegen::isa::{TargetFrontendConfig, TargetIsa}; use...
4
7
8
74556d45ae9558cf5a7097bb8839351dcda0d4fc
bjorn3
2019-09-28T13:55:07
Remove std feature from cranelift-codegen-meta
diff --git a/cranelift/codegen/Cargo.toml b/cranelift/codegen/Cargo.toml index 2739160aa..7281ad309 100644 --- a/cranelift/codegen/Cargo.toml +++ b/cranelift/codegen/Cargo.toml @@ -29,7 +29,7 @@ smallvec = { version = "0.6.10" } # accomodated in `tests`. [build-dependencies] -cranelift-codegen-meta = { path = "meta...
2
3
12
10e226f9ff67daea9d948573821cb4f8492f1402
bjorn3
2019-09-28T13:52:23
Always use extern crate std in cranelift-codegen
diff --git a/cranelift/codegen/src/abi.rs b/cranelift/codegen/src/abi.rs index 4c0b8d4db..8564fd5a2 100644 --- a/cranelift/codegen/src/abi.rs +++ b/cranelift/codegen/src/abi.rs @@ -5,7 +5,7 @@ use crate::ir::{AbiParam, ArgumentExtension, ArgumentLoc, Type}; use core::cmp::Ordering; -use std::vec::Vec; +use alloc::v...
63
89
90
a114423d0a649079586d8081eb854176df9e7fd9
bjorn3
2019-09-28T13:46:03
Remove std feature from cranelift-entity
diff --git a/cranelift/codegen/Cargo.toml b/cranelift/codegen/Cargo.toml index dae5e033c..2739160aa 100644 --- a/cranelift/codegen/Cargo.toml +++ b/cranelift/codegen/Cargo.toml @@ -14,7 +14,7 @@ edition = "2018" [dependencies] cranelift-codegen-shared = { path = "./shared", version = "0.44.0" } -cranelift-entity = ...
13
20
32
d25e611946cd14587b16a710e72d3f8285dff493
bjorn3
2019-09-28T13:39:58
Remove std feature from cranelift-bforest
diff --git a/cranelift/bforest/Cargo.toml b/cranelift/bforest/Cargo.toml index 960827da5..4dc95212e 100644 --- a/cranelift/bforest/Cargo.toml +++ b/cranelift/bforest/Cargo.toml @@ -14,11 +14,6 @@ edition = "2018" [dependencies] cranelift-entity = { path = "../cranelift-entity", version = "0.44.0", default-features = ...
7
10
22
8c524815c36cdc5ab45694196692517c36d25f9f
Dan Gohman
2019-10-02T18:00:28
Update dependencies.
diff --git a/lightbeam/Cargo.toml b/lightbeam/Cargo.toml index 4f6b1b16b..e92ab9fe0 100644 --- a/lightbeam/Cargo.toml +++ b/lightbeam/Cargo.toml @@ -13,10 +13,10 @@ edition = "2018" smallvec = "0.6" dynasm = "0.3" dynasmrt = "0.3" -wasmparser = "0.32" -memoffset = "0.2" +wasmparser = "0.39.1" +memoffset = "0.5.1" i...
2
11
7
8d52e389f8b548b8e329f11505d2cea716235c65
Dan Gohman
2019-10-02T17:10:32
Update Lightbeam for various API changes.
diff --git a/lightbeam/Cargo.toml b/lightbeam/Cargo.toml index 455340750..4f6b1b16b 100644 --- a/lightbeam/Cargo.toml +++ b/lightbeam/Cargo.toml @@ -22,7 +22,7 @@ failure_derive = "0.1.3" cranelift-codegen = "0.44" multi_mut = "0.1" either = "1.5" -wabt = "0.7" +wabt = "0.9.2" lazy_static = "1.2" quickcheck = "0.7...
3
28
6
cb38b481568e3030ad5be5e49c21cf688884028a
Peter Huene
2019-10-02T12:54:36
Fix memory leaks in extern conversion functions in C API. (#395) This fixes the memory leaks in the following functions which should not be returning "owned" pointers: * `wasm_extern_as_func` * `wasm_func_as_extern` * `wasm_extern_as_global` * `wasm_global_as_extern` * `wasm_extern_as_memory` * `wasm_extern_a...
diff --git a/wasmtime-api/src/wasm.rs b/wasmtime-api/src/wasm.rs index 6e7be7cfd..049dccfe0 100644 --- a/wasmtime-api/src/wasm.rs +++ b/wasmtime-api/src/wasm.rs @@ -343,6 +343,7 @@ pub struct wasm_shared_module_t { #[derive(Clone)] pub struct wasm_func_t { func: HostRef<Func>, + ext: Option<Box<wasm_extern_t>...
1
119
37
dadfbcd32b79739ae8e8a5a0a1228d2a3de852bb
Erin Power
2019-09-23T15:55:49
Re-export ReplaceBuilder ReplaceBuilder is available in the public API through `DataFlowGraph::replace`, however it's documentation is not available through rustdoc as the type isn't publicly importable.
diff --git a/cranelift/codegen/src/ir/mod.rs b/cranelift/codegen/src/ir/mod.rs index 2ee589f6a..9c03d569d 100644 --- a/cranelift/codegen/src/ir/mod.rs +++ b/cranelift/codegen/src/ir/mod.rs @@ -26,7 +26,9 @@ mod valueloc; #[cfg(feature = "enable-serde")] use serde::{Deserialize, Serialize}; -pub use crate::ir::build...
1
3
1
0d50462a93671ae75561cdb491d2e0db01d7ab19
Benjamin Bouvier
2019-10-01T08:18:11
Fixes #1091: Use match statements instead of HashMaps in x86 encodings;
diff --git a/cranelift/codegen/meta/src/isa/x86/encodings.rs b/cranelift/codegen/meta/src/isa/x86/encodings.rs index 1e9294048..da08462e9 100644 --- a/cranelift/codegen/meta/src/isa/x86/encodings.rs +++ b/cranelift/codegen/meta/src/isa/x86/encodings.rs @@ -1759,24 +1759,22 @@ pub(crate) fn define( } // SIMD...
1
51
53
5096d7cf92c768a7e17e1d88241f610117915fab
Johnnie Birch
2019-09-30T20:31:51
Updates Cranelift Codegen dependence to 0.44 In trying to build the lightbeam feature in wasmtime there are compile errors mostly related to outdated or missing trait definitions. This patch moves the current cranelift codegen dependence to 0.44 in support of that, though other changes are still needed in wasmtime to ...
diff --git a/Cargo.toml b/Cargo.toml index 9c7ebe476..329ed4867 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -19,7 +19,7 @@ itertools = "0.8" capstone = "0.5.0" failure = "0.1.3" failure_derive = "0.1.3" -cranelift-codegen = "0.33" +cranelift-codegen = "0.44" multi_mut = "0.1" either = "1.5" wabt = "0.7" diff --gi...
2
5
1
c932f9b2b5745f3bc049306ddea49ec691a5c941
Andrew Brown
2019-09-18T20:45:26
Add parsing of 16-bit signed integers
diff --git a/cranelift/codegen/src/ir/immediates.rs b/cranelift/codegen/src/ir/immediates.rs index 408fe17cf..eb6dfad34 100644 --- a/cranelift/codegen/src/ir/immediates.rs +++ b/cranelift/codegen/src/ir/immediates.rs @@ -22,6 +22,12 @@ impl IntoBytes for u8 { } } +impl IntoBytes for i16 { + fn into_bytes(sel...
2
21
1
6b2f3ebf7c7b4894a79e3ab58bbf3651ea7a798e
Dan Gohman
2019-09-30T18:27:53
Begin sketching out a new high-level `fs` API. (#91) * Begin sketching out a new high-level `fs` API. This is a very preliminary sketch of #83. It doesn't even compile yet, but it shows a possible high-level structure of such an API. * Stub out more functionality. * Switch from a lazy_static WasiCtx to a bor...
diff --git a/src/fs/dir.rs b/src/fs/dir.rs new file mode 100644 index 000000000..806628fbe --- /dev/null +++ b/src/fs/dir.rs @@ -0,0 +1,216 @@ +use crate::fs::{error::wasi_errno_to_io_error, File, OpenOptions, ReadDir}; +use crate::{host, hostcalls, WasiCtx}; +#[cfg(unix)] +use std::os::unix::ffi::OsStrExt; +use std::{...
12
1,058
0
a679412dd0132b22b6dd8864f1ffb9fb15d59b3e
Dan Gohman
2019-09-30T17:22:11
Sync with lucet-wasi (#106) * Open /dev/null for writing as well as reading. Port this fix to wasi-common: https://github.com/fastly/lucet/commit/b905c4448308d89fe600f314c14932644985f877 * Remove all remaining uses of `std::mem::uninitialized`. Patch inspired by: https://github.com/fastly/lucet/commit/2...
diff --git a/src/error.rs b/src/error.rs index d8d50cb67..6b64dd847 100644 --- a/src/error.rs +++ b/src/error.rs @@ -87,8 +87,8 @@ pub enum WasiError { } impl WasiError { - pub fn as_raw_errno(&self) -> host::__wasi_errno_t { - *self as host::__wasi_errno_t + pub fn as_raw_errno(self) -> host::__wasi_e...
9
46
29
e1b9c01d94485fa63d90920a10f49a3e9499f863
Jean-Bapiste Lepesme
2019-09-29T17:37:33
Fix opt_level setting passed to cranelift With https://github.com/CraneStation/cranelift/commit/92a19e9398a0413ac598537c3dbea3a3699f45a1 the optimisation levels of cranelift were renamed, without this change trying to use the -o flag on wasmtime runtime results in "error: Unexpected value for a setting, expected any a...
diff --git a/src/bin/wasmtime.rs b/src/bin/wasmtime.rs index e16724e9b..10e362ea9 100644 --- a/src/bin/wasmtime.rs +++ b/src/bin/wasmtime.rs @@ -278,7 +278,7 @@ fn rmain() -> Result<(), Error> { // Enable optimization if requested. if args.flag_optimize { - flag_builder.set("opt_level", "best")?; + ...
1
1
1
4e3cb25983552a6d18514516d0be5b08b03e77d5
Benjamin Bouvier
2019-09-13T16:58:50
Use a sorted array for (Ebb, Inst) interval again (fixes #1084);
diff --git a/cranelift/codegen/src/regalloc/coalescing.rs b/cranelift/codegen/src/regalloc/coalescing.rs index 8a1f1d81b..b27a105d6 100644 --- a/cranelift/codegen/src/regalloc/coalescing.rs +++ b/cranelift/codegen/src/regalloc/coalescing.rs @@ -196,12 +196,7 @@ impl<'a> Context<'a> { // to be live at the u...
10
212
250
79784dfaf66f0427ee8258020ba6546e00c93290
John Gallagher
2019-09-30T13:38:03
Change signature of all() function
diff --git a/cranelift/codegen/meta/src/isa/mod.rs b/cranelift/codegen/meta/src/isa/mod.rs index 6c5ba1388..3b90f7fe1 100644 --- a/cranelift/codegen/meta/src/isa/mod.rs +++ b/cranelift/codegen/meta/src/isa/mod.rs @@ -38,8 +38,8 @@ impl Isa { } /// Returns all supported isa targets. - pub fn all() -> [Isa...
1
2
2
9f3c5b967e77156ed2acd4848b893050790b3bea
Ujjwal Sharma
2019-09-25T22:08:38
[codegen] add documentation for overflow Add documentation to the icmp instruction text for both signed and unsigned overflow, making it very clear why unsigned overflow is complicated and where to find it.
diff --git a/cranelift/codegen/meta/src/shared/instructions.rs b/cranelift/codegen/meta/src/shared/instructions.rs index 679ee1a2c..1f0e629a2 100644 --- a/cranelift/codegen/meta/src/shared/instructions.rs +++ b/cranelift/codegen/meta/src/shared/instructions.rs @@ -1586,8 +1586,6 @@ pub(crate) fn define( let x = &o...
1
15
12
e45ef24d3bf5bccaf456a15cea1140e10595bdee
Andrew Brown
2019-09-25T19:40:27
Convert SIMD load and store to their respective CLIF instructions
diff --git a/cranelift/wasm/src/code_translator.rs b/cranelift/wasm/src/code_translator.rs index 0bf7f4b0b..3c004e363 100644 --- a/cranelift/wasm/src/code_translator.rs +++ b/cranelift/wasm/src/code_translator.rs @@ -500,6 +500,11 @@ pub fn translate_operator<FE: FuncEnvironment + ?Sized>( } => { ...
1
11
3
406bc7895a4ec274bc21e03d1ec2b90a085a5687
Peter Huene
2019-09-27T12:50:54
Implement reading module table imports in API. (#387) This commit implements populating the table imports of a module from the API. It also allows for `anyref` in table types as per the reference types proposal.
diff --git a/wasmtime-api/src/module.rs b/wasmtime-api/src/module.rs index 4447127c7..0caed03b1 100644 --- a/wasmtime-api/src/module.rs +++ b/wasmtime-api/src/module.rs @@ -47,7 +47,9 @@ fn into_func_type(mt: wasmparser::FuncType) -> FuncType { } fn into_table_type(tt: wasmparser::TableType) -> TableType { - ass...
1
7
3
0653ae2c9c37353cb2bae2511a63f04e06c30b98
Dan Gohman
2019-09-26T05:58:36
Fix compilation errors.
diff --git a/wasmtime-wasi/src/syscalls.rs b/wasmtime-wasi/src/syscalls.rs index 7aa60d31e..0ec69904b 100644 --- a/wasmtime-wasi/src/syscalls.rs +++ b/wasmtime-wasi/src/syscalls.rs @@ -1,5 +1,5 @@ use cranelift_codegen::ir::types::{Type, I32, I64}; -use log::trace; +use log::{error, trace}; use wasi_common::{hostcall...
1
5
5
78997846638aeff23e2d6b252cb06f426a0106c7
Dan Gohman
2019-09-26T05:32:53
Replace `println` error handling. Use `panic!` and log macros for error handling instead of `println!`.
diff --git a/wasmtime-wasi-c/src/translate.rs b/wasmtime-wasi-c/src/translate.rs index ea81c4798..d3dd1007c 100644 --- a/wasmtime-wasi-c/src/translate.rs +++ b/wasmtime-wasi-c/src/translate.rs @@ -26,19 +26,19 @@ unsafe fn decode_ptr( let last = match (ptr as usize).checked_add(len - 1) { ...
2
8
8
053fb3433e9e17ae9d6248291f13ba189be7de72
Dan Gohman
2019-09-26T05:12:12
Fix compilation error.
diff --git a/src/bin/wasmtime.rs b/src/bin/wasmtime.rs index 1801a335c..e16724e9b 100644 --- a/src/bin/wasmtime.rs +++ b/src/bin/wasmtime.rs @@ -314,7 +314,7 @@ fn rmain() -> Result<(), Error> { module_registry.insert( "wasi_unstable".to_owned(), - Instance::from_handle(store.clone(), wasi)?, + ...
1
1
1
0667a2897d86e433152fdb392939bf75eb68580c
Andrew Brown
2019-09-26T21:44:44
Ignore simd_const test when glibc has a floating point parsing issue
diff --git a/build.rs b/build.rs index b746ae5df..56cd2fb8a 100644 --- a/build.rs +++ b/build.rs @@ -167,6 +167,7 @@ fn ignore(testsuite: &str, name: &str) -> bool { { return match (testsuite, name) { ("spec_testsuite", "const") => true, + ("single_file_spec_test", ...
1
1
0
68de2247bc1d56616061ffa36225a11add2392da
Andrew Brown
2019-09-25T18:49:58
Avoid errors when converting V128 for the wasm-c-api For this to work the wasm-c-api must add support for the V128 type (e.g. through __uint128_t)
diff --git a/wasmtime-api/src/wasm.rs b/wasmtime-api/src/wasm.rs index 2eec23d9e..6e7be7cfd 100644 --- a/wasmtime-api/src/wasm.rs +++ b/wasmtime-api/src/wasm.rs @@ -815,6 +815,7 @@ fn from_valtype(ty: &ValType) -> wasm_valkind_t { ValType::F64 => 3, ValType::AnyRef => 128, ValType::FuncRef =>...
1
1
0
03a9f0e4612d51202e11f3a0b03f2125dee4b35b
Andrew Brown
2019-09-06T17:56:07
Run SIMD const spec test
diff --git a/build.rs b/build.rs index 51d69911d..b746ae5df 100644 --- a/build.rs +++ b/build.rs @@ -4,7 +4,7 @@ //! to automatically run the files in parallel. use std::env; -use std::fs::{read_dir, DirEntry, File}; +use std::fs::{read_dir, File}; use std::io::{self, Write}; use std::path::{Path, PathBuf}; @@ ...
1
9
4
ce8e8662ffda48d878dbd2bdcb3201c003241914
Andrew Brown
2019-08-14T18:12:00
Enable SIMD in WAST testsuites
diff --git a/build.rs b/build.rs index eec184afb..51d69911d 100644 --- a/build.rs +++ b/build.rs @@ -55,7 +55,7 @@ fn test_directory(out: &mut File, testsuite: &str) -> io::Result<()> { )?; writeln!( out, - " use super::{{native_isa, Path, WastContext, Compiler}};" + " use super::...
2
8
3
bb244d52d549847c6ca54c7a52859e7d200b9be8
Andrew Brown
2019-08-14T17:39:33
Pass enabled features (e.g. --enable-simd) on to WABT when running WAST files
diff --git a/wasmtime-jit/src/context.rs b/wasmtime-jit/src/context.rs index 144f066e7..16891bf22 100644 --- a/wasmtime-jit/src/context.rs +++ b/wasmtime-jit/src/context.rs @@ -107,6 +107,11 @@ impl Context { Self::new(Box::new(Compiler::new(isa))) } + /// Retrieve the context features + pub fn fe...
2
43
11
fb1c473342ad0a9d7c1cfb0ab68235042ca50602
Andrew Brown
2019-08-14T23:14:53
Alter invocation of functions to use 16-byte invocation arguments
diff --git a/wasmtime-environ/src/vmoffsets.rs b/wasmtime-environ/src/vmoffsets.rs index 100ce9cbe..070a73966 100644 --- a/wasmtime-environ/src/vmoffsets.rs +++ b/wasmtime-environ/src/vmoffsets.rs @@ -22,6 +22,11 @@ fn cast_to_u32(sz: usize) -> u32 { } } +/// Align an offset used in this module to a specific by...
4
83
15
5bd422b42985bdc4d6e7cf18483822f5ade01057
Andrew Brown
2019-08-14T17:12:38
Add V128 type
diff --git a/wasmtime-api/src/module.rs b/wasmtime-api/src/module.rs index 436aa8a14..4447127c7 100644 --- a/wasmtime-api/src/module.rs +++ b/wasmtime-api/src/module.rs @@ -32,6 +32,7 @@ fn into_valtype(ty: &wasmparser::Type) -> ValType { I64 => ValType::I64, F32 => ValType::F32, F64 => ValTy...
5
31
3
290b51a5f6f0f243422a171322fa32935d7402c5
Andrew Brown
2019-09-06T16:55:20
Update wabt and spec test suite Update wabt (see issue in https://github.com/pepyakin/wabt-rs/pull/56). Due to changes in wabt, the spec tests are updated as well.
diff --git a/Cargo.toml b/Cargo.toml index 6ad3f8b66..08c11f417 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -33,7 +33,7 @@ failure = "0.1" target-lexicon = { version = "0.8.1", default-features = false } pretty_env_logger = "0.3.0" file-per-thread-logger = "0.1.1" -wabt = "0.9" +wabt = "0.9.2" libc = "0.2.60" errn...
3
3
3
86142f2e94cbcd89719e77c088e1c99f69604f2d
Dan Gohman
2019-09-26T20:44:43
Use `r#` to escape strings which may be rust keywords. (#379) This is a minor simplification, replacing a hardcoded list of keywords.
diff --git a/build.rs b/build.rs index 8acbdfb85..eec184afb 100644 --- a/build.rs +++ b/build.rs @@ -76,11 +76,7 @@ fn write_testsuite_tests(out: &mut File, dir_entry: DirEntry, testsuite: &str) - if ignore(testsuite, stemstr) { writeln!(out, " #[ignore]")?; } - writeln!( - out, - ...
1
1
17
bbd7e91d1c524b7d7f5b88c4e89cffe03c70b3ef
Artur Jamro
2019-09-26T20:30:20
Reformat code with new rustfmt (#28)
diff --git a/src/microwasm.rs b/src/microwasm.rs index 42d00e8ab..cf3002f9a 100644 --- a/src/microwasm.rs +++ b/src/microwasm.rs @@ -1174,12 +1174,8 @@ where sig!((ty) -> (ty)) } - WasmOperator::GetGlobal { global_index } => { - sig!(() -> (self.module.global_ty...
1
4
12
10845134f7dfd6e41a4f71d5bd03a1217a3e31f1
Dan Gohman
2019-09-26T05:04:41
Update to latest walrus, wasmparser, and wasm-webidl-bindings.
diff --git a/Cargo.toml b/Cargo.toml index 01bfaf58a..6ad3f8b66 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -37,7 +37,7 @@ wabt = "0.9" libc = "0.2.60" errno = "0.2.4" rayon = "1.1" -wasm-webidl-bindings = "0.4" +wasm-webidl-bindings = "0.5" # build.rs tests whether to enable a workaround for the libc strtof func...
8
11
16
622a630acd6f4f62cb69cf2e330672fff52c7056
Peter Huene
2019-09-26T18:57:33
Implement wasm_module_imports. (#384) This commit implements `wasm_module_imports` and a few related APIs so that import information can be read about a module.
diff --git a/wasmtime-api/src/wasm.rs b/wasmtime-api/src/wasm.rs index 3c86d615a..2eec23d9e 100644 --- a/wasmtime-api/src/wasm.rs +++ b/wasmtime-api/src/wasm.rs @@ -250,6 +250,8 @@ pub type wasm_externkind_t = u8; #[derive(Clone)] pub struct wasm_importtype_t { ty: ImportType, + module_cache: Option<wasm_name...
1
72
14
286d2515f9740e3d3b42e3dca31b81e87a11933b
Artur Jamro
2019-09-25T17:34:37
Check trap code in test suite assertions
diff --git a/src/bin/wasm2obj.rs b/src/bin/wasm2obj.rs index 03f830052..768101a2c 100644 --- a/src/bin/wasm2obj.rs +++ b/src/bin/wasm2obj.rs @@ -203,6 +203,11 @@ fn handle_module( }), }; let mut flag_builder = settings::builder(); + + // There are two possible traps for division, and this way + ...
7
66
20
b0fe01397b4a7fc220c94a797ce747917b3418ba
Yury Delendik
2019-09-26T18:10:41
Use HOST call convension in Func signature (#383)
diff --git a/wasmtime-api/src/types.rs b/wasmtime-api/src/types.rs index 93b13e80d..972521342 100644 --- a/wasmtime-api/src/types.rs +++ b/wasmtime-api/src/types.rs @@ -137,10 +137,11 @@ pub struct FuncType { impl FuncType { pub fn new(params: Box<[ValType]>, results: Box<[ValType]>) -> FuncType { - let ...
1
6
5
a1f6457e8af856ff0e39735bbd2544cc3c3edaf2
Joshua Nelson
2019-09-26T16:00:03
Allow building without std (#1069) Closes https://github.com/CraneStation/cranelift/issues/1067
diff --git a/cranelift/codegen/Cargo.toml b/cranelift/codegen/Cargo.toml index eb6a1094c..e38f06d60 100644 --- a/cranelift/codegen/Cargo.toml +++ b/cranelift/codegen/Cargo.toml @@ -18,7 +18,7 @@ cranelift-entity = { path = "../cranelift-entity", version = "0.44.0", default-f cranelift-bforest = { path = "../cranelift-...
18
43
31
b41e918ec3b59e56bf840d1bf7461bb054663db0
Yury Delendik
2019-09-25T22:01:00
[wasmtime-api] Fixes wasm_exporttype_type leak
diff --git a/wasmtime-api/src/wasm.rs b/wasmtime-api/src/wasm.rs index 9f56eaefe..3c86d615a 100644 --- a/wasmtime-api/src/wasm.rs +++ b/wasmtime-api/src/wasm.rs @@ -259,6 +259,7 @@ declare_vec!(wasm_importtype_vec_t, *mut wasm_importtype_t); pub struct wasm_exporttype_t { ty: ExportType, name_cache: Option<w...
1
10
5
e2efa6318b651ba853ec251ab7c315a266a046ec
Dan Gohman
2019-09-07T04:39:18
Remove `feature(alloc)` declarations which are no longer needed.
diff --git a/wasmtime-environ/src/lib.rs b/wasmtime-environ/src/lib.rs index 104f491e2..cd9db5063 100644 --- a/wasmtime-environ/src/lib.rs +++ b/wasmtime-environ/src/lib.rs @@ -25,7 +25,6 @@ ) )] #![no_std] -#![cfg_attr(not(feature = "std"), feature(alloc))] #[cfg(not(feature = "std"))] #[macro_use] diff --g...
2
0
2
d1706117e5fdbe3c8230a00e7662306dfeb20ce9
Artur Jamro
2019-09-18T23:33:21
Enable cache system by default
diff --git a/src/bin/wasm2obj.rs b/src/bin/wasm2obj.rs index c53beaab6..4cba03852 100644 --- a/src/bin/wasm2obj.rs +++ b/src/bin/wasm2obj.rs @@ -63,7 +63,7 @@ The translation is dependent on the environment chosen. The default is a dummy environment that produces placeholder values. Usage: - wasm2obj [--target T...
3
16
16
d33036a3b5cec8d72419b7737167f47090da1ecf
Jakub Konka
2019-09-17T21:03:31
Fix path_rename on *nix hosts The fix contains an errno remapping in macOS case where in case when we try to rename a file into a path with a trailing slash an ENOENT is returned. In this case, if the destination does not exist, an ENOTDIR should be thrown as is thrown correctly on Linux hosts. Thus, as a fix, if an E...
diff --git a/build.rs b/build.rs index 777027b94..caf01c8fc 100644 --- a/build.rs +++ b/build.rs @@ -163,7 +163,6 @@ cfg_if::cfg_if! { fn ignore(testsuite: &str, name: &str) -> bool { if testsuite == "misc_testsuite" { match name { - "path_rename_trailing_slashe...
5
77
23
1848cc0868ef6936277832ca322ab166d81e3117
Nick Fitzgerald
2019-09-23T22:24:43
deps: Update cranelift-* to 0.43.1
diff --git a/Cargo.toml b/Cargo.toml index 9a604c68c..3b5e10417 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -11,10 +11,10 @@ edition = "2018" default-run = "wasmtime" [dependencies] -cranelift-codegen = { version = "0.41.0", features = ["enable-serde"] } -cranelift-entity = { version = "0.41.0", features = ["enable...
18
102
60
8c3072c774de3a2c419867eccc355011c83b7f47
Nick Fitzgerald
2019-09-25T19:07:54
Combine `VisibleTranslationState` and `TranslationState` (#1076) `VisibleTranslationState` was a wrapper around a `TranslationState` that was meant to public API consumers outside of this crate. However, the internal `TranslationState` and all its methods were still publicly exposed! This commit simplifies and reme...
diff --git a/cranelift/wasm/src/environ/spec.rs b/cranelift/wasm/src/environ/spec.rs index bce06e4cd..e83e675e7 100644 --- a/cranelift/wasm/src/environ/spec.rs +++ b/cranelift/wasm/src/environ/spec.rs @@ -6,7 +6,7 @@ //! //! [Wasmtime]: https://github.com/CraneStation/wasmtime -use crate::state::VisibleTranslationS...
4
42
50
46ab1b4103d21d78ac2240c7e5b20fc07ba91b4a
Benjamin Bouvier
2019-09-13T16:54:38
Liverange: use a macro to make Order comparisons simpler to read;
diff --git a/cranelift/codegen/src/regalloc/liverange.rs b/cranelift/codegen/src/regalloc/liverange.rs index 6465b9ab8..fb8fcc5ff 100644 --- a/cranelift/codegen/src/regalloc/liverange.rs +++ b/cranelift/codegen/src/regalloc/liverange.rs @@ -190,6 +190,22 @@ impl<'a, PO: ProgramOrder> bforest::Comparator<Ebb> for Cmp<'a...
1
26
16
5beb10e77a8cdd7203597ab4d1d72518482e861e
Benjamin Bouvier
2019-09-12T17:32:43
Regalloc: remove the transient LiveRangeContext data structure;
diff --git a/cranelift/codegen/src/regalloc/coalescing.rs b/cranelift/codegen/src/regalloc/coalescing.rs index 4ba19ebbf..8a1f1d81b 100644 --- a/cranelift/codegen/src/regalloc/coalescing.rs +++ b/cranelift/codegen/src/regalloc/coalescing.rs @@ -199,7 +199,8 @@ impl<'a> Context<'a> { if self.liveness[pa...
10
108
143
b9b1c842e9606c16f3dc17e28f6c80a068434634
Benjamin Bouvier
2019-09-12T12:43:31
Use LiveRange::reaches_use instead of reimplementing it in liveness checks;
diff --git a/cranelift/codegen/src/verifier/liveness.rs b/cranelift/codegen/src/verifier/liveness.rs index c396a4680..11cde21e6 100644 --- a/cranelift/codegen/src/verifier/liveness.rs +++ b/cranelift/codegen/src/verifier/liveness.rs @@ -2,13 +2,12 @@ use crate::flowgraph::{BasicBlock, ControlFlowGraph}; use crate::...
1
9
23
59f5f12c60b070445bb31c7fb79867ea13ea3783
Benjamin Bouvier
2019-09-12T12:23:12
[codegen] Rename GenLiveRange to GenericLiveRange; (to avoid confuson with Gen interpreted as Generator)
diff --git a/cranelift/codegen/src/ir/layout.rs b/cranelift/codegen/src/ir/layout.rs index 78a462857..632c03dc5 100644 --- a/cranelift/codegen/src/ir/layout.rs +++ b/cranelift/codegen/src/ir/layout.rs @@ -698,7 +698,7 @@ impl Layout { #[derive(Clone, Debug, Default)] struct InstNode { - // The Ebb containing thi...
2
19
15
b036ab77dc1f2a2f7feaf2508b90a84926f6b073
Benjamin Bouvier
2019-09-13T15:57:14
Update comment about the live range implementation details;
diff --git a/cranelift/codegen/src/regalloc/liverange.rs b/cranelift/codegen/src/regalloc/liverange.rs index 5629ea40e..b0d3c6fed 100644 --- a/cranelift/codegen/src/regalloc/liverange.rs +++ b/cranelift/codegen/src/regalloc/liverange.rs @@ -58,8 +58,16 @@ //! //! # Implementation notes //! -//! A few notes about the...
1
10
9
6e131e5347fcdc33c7ffbdaa0205a2aa29f30765
Ujjwal Sharma
2019-09-06T18:40:54
[codegen] add intcc conditions for reading carry flag Add conditions to IntCC for checking the carry flag (Carry, NotCarry). Fixes: https://github.com/CraneStation/cranelift/issues/980
diff --git a/cranelift/codegen/meta/src/shared/instructions.rs b/cranelift/codegen/meta/src/shared/instructions.rs index b52a8dafe..5461aada5 100644 --- a/cranelift/codegen/meta/src/shared/instructions.rs +++ b/cranelift/codegen/meta/src/shared/instructions.rs @@ -1586,6 +1586,7 @@ pub(crate) fn define( let x = &o...
7
44
1
1431ab5201b5affdf8b08838bed39153188f40eb
Artur Jamro
2019-09-24T16:28:40
Derive serde traits for TrapCode
diff --git a/cranelift/codegen/src/ir/trapcode.rs b/cranelift/codegen/src/ir/trapcode.rs index 273a77670..5621e1d91 100644 --- a/cranelift/codegen/src/ir/trapcode.rs +++ b/cranelift/codegen/src/ir/trapcode.rs @@ -2,11 +2,14 @@ use core::fmt::{self, Display, Formatter}; use core::str::FromStr; +#[cfg(feature = "enab...
1
3
0
636ef98024d08b5e512ea34b1c907e4fb78fd793
Andrew Brown
2019-09-23T18:22:34
Use existing `is_equal` predicate with the newly-shared condition codes This removes the `HasConditionCode(&'static str)` predicate and the associated issues with that.
diff --git a/cranelift/codegen/meta/src/cdsl/instructions.rs b/cranelift/codegen/meta/src/cdsl/instructions.rs index 0ad5c1397..178077e45 100644 --- a/cranelift/codegen/meta/src/cdsl/instructions.rs +++ b/cranelift/codegen/meta/src/cdsl/instructions.rs @@ -13,6 +13,7 @@ use crate::cdsl::operands::Operand; use crate::c...
3
6
20
694de912a5a1f6752bf0b44d5b320b359bcb1696
Nicolas B. Pierron
2019-09-16T13:50:34
Update brnz.i128 legalization to use non-extended basic blocks.
diff --git a/cranelift/codegen/meta/src/shared/legalize.rs b/cranelift/codegen/meta/src/shared/legalize.rs index 30de84a19..fef4c1e1e 100644 --- a/cranelift/codegen/meta/src/shared/legalize.rs +++ b/cranelift/codegen/meta/src/shared/legalize.rs @@ -93,6 +93,7 @@ pub(crate) fn define(insts: &InstructionGroup, imm: &Imme...
1
8
3