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
69513ee85e3ca6c3cff7facf7040c8eedaa0d896
bjorn3
2020-10-12T12:02:37
Merge CompiledFunction and CompiledData
diff --git a/cranelift/simplejit/src/backend.rs b/cranelift/simplejit/src/backend.rs index 67f775dfb..06d22dbf1 100644 --- a/cranelift/simplejit/src/backend.rs +++ b/cranelift/simplejit/src/backend.rs @@ -128,8 +128,8 @@ pub struct SimpleJITModule { libcall_names: Box<dyn Fn(ir::LibCall) -> String>, memory: S...
1
23
32
7a2a4bc9037ce6a22227296343ac13202fcd0022
bjorn3
2020-10-12T09:45:01
Add some debug derives
diff --git a/cranelift/module/src/module.rs b/cranelift/module/src/module.rs index 58ddb2aa7..3b87876c1 100644 --- a/cranelift/module/src/module.rs +++ b/cranelift/module/src/module.rs @@ -122,6 +122,7 @@ impl From<FuncOrDataId> for ir::ExternalName { } /// Information about a function which can be called. +#[deriv...
1
3
1
6b0d246b2480eca69da31a9ddcd80e2d5729acad
bjorn3
2020-10-11T14:23:43
Implement Linkage::Preemptible for simplejit
diff --git a/cranelift/simplejit/src/backend.rs b/cranelift/simplejit/src/backend.rs index 4324817ad..67f775dfb 100644 --- a/cranelift/simplejit/src/backend.rs +++ b/cranelift/simplejit/src/backend.rs @@ -218,35 +218,47 @@ impl SimpleJITProduct { } impl SimpleJITModule { - fn lookup_symbol(&self, name: &str) -> ...
1
29
21
589f4a4405f605df95852c0b06995e18a38cb643
bjorn3
2020-10-11T14:18:27
Re-introduce finalize_definitions and get_finalized_* for simplejit
diff --git a/cranelift/simplejit/src/backend.rs b/cranelift/simplejit/src/backend.rs index b5c5f1f87..4324817ad 100644 --- a/cranelift/simplejit/src/backend.rs +++ b/cranelift/simplejit/src/backend.rs @@ -252,6 +252,32 @@ impl SimpleJITModule { } } + /// Returns the address of a finalized function. +...
1
50
14
2346fe7de64bf8632d576d7154120c7ae6379111
bjorn3
2020-10-11T14:16:39
Make some things private
diff --git a/cranelift/simplejit/src/backend.rs b/cranelift/simplejit/src/backend.rs index 369561f06..b5c5f1f87 100644 --- a/cranelift/simplejit/src/backend.rs +++ b/cranelift/simplejit/src/backend.rs @@ -151,14 +151,14 @@ struct StackMapRecord { } #[derive(Clone)] -pub struct SimpleJITCompiledFunction { +struct Si...
1
8
20
cdf158cd5043ca85a002bda137d39bf1c7dafe38
Alex Crichton
2020-10-09T17:09:27
Fix enabling interrupts in fuzzers Modifying the `Config` after the gneine has been created has no effect, so be sure to flag the configuration as interruptible earlier.
diff --git a/crates/fuzzing/src/oracles.rs b/crates/fuzzing/src/oracles.rs index 7b321f0a4..d0e7fc3e8 100644 --- a/crates/fuzzing/src/oracles.rs +++ b/crates/fuzzing/src/oracles.rs @@ -66,11 +66,11 @@ pub fn instantiate(wasm: &[u8], strategy: Strategy) { pub fn instantiate_with_config(wasm: &[u8], mut config: Config, ...
1
1
1
d5d84e2ec3c36c880eacada76a7b602049ead338
Andrew Brown
2020-10-07T22:54:46
[machinst x64]: enable simd_bitwise.wast
diff --git a/build.rs b/build.rs index c7d6c3ff8..1417bf8e2 100644 --- a/build.rs +++ b/build.rs @@ -180,6 +180,7 @@ fn experimental_x64_should_panic(testsuite: &str, testname: &str, strategy: &str match (testsuite, testname) { ("simd", "simd_address") => return false, + ("simd", "simd_bitwise") ...
1
1
0
1799b0947f98f7a4933e2b6933e228044d1fbdf6
Andrew Brown
2020-10-07T22:48:25
[machinst x64]: implement packed bitselect
diff --git a/cranelift/codegen/src/isa/x64/inst/mod.rs b/cranelift/codegen/src/isa/x64/inst/mod.rs index 46373bee7..1fe0de694 100644 --- a/cranelift/codegen/src/isa/x64/inst/mod.rs +++ b/cranelift/codegen/src/isa/x64/inst/mod.rs @@ -1105,33 +1105,6 @@ impl Inst { } } - /// Choose which instruction to...
2
80
27
95f0e96e6233d780cb9f42d183c4b1954bea9063
Andrew Brown
2020-10-07T20:52:35
[machinst x64]: implement packed not This begins to use `Inst` helper functions as discussed in #2252.
diff --git a/cranelift/codegen/src/isa/x64/inst/mod.rs b/cranelift/codegen/src/isa/x64/inst/mod.rs index ec5861577..46373bee7 100644 --- a/cranelift/codegen/src/isa/x64/inst/mod.rs +++ b/cranelift/codegen/src/isa/x64/inst/mod.rs @@ -1105,6 +1105,33 @@ impl Inst { } } + /// Choose which instruction to...
2
35
5
3c55523d40ff4150cc54ad4830ee84fffad07a42
Andrew Brown
2020-10-07T20:34:18
[machinst x64]: implement packed and, and_not, xor, or
diff --git a/cranelift/codegen/src/isa/x64/inst/args.rs b/cranelift/codegen/src/isa/x64/inst/args.rs index 2d47d71a5..3a2dd0de0 100644 --- a/cranelift/codegen/src/isa/x64/inst/args.rs +++ b/cranelift/codegen/src/isa/x64/inst/args.rs @@ -413,6 +413,8 @@ pub enum SseOpcode { Paddsw, Paddusb, Paddusw, + ...
3
41
1
116acb8dcd2eae56bd4f928cfe41e34d9c096e1e
Benjamin Bouvier
2020-10-07T12:05:35
machinst x64: emit nop of variable sizes;
diff --git a/cranelift/codegen/src/isa/x64/inst/emit.rs b/cranelift/codegen/src/isa/x64/inst/emit.rs index e94c10083..bd7b9d442 100644 --- a/cranelift/codegen/src/isa/x64/inst/emit.rs +++ b/cranelift/codegen/src/isa/x64/inst/emit.rs @@ -2720,10 +2720,85 @@ pub(crate) fn emit( } Inst::Nop { len } => ...
2
80
5
a470f1e0cd57578f2f8f5bd3979ea91583fd26d2
Benjamin Bouvier
2020-10-07T11:31:29
machinst x64: remove dead code and allow(dead_code) annotation; The BranchTarget is always used as a label, so just use a plain MachLabel in this case.
diff --git a/cranelift/codegen/src/isa/x64/abi.rs b/cranelift/codegen/src/isa/x64/abi.rs index a253a92ba..bbbabc5ff 100644 --- a/cranelift/codegen/src/isa/x64/abi.rs +++ b/cranelift/codegen/src/isa/x64/abi.rs @@ -276,11 +276,11 @@ impl ABIMachineSpec for X64ABIMachineSpec { } fn gen_ret() -> Self::I { - ...
7
90
165
13c6bdd9bab2e8aaacad420a2f90b87624b8e6f3
Pat Hickey
2020-10-08T03:06:58
cranelift-module: add iterator methods to ModuleDeclarations The predecessor interface made it possible to iterate across all function and data declarations. This is still useful and easy enough to provide.
diff --git a/cranelift/module/src/module.rs b/cranelift/module/src/module.rs index 26704ae5e..58ddb2aa7 100644 --- a/cranelift/module/src/module.rs +++ b/cranelift/module/src/module.rs @@ -210,6 +210,11 @@ impl ModuleDeclarations { self.names.get(name).copied() } + /// Get an iterator of all function...
1
10
0
3778fa025cc00e0d315333025991c3fdba595ceb
Andrew Brown
2020-10-07T16:57:51
Switch DataValue to use Ieee32/Ieee64 As discussed in #2251, in order to be very confident that NaN signaling bits are correctly handled by the compiler, this switches `DataValue` to use Cranelift's `Ieee32` and `Ieee64` structures. This makes it a bit more inconvenient to interpreter Cranelift FP operations but this ...
diff --git a/cranelift/codegen/src/data_value.rs b/cranelift/codegen/src/data_value.rs index 4568923bf..6ffcb9984 100644 --- a/cranelift/codegen/src/data_value.rs +++ b/cranelift/codegen/src/data_value.rs @@ -18,8 +18,8 @@ pub enum DataValue { I16(i16), I32(i32), I64(i64), - F32(f32), - F64(f64), +...
5
22
28
ce44719e1fa86b750f3bf9d3b2ece158227e0c2b
Andrew Brown
2020-10-01T17:33:49
refactor: change LowerCtx::get_immediate to return a DataValue This change abstracts away (from the perspective of the new backend) how immediate values are stored in InstructionData. It gathers large immediates from necessary places (e.g. constant pool) and delegates to `InstructionData::imm_value` for the rest. This...
diff --git a/cranelift/codegen/src/ir/constant.rs b/cranelift/codegen/src/ir/constant.rs index af7dd56a8..bd84e25ee 100644 --- a/cranelift/codegen/src/ir/constant.rs +++ b/cranelift/codegen/src/ir/constant.rs @@ -63,6 +63,11 @@ impl ConstantData { self.0.is_empty() } + /// Return the data as a slice....
4
38
28
3a2025fdc7101d2d0d49b5359f97189197979c7f
Andrew Brown
2020-10-01T16:50:07
Add InstructionData::imm_value()
diff --git a/cranelift/codegen/src/data_value.rs b/cranelift/codegen/src/data_value.rs index 05379196d..4568923bf 100644 --- a/cranelift/codegen/src/data_value.rs +++ b/cranelift/codegen/src/data_value.rs @@ -1,6 +1,6 @@ //! This module gives users to instantiate values that Cranelift understands. These values are use...
2
52
1
6f6f79ef2bbba5d076771d3ca503dc5de036a225
Andrew Brown
2020-10-01T15:55:12
refactor: move DataValue from cranelift-reader to cranelift-codegen This is no change to functionality; the move is necessary in order to return InstructionData immediates in a structure way (see next commit).
diff --git a/cranelift/codegen/src/data_value.rs b/cranelift/codegen/src/data_value.rs new file mode 100644 index 000000000..05379196d --- /dev/null +++ b/cranelift/codegen/src/data_value.rs @@ -0,0 +1,180 @@ +//! This module gives users to instantiate values that Cranelift understands. These values are used, +//! for ...
8
192
180
387afc805ec2a4904e1c60fe28fad46bf2e54ebf
Gabor Greif
2020-10-07T17:42:20
debug: Normalise value prior to right shifts (#2276) * normalise value prior to right shifts by first left-aligning (shift left by 32 bits) then shifting back (respecting signedness) * Update crates/debug/src/transform/expression.rs Co-authored-by: bjorn3 <bjorn3@users.noreply.github.com> * Update crates/...
diff --git a/crates/debug/src/transform/expression.rs b/crates/debug/src/transform/expression.rs index 991de99ce..3d9985b2f 100644 --- a/crates/debug/src/transform/expression.rs +++ b/crates/debug/src/transform/expression.rs @@ -547,8 +547,6 @@ where | Operation::And { .. } | Operation...
1
44
3
d91f0c3933e90cb2946655ed1f34cc4698b0ae91
subtly
2020-10-07T11:30:14
get pc for freebsd (#2270) * get pc for freebsd * whitespace :| * fix; i386 to x86 * remove x86 since uc_mcontext isn't yet in libc * freebsd build of rust uses libcc/unwind
diff --git a/crates/jit/src/unwind/systemv.rs b/crates/jit/src/unwind/systemv.rs index b5890fbbf..b449f5d17 100644 --- a/crates/jit/src/unwind/systemv.rs +++ b/crates/jit/src/unwind/systemv.rs @@ -90,7 +90,7 @@ impl UnwindRegistry { let mut eh_frame = EhFrame(EndianVec::new(RunTimeEndian::default())); ...
2
6
3
84ac3feef8b5ed5e53203a8ccb24cf28a363dd07
Benjamin Bouvier
2020-10-06T16:30:14
machinst x64: use zero-latency move instructions for f32/f64; As found by @julian-seward1, movss/movsd aren't included in the zero-latency move instructions section of the Intel optimization manual. Use MOVAPS instead for those moves.
diff --git a/cranelift/codegen/src/isa/x64/inst/mod.rs b/cranelift/codegen/src/isa/x64/inst/mod.rs index b370c97f4..e2f8a6c61 100644 --- a/cranelift/codegen/src/isa/x64/inst/mod.rs +++ b/cranelift/codegen/src/isa/x64/inst/mod.rs @@ -2401,10 +2401,12 @@ impl MachInst for Inst { match rc_dst { RegCl...
1
5
3
1d1de35ad140096bc345f94d32f6f7273e1d5303
zhiqiangxu
2020-10-05T18:14:44
optimize register_jit_code (#2262)
diff --git a/crates/wasmtime/src/instance.rs b/crates/wasmtime/src/instance.rs index f69b0be36..2ca3aa421 100644 --- a/crates/wasmtime/src/instance.rs +++ b/crates/wasmtime/src/instance.rs @@ -163,7 +163,7 @@ impl Instance { let host_info = Box::new({ let frame_info_registration = module.registe...
2
3
2
df8f85f4bc867868f39347c563c65651155805f0
Benjamin Bouvier
2020-10-02T10:24:07
machinst x64: remove non_camel_case_types;
diff --git a/cranelift/codegen/src/isa/x64/inst/emit.rs b/cranelift/codegen/src/isa/x64/inst/emit.rs index a633c2a23..edddb7e6b 100644 --- a/cranelift/codegen/src/isa/x64/inst/emit.rs +++ b/cranelift/codegen/src/isa/x64/inst/emit.rs @@ -476,7 +476,7 @@ pub(crate) fn emit( state: &mut EmitState, ) { match ins...
2
70
71
4a10a78e33bcbb6184179830159ec090254fd2a0
Benjamin Bouvier
2020-10-02T09:42:25
machinst x64: remove non_snake_case;
diff --git a/cranelift/codegen/src/isa/x64/inst/emit.rs b/cranelift/codegen/src/isa/x64/inst/emit.rs index 363299c97..a633c2a23 100644 --- a/cranelift/codegen/src/isa/x64/inst/emit.rs +++ b/cranelift/codegen/src/isa/x64/inst/emit.rs @@ -517,8 +517,8 @@ pub(crate) fn emit( } R...
3
25
29
7b4d173b90b673721cd0cb18e7f1fb1532b23b3d
Johnnie Birch
2020-09-25T23:22:15
Adds packed floating point min/max for X64 for the new backend Allows for simd_f32x4 and simd_f64x2 spec tests
diff --git a/build.rs b/build.rs index c5674a343..6081996d6 100644 --- a/build.rs +++ b/build.rs @@ -192,8 +192,10 @@ fn experimental_x64_should_panic(testsuite: &str, testname: &str, strategy: &str ("simd", "simd_i32x4_arith2") => return false, ("simd", "simd_i32x4_cmp") => return false, ("s...
2
200
6
3ca173e4bcf2a17828b072c443eb7b3d28fb1f0f
Chris Fallin
2020-10-02T18:55:46
Fix arm32 build after some ABI framework changes. It turns out that while we don't have the partial/experimental arm32 backend tested on our CI yet, the Firefox build *does* at least rely on the backend to build, because it specifies the `arm32` feature to `cranelift-codegen`, even if it will never invoke the backend....
diff --git a/cranelift/codegen/src/isa/arm32/abi.rs b/cranelift/codegen/src/isa/arm32/abi.rs index d50eafb71..54f0d3e6a 100644 --- a/cranelift/codegen/src/isa/arm32/abi.rs +++ b/cranelift/codegen/src/isa/arm32/abi.rs @@ -81,6 +81,7 @@ impl ABIMachineSpec for Arm32MachineDeps { reg.to_real_reg(), ...
1
21
4
ca1b76421ac3b8a37d7e2ddad096f21db959bfbf
Andrew Brown
2020-10-01T19:23:48
[machinst x64]: remove duplicate code to insert a lane
diff --git a/cranelift/codegen/src/isa/x64/lower.rs b/cranelift/codegen/src/isa/x64/lower.rs index aaac19eac..4fa200029 100644 --- a/cranelift/codegen/src/isa/x64/lower.rs +++ b/cranelift/codegen/src/isa/x64/lower.rs @@ -202,6 +202,48 @@ fn input_to_reg_mem_imm(ctx: Ctx, spec: InsnInput) -> RegMemImm { } } +///...
1
43
71
c42a097a0c81877af2677271f2bdbfb98ab50e8b
Andrew Brown
2020-10-01T18:44:31
[machinst x64]: use `is64` instead of `w_bit`
diff --git a/cranelift/codegen/src/isa/x64/lower.rs b/cranelift/codegen/src/isa/x64/lower.rs index 4b8a4e180..aaac19eac 100644 --- a/cranelift/codegen/src/isa/x64/lower.rs +++ b/cranelift/codegen/src/isa/x64/lower.rs @@ -2862,14 +2862,14 @@ fn lower_insn_to_regs<C: LowerCtx<I = Inst>>( ctx.emit(Inst::gen...
1
2
2
a82d1604cb3d35cfd2ab6386e7921eed86414740
Andrew Brown
2020-09-30T18:05:20
[machinst x64]: enable lane spec tests
diff --git a/build.rs b/build.rs index bf4d7ce19..c5674a343 100644 --- a/build.rs +++ b/build.rs @@ -196,6 +196,8 @@ fn experimental_x64_should_panic(testsuite: &str, testname: &str, strategy: &str ("simd", "simd_f32x4_cmp") => return false, ("simd", "simd_f64x2_arith") => return false, ("sim...
1
2
0
50b9399006ae5bf0f7ff76ede6dbbb0c83987ac3
Andrew Brown
2020-09-29T21:42:53
[machinst x64]: lower remaining lane operations--any_true, all_true, splat
diff --git a/cranelift/codegen/src/isa/x64/inst/args.rs b/cranelift/codegen/src/isa/x64/inst/args.rs index fc441c302..29cf01c71 100644 --- a/cranelift/codegen/src/isa/x64/inst/args.rs +++ b/cranelift/codegen/src/isa/x64/inst/args.rs @@ -459,6 +459,7 @@ pub enum SseOpcode { Psubd, Psubq, Psubw, + Ptest...
4
165
5
4565582f024fd3cba2f05ecf7ff3a22197319015
Andrew Brown
2020-09-29T21:42:36
[machinst x64]: clarify parameter name of Inst::xmm_rm_r_imm
diff --git a/cranelift/codegen/src/isa/x64/inst/mod.rs b/cranelift/codegen/src/isa/x64/inst/mod.rs index 929afa293..9026bddef 100644 --- a/cranelift/codegen/src/isa/x64/inst/mod.rs +++ b/cranelift/codegen/src/isa/x64/inst/mod.rs @@ -786,14 +786,14 @@ impl Inst { src: RegMem, dst: Writable<Reg>, ...
1
2
2
0579e9f9de7d71a255cd401826759a9747f85f74
Andrew Brown
2020-09-29T21:41:01
[machinst x64]: add packed OR
diff --git a/cranelift/codegen/src/isa/x64/inst/args.rs b/cranelift/codegen/src/isa/x64/inst/args.rs index 16acafc94..fc441c302 100644 --- a/cranelift/codegen/src/isa/x64/inst/args.rs +++ b/cranelift/codegen/src/isa/x64/inst/args.rs @@ -444,6 +444,7 @@ pub enum SseOpcode { Pmulld, Pmullw, Pmuludq, + P...
2
4
0
f6bfa71dc1cc7031590aac34b4e1bc8786881f8f
Andrew Brown
2020-09-29T20:18:21
[machinst x64]: enable integer comparison SIMD spec tests
diff --git a/build.rs b/build.rs index 8b11a3d17..bf4d7ce19 100644 --- a/build.rs +++ b/build.rs @@ -184,10 +184,13 @@ fn experimental_x64_should_panic(testsuite: &str, testname: &str, strategy: &str ("simd", "simd_const") => return false, ("simd", "simd_i8x16_arith") => return false, ("simd"...
1
3
0
74226d67812869807e558e3942bf9a3b3acd8b80
Andrew Brown
2020-09-29T20:17:46
[machinst x64]: add integer comparisons
diff --git a/cranelift/codegen/src/isa/x64/inst/args.rs b/cranelift/codegen/src/isa/x64/inst/args.rs index 5372d390c..16acafc94 100644 --- a/cranelift/codegen/src/isa/x64/inst/args.rs +++ b/cranelift/codegen/src/isa/x64/inst/args.rs @@ -344,6 +344,7 @@ pub(crate) enum InstructionSet { SSE2, SSSE3, SSE41,...
4
151
7
81ce92b7ef289121bee123aa2ac6cc500d7e59c0
Nick Fitzgerald
2020-09-30T22:37:29
Add reminder to tag releases to publish script (#2250)
diff --git a/scripts/publish.rs b/scripts/publish.rs index b612d4735..af12d22db 100644 --- a/scripts/publish.rs +++ b/scripts/publish.rs @@ -108,6 +108,13 @@ fn main() { for krate in crates.iter() { publish(&krate); } + println!(""); + println!("=========...
1
7
0
835db11beaf914b19a5c70a21c8da4cfbe3311d6
Chris Fallin
2020-09-22T23:53:06
Support for SpiderMonkey's "Wasm ABI 2020". As part of a Wasm JIT update, SpiderMonkey is changing its internal WebAssembly function ABI. The new ABI's frame format includes "caller TLS" and "callee TLS" slots. The details of where these come from are not important; from Cranelift's point of view, the only relevant re...
diff --git a/cranelift/codegen/meta/src/shared/settings.rs b/cranelift/codegen/meta/src/shared/settings.rs index 8a6e25910..1ddc44592 100644 --- a/cranelift/codegen/meta/src/shared/settings.rs +++ b/cranelift/codegen/meta/src/shared/settings.rs @@ -194,6 +194,7 @@ pub(crate) fn define() -> SettingGroup { "...
10
204
21
9ccf8370926ffd6094076b4b83c437ff41476ea6
bjorn3
2020-09-30T17:58:12
Fix SimpleJIT tests
diff --git a/cranelift/simplejit/examples/simplejit-minimal.rs b/cranelift/simplejit/examples/simplejit-minimal.rs index 1534e144d..7c5df36ee 100644 --- a/cranelift/simplejit/examples/simplejit-minimal.rs +++ b/cranelift/simplejit/examples/simplejit-minimal.rs @@ -1,12 +1,12 @@ use cranelift::prelude::*; use cranelif...
2
13
27
d84ca235d2a627ce674738a47a10841c59a777e8
bjorn3
2020-09-30T17:52:57
Remove Backend trait and turn Module into a trait
diff --git a/cranelift/module/src/backend.rs b/cranelift/module/src/backend.rs deleted file mode 100644 index 9b9df893b..000000000 --- a/cranelift/module/src/backend.rs +++ /dev/null @@ -1,128 +0,0 @@ -//! Defines the `Backend` trait. - -use crate::module::ModuleCompiledFunction; -use crate::DataContext; -use crate::Da...
7
95
233
84c6ec32148307716edecf48e2a32710be7387b7
bjorn3
2020-09-30T17:23:23
Move alignment config from declare_data to define_data
diff --git a/cranelift/module/src/backend.rs b/cranelift/module/src/backend.rs index 9d12fa17a..9b9df893b 100644 --- a/cranelift/module/src/backend.rs +++ b/cranelift/module/src/backend.rs @@ -62,7 +62,6 @@ where linkage: Linkage, writable: bool, tls: bool, - align: Option<u8>, ) ...
6
30
23
447c3e71a6361bafac49126eb99be19929fc84f7
Nick Fitzgerald
2020-09-22T23:06:07
peepmatic: Simplify linear IR This commit splits "increments" in two; they previously contained both the linearized left- and right-hand sides. But only the first increment ever had any actions, so it was confusing (and space wasting) that all increments had an "actions" vector. No more! This commit separates the lin...
diff --git a/cranelift/peepmatic/crates/runtime/src/linear.rs b/cranelift/peepmatic/crates/runtime/src/linear.rs index 21bbdd316..daa147e22 100644 --- a/cranelift/peepmatic/crates/runtime/src/linear.rs +++ b/cranelift/peepmatic/crates/runtime/src/linear.rs @@ -37,8 +37,13 @@ pub struct Optimization<TOperator> where ...
4
253
255
b44c5bb2bef5c6567c96aca6acc529ccd9e866ff
bjorn3
2020-09-30T16:33:29
Move ModuleDeclarations to backends
diff --git a/cranelift/module/src/backend.rs b/cranelift/module/src/backend.rs index a72adf00c..9d12fa17a 100644 --- a/cranelift/module/src/backend.rs +++ b/cranelift/module/src/backend.rs @@ -44,28 +44,34 @@ where /// Return the `TargetIsa` to compile for. fn isa(&self) -> &dyn TargetIsa; + /// Get all ...
4
106
107
7a6e909efe9a72f94a9aac3acceb0325e25a1236
bjorn3
2020-09-30T15:31:08
Move a bit more logic out of Module
diff --git a/Cargo.lock b/Cargo.lock index 4fc0480e9..ee7bc821f 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -489,6 +489,7 @@ dependencies = [ "anyhow", "cranelift-codegen", "cranelift-module", + "log", "object 0.21.1", "target-lexicon", ] @@ -535,6 +536,7 @@ dependencies = [ "cranelift-native", "errno", ...
8
66
53
c2ffcdc6d098642a7a697d5c01207c8bad73c892
bjorn3
2020-09-30T15:12:27
Move logic out of more Module methods
diff --git a/cranelift/module/src/backend.rs b/cranelift/module/src/backend.rs index 69137d714..61cab5521 100644 --- a/cranelift/module/src/backend.rs +++ b/cranelift/module/src/backend.rs @@ -63,7 +63,6 @@ where fn define_function<TS>( &mut self, id: FuncId, - name: &str, ctx: &C...
4
66
82
80f4ecf9b511c3767c65e5657775e154ae5fe1fa
bjorn3
2020-09-30T14:50:24
Move almost all logic out of Module
diff --git a/cranelift/module/src/backend.rs b/cranelift/module/src/backend.rs index 32fcd6cf7..69137d714 100644 --- a/cranelift/module/src/backend.rs +++ b/cranelift/module/src/backend.rs @@ -5,7 +5,7 @@ use crate::FuncId; use crate::Linkage; use crate::ModuleDeclarations; use crate::ModuleResult; -use crate::{Data...
4
106
87
588a4be0b31bf679ae153e929853623894184c63
bjorn3
2020-09-30T14:18:57
Store Compiled* in the backend instead of Module
diff --git a/cranelift/module/src/backend.rs b/cranelift/module/src/backend.rs index 0d4b5e8e5..32fcd6cf7 100644 --- a/cranelift/module/src/backend.rs +++ b/cranelift/module/src/backend.rs @@ -1,19 +1,19 @@ //! Defines the `Backend` trait. -use crate::{DataContext, FuncOrDataId}; use crate::DataId; use crate::Func...
6
218
326
405b9e28753db5d5681ddf6fb9099612ff64621e
bjorn3
2020-09-30T12:20:39
Remove finalize_* from the Backend trait Instead let the `finish` method perform finalization
diff --git a/cranelift/module/src/backend.rs b/cranelift/module/src/backend.rs index bf4f593a4..0d4b5e8e5 100644 --- a/cranelift/module/src/backend.rs +++ b/cranelift/module/src/backend.rs @@ -103,30 +103,6 @@ where contents: &ModuleContents<Self>, ) -> ModuleResult<Self::CompiledData>; - /// Perform...
4
142
164
59f95083b14f045745e4a4991239af9dbd38bfb3
bjorn3
2020-09-30T11:58:58
Remove write_data_funcaddr and write_data_dataaddr They are unimplemented by all backends
diff --git a/cranelift/module/src/backend.rs b/cranelift/module/src/backend.rs index 74b2342e1..bf4f593a4 100644 --- a/cranelift/module/src/backend.rs +++ b/cranelift/module/src/backend.rs @@ -103,25 +103,6 @@ where contents: &ModuleContents<Self>, ) -> ModuleResult<Self::CompiledData>; - /// Write t...
4
1
101
7608749647d3fd4adbce405cdfdb1ebbca0ecb51
bjorn3
2020-09-30T11:58:13
Merge finalize_definitions into finish
diff --git a/cranelift/module/src/backend.rs b/cranelift/module/src/backend.rs index e20416b92..74b2342e1 100644 --- a/cranelift/module/src/backend.rs +++ b/cranelift/module/src/backend.rs @@ -146,12 +146,6 @@ where contents: &ModuleContents<Self>, ); - /// "Publish" all finalized functions and data ...
4
14
39
4483c3740a7f045b59648b5e37249c8e1fc66653
bjorn3
2020-09-30T11:53:01
Remove get_finalized_*
diff --git a/cranelift/module/src/backend.rs b/cranelift/module/src/backend.rs index 6602c4cbb..e20416b92 100644 --- a/cranelift/module/src/backend.rs +++ b/cranelift/module/src/backend.rs @@ -1,6 +1,6 @@ //! Defines the `Backend` trait. -use crate::DataContext; +use crate::{DataContext, FuncOrDataId}; use crate::D...
5
84
113
7dcfb1b47bbeb93927c98740a76603479f0b3621
bjorn3
2020-09-30T10:40:26
Move some error checking out of the define_* functions
diff --git a/cranelift/module/src/module.rs b/cranelift/module/src/module.rs index f27cac201..4e08afe37 100644 --- a/cranelift/module/src/module.rs +++ b/cranelift/module/src/module.rs @@ -191,6 +191,16 @@ where } Ok(()) } + + fn validate_for_define(&self) -> ModuleResult<()> { + if sel...
1
23
18
6161acfba50d2c3d748f32d375282772f41c808a
bjorn3
2020-09-30T10:33:12
Minor simplification
diff --git a/cranelift/object/src/backend.rs b/cranelift/object/src/backend.rs index 31ec135d2..be247f9cd 100644 --- a/cranelift/object/src/backend.rs +++ b/cranelift/object/src/backend.rs @@ -455,8 +455,7 @@ impl Backend for ObjectBackend { } fn finish(mut self, contents: &ModuleContents<Self>) -> ObjectPr...
1
1
2
b1187b5507a68af67444f5b0c08e719ee4b91320
bjorn3
2020-09-30T10:29:22
Merge ModuleNamespace and ModuleContents
diff --git a/cranelift/module/src/backend.rs b/cranelift/module/src/backend.rs index ff1372208..6602c4cbb 100644 --- a/cranelift/module/src/backend.rs +++ b/cranelift/module/src/backend.rs @@ -4,7 +4,7 @@ use crate::DataContext; use crate::DataId; use crate::FuncId; use crate::Linkage; -use crate::ModuleNamespace; +...
5
52
97
a04001211cad679a4322dd70787050eee713fc89
Alex Crichton
2020-09-29T23:56:08
Add metadata to peepmatic crates (#2245)
diff --git a/cranelift/peepmatic/crates/traits/Cargo.toml b/cranelift/peepmatic/crates/traits/Cargo.toml index 06caa90e3..187d03081 100644 --- a/cranelift/peepmatic/crates/traits/Cargo.toml +++ b/cranelift/peepmatic/crates/traits/Cargo.toml @@ -3,6 +3,8 @@ name = "peepmatic-traits" version = "0.67.0" authors = ["Nick...
1
2
0
4484a00ea5c8b03203317f0cb823cbb8c2615c9d
Andrew Brown
2020-09-28T19:54:53
[machinst x64]: calculate extension modes in one place
diff --git a/cranelift/codegen/src/isa/x64/abi.rs b/cranelift/codegen/src/isa/x64/abi.rs index b9d55349c..93e057a5a 100644 --- a/cranelift/codegen/src/isa/x64/abi.rs +++ b/cranelift/codegen/src/isa/x64/abi.rs @@ -226,12 +226,8 @@ impl ABIMachineSpec for X64ABIMachineSpec { from_bits: u8, to_bits: u8, ...
3
31
36
715be68101504d2c737617a7be98042bda56735a
Andrew Brown
2020-09-29T15:56:40
[machinst x64]: assert lane is correct size for extractlane This change applies a good suggestion @bjorn3 made in #2230 that I forgot to implement there.
diff --git a/cranelift/codegen/src/isa/x64/lower.rs b/cranelift/codegen/src/isa/x64/lower.rs index e4093c193..4b5108195 100644 --- a/cranelift/codegen/src/isa/x64/lower.rs +++ b/cranelift/codegen/src/isa/x64/lower.rs @@ -2817,6 +2817,7 @@ fn lower_insn_to_regs<C: LowerCtx<I = Inst>>( } else { ...
1
1
0
f50d905152954335a1e351aec3fc309b0ab1e4d5
Andrew Brown
2020-09-23T16:24:06
[machinst x64]: refactor using added RegMem::from(Writable<Reg>)
diff --git a/cranelift/codegen/src/isa/x64/inst/args.rs b/cranelift/codegen/src/isa/x64/inst/args.rs index 0013b493a..9a83a6089 100644 --- a/cranelift/codegen/src/isa/x64/inst/args.rs +++ b/cranelift/codegen/src/isa/x64/inst/args.rs @@ -5,7 +5,7 @@ use super::EmitState; use crate::ir::condcodes::{FloatCC, IntCC}; use...
2
21
13
e3eb098c99a08285e9ead0a86c9d5877625a5dba
Andrew Brown
2020-09-23T16:18:45
[machinst x64]: add swizzle implementation
diff --git a/cranelift/codegen/src/isa/x64/lower.rs b/cranelift/codegen/src/isa/x64/lower.rs index 40c6bee7e..f35f15e32 100644 --- a/cranelift/codegen/src/isa/x64/lower.rs +++ b/cranelift/codegen/src/isa/x64/lower.rs @@ -2721,6 +2721,38 @@ fn lower_insn_to_regs<C: LowerCtx<I = Inst>>( } } + ...
1
32
0
050f078f8659a064dae9646a4a09f941b048cb5b
Andrew Brown
2020-09-23T15:54:10
[machinst x64]: add saturating addition implementation
diff --git a/cranelift/codegen/src/isa/x64/inst/args.rs b/cranelift/codegen/src/isa/x64/inst/args.rs index 719cfa760..0013b493a 100644 --- a/cranelift/codegen/src/isa/x64/inst/args.rs +++ b/cranelift/codegen/src/isa/x64/inst/args.rs @@ -402,6 +402,10 @@ pub enum SseOpcode { Paddd, Paddq, Paddw, + Padd...
4
57
5
a64abf9b7650ed9f2916b030cb92cb9dfbb1adb2
Andrew Brown
2020-09-23T15:39:33
[machinst x64]: add shuffle implementation
diff --git a/cranelift/codegen/src/isa/x64/inst/args.rs b/cranelift/codegen/src/isa/x64/inst/args.rs index f76394576..719cfa760 100644 --- a/cranelift/codegen/src/isa/x64/inst/args.rs +++ b/cranelift/codegen/src/isa/x64/inst/args.rs @@ -425,6 +425,7 @@ pub enum SseOpcode { Pmulld, Pmullw, Pmuludq, + P...
4
79
1
f4836f9ca92f2dff3cd4b637db29295b711127c1
Andrew Brown
2020-09-23T14:13:53
[machinst x64]: add extractlane implementation
diff --git a/cranelift/codegen/src/isa/x64/inst/args.rs b/cranelift/codegen/src/isa/x64/inst/args.rs index 8b31ce994..f76394576 100644 --- a/cranelift/codegen/src/isa/x64/inst/args.rs +++ b/cranelift/codegen/src/isa/x64/inst/args.rs @@ -404,6 +404,9 @@ pub enum SseOpcode { Paddw, Pavgb, Pavgw, + Pextr...
4
100
6
29fa8947901cd5455a6eb5c405a9650e79e20937
Andrew Brown
2020-09-22T19:39:50
[machinst x64]: add insertlane implementation
diff --git a/cranelift/codegen/src/isa/x64/inst/args.rs b/cranelift/codegen/src/isa/x64/inst/args.rs index 7cb64898e..8b31ce994 100644 --- a/cranelift/codegen/src/isa/x64/inst/args.rs +++ b/cranelift/codegen/src/isa/x64/inst/args.rs @@ -383,6 +383,7 @@ pub enum SseOpcode { Movd, Movdqa, Movdqu, + Movl...
5
116
24
a8a6e4e69d4d76063a71da752d410dfac65510dd
zhiqiangxu
2020-09-29T04:49:46
optimize get_wasmtime_signature (#2243)
diff --git a/crates/wasmtime/src/types.rs b/crates/wasmtime/src/types.rs index 35c03acb3..d8a3ad27b 100644 --- a/crates/wasmtime/src/types.rs +++ b/crates/wasmtime/src/types.rs @@ -252,21 +252,20 @@ impl FuncType { use wasmtime_environ::ir::{AbiParam, ArgumentPurpose, Signature}; use wasmtime_jit::nat...
1
9
10
0de5f7cf5c8f50b9658c59e7f0dc4b979f38dfa1
zhiqiangxu
2020-09-26T05:49:56
rm useless code (#2229)
diff --git a/crates/wasmtime/src/trampoline/func.rs b/crates/wasmtime/src/trampoline/func.rs index 85ef15359..29bf5af08 100644 --- a/crates/wasmtime/src/trampoline/func.rs +++ b/crates/wasmtime/src/trampoline/func.rs @@ -128,10 +128,6 @@ fn make_trampoline( let values_vec_ptr_val = builder.ins().stack_addr(poi...
1
0
4
b10beeee015372ed6cef628b1da7f2a7395f0f94
Pat Hickey
2020-09-26T05:49:28
dep gardening (#2233) * wasmtime-profiling: latest object dep is 0.21.1 * latest gimli is 0.22 * bump cargo.lock
diff --git a/Cargo.lock b/Cargo.lock index 81b0985ce..82b9a2a64 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -6,7 +6,7 @@ version = "0.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1b6a2d3371669ab3ca9797670853d61402b03d0b4b9ebf33d677dfa720203072" dependencies = [ - "gimli 0.22.0",...
7
17
29
48cf45491d366f4cf401e77887491a7e599a775e
Andrew Brown
2020-09-25T17:53:56
[machinst x64]: inform the register allocator of more types of packed moves
diff --git a/cranelift/codegen/src/isa/x64/inst/mod.rs b/cranelift/codegen/src/isa/x64/inst/mod.rs index e2afc3019..b9bf226e7 100644 --- a/cranelift/codegen/src/isa/x64/inst/mod.rs +++ b/cranelift/codegen/src/isa/x64/inst/mod.rs @@ -2278,18 +2278,27 @@ impl MachInst for Inst { } fn is_move(&self) -> Option<...
1
14
5
4f7bec5e94fbc6c7b2ad177fab20c9c6bb558c6f
Benjamin Bouvier
2020-09-24T15:37:48
machinst x64: enable two more Rust tests; Fixed by the grand ABI refactoring, h/t @cfallin.
diff --git a/tests/all/iloop.rs b/tests/all/iloop.rs index 6f59800ad..23e6f85aa 100644 --- a/tests/all/iloop.rs +++ b/tests/all/iloop.rs @@ -99,7 +99,6 @@ fn loop_interrupt_from_afar() -> anyhow::Result<()> { } #[test] -#[cfg_attr(feature = "experimental_x64", ignore)] // TODO #2079 interrupts in wasmtime fn funct...
2
0
2
f8d397fd98ef02094660b43af107cbeb95e2684e
Andrew Brown
2020-09-21T19:33:52
[machinst x64]: enable packed arithmetic spec tests This change should finish off the implementation of packed arithmetic in the new backend.
diff --git a/build.rs b/build.rs index 25a3f23e7..8b11a3d17 100644 --- a/build.rs +++ b/build.rs @@ -183,8 +183,11 @@ fn experimental_x64_should_panic(testsuite: &str, testname: &str, strategy: &str ("simd", "simd_address") => return false, ("simd", "simd_const") => return false, ("simd", "si...
1
3
0
ac2bf9d2463534ae89ec6e51ee71160a6f212656
Andrew Brown
2020-09-21T19:32:32
[machinst x64]: add packed min/max implementations
diff --git a/cranelift/codegen/src/isa/x64/inst/args.rs b/cranelift/codegen/src/isa/x64/inst/args.rs index caa00eed3..7cb64898e 100644 --- a/cranelift/codegen/src/isa/x64/inst/args.rs +++ b/cranelift/codegen/src/isa/x64/inst/args.rs @@ -403,6 +403,18 @@ pub enum SseOpcode { Paddw, Pavgb, Pavgw, + Pmax...
4
166
3
7546d988441fe663c73429028c8b4ae8ca78a302
Andrew Brown
2020-09-21T18:49:26
[machinst x64]: add avg_round implementation
diff --git a/cranelift/codegen/src/isa/x64/inst/args.rs b/cranelift/codegen/src/isa/x64/inst/args.rs index 18e5d15d4..caa00eed3 100644 --- a/cranelift/codegen/src/isa/x64/inst/args.rs +++ b/cranelift/codegen/src/isa/x64/inst/args.rs @@ -401,6 +401,8 @@ pub enum SseOpcode { Paddd, Paddq, Paddw, + Pavgb...
4
26
0
b202464fa022adb6b8b7cb5abd3aae3c4a351401
Andrew Brown
2020-09-21T18:40:04
[machinst x64]: add iabs implementation
diff --git a/cranelift/codegen/src/isa/x64/inst/args.rs b/cranelift/codegen/src/isa/x64/inst/args.rs index 4b236ee16..18e5d15d4 100644 --- a/cranelift/codegen/src/isa/x64/inst/args.rs +++ b/cranelift/codegen/src/isa/x64/inst/args.rs @@ -336,6 +336,7 @@ impl fmt::Display for UnaryRmROpcode { pub(crate) enum Instruction...
4
70
17
0ec2c12ab539209f4b731a232f8f213854da7d1d
Nikolay Volf
2020-09-23T15:06:53
Log level to "debug!" in translate_from_reader (#2221) Default logger floods the console otherwise: ``` Sep 22 22:41:02.525 INFO translate(181 bytes, u0:1353(i64 vmctx, i64, i32, i32) -> i32 system_v) Sep 22 22:41:02.526 INFO translate(394 bytes, u0:1354(i64 vmctx, i64, i32) system_v) Sep 22 22:41:02.527 INFO tr...
diff --git a/cranelift/wasm/src/func_translator.rs b/cranelift/wasm/src/func_translator.rs index 11ec5b6ca..f46b0f7fa 100644 --- a/cranelift/wasm/src/func_translator.rs +++ b/cranelift/wasm/src/func_translator.rs @@ -14,7 +14,6 @@ use cranelift_codegen::entity::EntityRef; use cranelift_codegen::ir::{self, Block, InstB...
1
1
2
04cf94cea3606d39279bc2348336b1aea9095602
Benjamin Bouvier
2020-09-22T17:14:54
runtime: fix nearest for NaN inputs; According to wasm's spec, nearest must do the following, for NaN inputs: - when the input is a canonical NaN, return a canonical NaN; - when the input is a non-canonical NaN, return an arithmetic NaN. This patch adds checks when the exponent is all ones if the input was a NaN, and...
diff --git a/crates/runtime/src/libcalls.rs b/crates/runtime/src/libcalls.rs index a7dfe0a72..9383af9a8 100644 --- a/crates/runtime/src/libcalls.rs +++ b/crates/runtime/src/libcalls.rs @@ -88,12 +88,22 @@ pub extern "C" fn wasmtime_f32_trunc(x: f32) -> f32 { /// Implementation of f32.nearest #[allow(clippy::float_ari...
1
22
2
79cff73da53c5e72bc8dae9b4c2582d0596b8141
Benjamin Bouvier
2020-09-22T15:19:10
machinst x64: implement loads/stores for v128 SIMD types; This made it possible to enable more SIMD tests from the spec test suite too.
diff --git a/build.rs b/build.rs index e23e8c218..25a3f23e7 100644 --- a/build.rs +++ b/build.rs @@ -182,6 +182,10 @@ fn experimental_x64_should_panic(testsuite: &str, testname: &str, strategy: &str match (testsuite, testname) { ("simd", "simd_address") => return false, ("simd", "simd_const") => ...
2
16
54
863d4272a792dd03c023c1ec2c006a1b7f384c1f
bjorn3
2020-09-22T12:04:12
cranelift-object: Support per function sections This makes it possible for the linker to omit unused functions when --gc-sections is passed.
diff --git a/cranelift/object/src/backend.rs b/cranelift/object/src/backend.rs index 6521dd0c3..4e550d6be 100644 --- a/cranelift/object/src/backend.rs +++ b/cranelift/object/src/backend.rs @@ -30,6 +30,7 @@ pub struct ObjectBuilder { name: Vec<u8>, libcall_names: Box<dyn Fn(ir::LibCall) -> String>, funct...
1
48
8
31165d0e9b2b9b8df04aad6384515d7be8cd218e
Andrew Brown
2020-09-18T20:08:16
Print more information about types that cannot be generated by wiggle
diff --git a/crates/wiggle/generate/src/types/struct.rs b/crates/wiggle/generate/src/types/struct.rs index 5aaf42353..2a79a6e9a 100644 --- a/crates/wiggle/generate/src/types/struct.rs +++ b/crates/wiggle/generate/src/types/struct.rs @@ -33,7 +33,7 @@ pub(super) fn define_struct( let pointee_type = ...
1
2
2
97e0f4864c1c5bc12baaf9ca1cf4e8c543c90402
Andrew Brown
2020-09-18T20:07:33
Fix typo
diff --git a/crates/wiggle/macro/src/lib.rs b/crates/wiggle/macro/src/lib.rs index 48f036731..a3c10afb8 100644 --- a/crates/wiggle/macro/src/lib.rs +++ b/crates/wiggle/macro/src/lib.rs @@ -11,7 +11,7 @@ use syn::parse_macro_input; /// CamelCase. /// /// * For each `module` defined in the witx document, a Rust modu...
1
1
1
45ccc6940e7f3d677de2186e69fcaa951e48c597
bjorn3
2020-09-21T12:48:31
Fix Switch for 128bit integers
diff --git a/cranelift/codegen/meta/src/cdsl/typevar.rs b/cranelift/codegen/meta/src/cdsl/typevar.rs index 752b458b2..c1027bf84 100644 --- a/cranelift/codegen/meta/src/cdsl/typevar.rs +++ b/cranelift/codegen/meta/src/cdsl/typevar.rs @@ -302,7 +302,7 @@ impl TypeVar { pub fn to_rust_code(&self) -> String { ...
3
20
3
deb20c129a7d36bd5b53f3727a5acf9231c7337e
bjorn3
2020-09-21T11:38:42
Fix relocated readonly data in custom sections Lld doesn't allow relocations in readonly sections
diff --git a/cranelift/object/src/backend.rs b/cranelift/object/src/backend.rs index 6521dd0c3..128571f6b 100644 --- a/cranelift/object/src/backend.rs +++ b/cranelift/object/src/backend.rs @@ -335,8 +335,10 @@ impl Backend for ObjectBackend { sec.clone().into_bytes(), if writable { ...
1
3
1
010e5b9aa86b8a303683046f2ebd0357a52f157a
Nick Fitzgerald
2020-09-18T18:33:38
Make filetest errors report full context (#2207) * clif-util: do not convert `anyhow::Error`s into strings into `anyhow::Error`s * filetests: Use the debug formatting of `anyhow::Error`s This provides the full error context, not just the source error's message.
diff --git a/cranelift/filetests/src/runner.rs b/cranelift/filetests/src/runner.rs index e7877cdb4..d3fa75953 100644 --- a/cranelift/filetests/src/runner.rs +++ b/cranelift/filetests/src/runner.rs @@ -48,7 +48,7 @@ impl Display for QueueEntry { let p = self.path.to_string_lossy(); match self.state { ...
2
3
5
d28abad44119fdac9cb3fa0bc086630b5ea49d7d
Joshua Nelson
2020-09-15T17:24:50
Upgrade to target-lexicon 0.11 This allows downstream library users to use `CDataModel` without having to install two different versions of target-lexicon.
diff --git a/Cargo.lock b/Cargo.lock index 506e5e58e..f9a5fe067 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2018,9 +2018,9 @@ dependencies = [ [[package]] name = "target-lexicon" -version = "0.10.0" +version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ab0e7238dcc7b40a7...
23
35
28
a923ecae9ea5ad4bc22af7e1667f34c507f30985
Nick Fitzgerald
2020-09-15T16:44:03
clif-util: Fix typo in subcommand description Co-authored-by: Andrew Brown <andrew.brown@intel.com>
diff --git a/cranelift/src/wasm.rs b/cranelift/src/wasm.rs index 7af9a2413..8083f9c98 100644 --- a/cranelift/src/wasm.rs +++ b/cranelift/src/wasm.rs @@ -99,7 +99,7 @@ pub struct Options { #[structopt(short("X"))] print_size: bool, - /// Juse decode Wasm into Cranelift IR, don't compile it to native code ...
1
1
1
ed38348b222ff3a41405ed67b94dcdcc13028fe1
Nick Fitzgerald
2020-09-14T23:26:02
clif-util: Switch to using `structopt` for CLI arguments
diff --git a/Cargo.lock b/Cargo.lock index 094bfe93f..506e5e58e 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -548,7 +548,6 @@ dependencies = [ "anyhow", "capstone", "cfg-if", - "clap", "cranelift", "cranelift-codegen", "cranelift-entity", @@ -570,6 +569,7 @@ dependencies = [ "peepmatic-souper", "pretty_e...
13
481
526
b72d5de86c7618f2e5d7454e16cee59fc0465c85
Pat Hickey
2020-09-14T23:33:46
virtfs: import types from handle, drop types:: prefix
diff --git a/crates/wasi-common/src/virtfs.rs b/crates/wasi-common/src/virtfs.rs index 520bab6ad..002382520 100644 --- a/crates/wasi-common/src/virtfs.rs +++ b/crates/wasi-common/src/virtfs.rs @@ -1,5 +1,8 @@ -use crate::handle::{Handle, HandleRights}; -use crate::wasi::{self, types, RightsExt}; +use crate::handle::{ +...
2
100
128
e5129b39cb00c7ea0ec4863e8b73fb2e0fc869c0
Pat Hickey
2020-09-14T23:31:15
path: import types from handle rather than wasi
diff --git a/crates/wasi-common/src/path.rs b/crates/wasi-common/src/path.rs index 2f6da351b..b2e4b19ba 100644 --- a/crates/wasi-common/src/path.rs +++ b/crates/wasi-common/src/path.rs @@ -1,6 +1,5 @@ use crate::entry::Entry; -use crate::handle::{Handle, HandleRights}; -use crate::wasi::types; +use crate::handle::{Fdf...
1
6
8
e47927f0fd6c983d55b0b7187c1b18bd565fa232
Pat Hickey
2020-09-14T23:30:24
fs: only import wasi Fd type in one place
diff --git a/crates/wasi-common/src/fs/dir.rs b/crates/wasi-common/src/fs/dir.rs index 5c2329669..d07734f65 100644 --- a/crates/wasi-common/src/fs/dir.rs +++ b/crates/wasi-common/src/fs/dir.rs @@ -1,5 +1,4 @@ -use crate::fs::{File, OpenOptions, ReadDir}; -use crate::wasi::types; +use crate::fs::{Fd, File, OpenOptions, ...
4
15
16
83c1fa1b8bcc34350eab6139a7f961b1004975fd
Pat Hickey
2020-09-14T23:29:23
entry: import types from handle
diff --git a/crates/wasi-common/src/entry.rs b/crates/wasi-common/src/entry.rs index 780734f29..a162b19f4 100644 --- a/crates/wasi-common/src/entry.rs +++ b/crates/wasi-common/src/entry.rs @@ -1,5 +1,4 @@ -use crate::handle::{Handle, HandleRights}; -use crate::wasi::types::Filetype; +use crate::handle::{Filetype, Handl...
1
1
2
5639881519a82157cbc23752c3ed973236bcb702
Pat Hickey
2020-09-14T23:28:34
ctx: import Fd without any types:: prefix
diff --git a/crates/wasi-common/src/ctx.rs b/crates/wasi-common/src/ctx.rs index 1b77b093c..e73fbb4ea 100644 --- a/crates/wasi-common/src/ctx.rs +++ b/crates/wasi-common/src/ctx.rs @@ -6,7 +6,7 @@ use crate::sys::osdir::OsDir; use crate::sys::stdio::NullDevice; use crate::sys::stdio::{Stderr, StderrExt, Stdin, StdinE...
1
12
12
66ba582bba5e5f19ed57c0454de1cca8546452ac
Pat Hickey
2020-09-14T23:27:49
sched: re-export the wasi types used for times and events
diff --git a/crates/wasi-common/src/lib.rs b/crates/wasi-common/src/lib.rs index 013106cb7..058f02d7a 100644 --- a/crates/wasi-common/src/lib.rs +++ b/crates/wasi-common/src/lib.rs @@ -29,8 +29,8 @@ pub mod fs; mod handle; pub mod old; mod path; -mod poll; mod sandboxed_tty_writer; +pub(crate) mod sched; pub mod s...
3
18
18
6db24fd08fa6f675e1b4ef818f8684602fd58730
Pat Hickey
2020-09-14T23:27:33
handle: re-export all of the wasi types used by handles
diff --git a/crates/wasi-common/src/entry.rs b/crates/wasi-common/src/entry.rs index 8e65f4ec5..780734f29 100644 --- a/crates/wasi-common/src/entry.rs +++ b/crates/wasi-common/src/entry.rs @@ -5,7 +5,7 @@ use std::ops::Deref; use std::path::PathBuf; use std::rc::Rc; -pub(crate) struct EntryHandle(Rc<dyn Handle>); +...
4
180
182
e1c8878b33a6a1908248f42069e407105618167e
Nick Fitzgerald
2020-09-14T15:46:34
cranelift_codegen::souper_harvest: Move preopt out of `Context`, into `clif-util` This allows for more flexibility of when/where to harvest LHS candidates. For example, we could choose to harvest candidates that overlap with and supercede our current preopt peepholes. This commit also makes sure that we compute the C...
diff --git a/cranelift/codegen/src/context.rs b/cranelift/codegen/src/context.rs index 81b9dcbd2..842a48ab2 100644 --- a/cranelift/codegen/src/context.rs +++ b/cranelift/codegen/src/context.rs @@ -457,10 +457,8 @@ impl Context { #[cfg(feature = "souper-harvest")] pub fn souper_harvest( &mut self, - ...
2
5
3
c87aaeeecea7c8a4f29114b7fa5bdda9e7c7f457
Nick Fitzgerald
2020-09-14T15:41:56
cranelift_codegen::souper_harvest: Update TODOs to include more instructions
diff --git a/cranelift/codegen/src/souper_harvest.rs b/cranelift/codegen/src/souper_harvest.rs index e97b8c0fa..fcf53b0ed 100644 --- a/cranelift/codegen/src/souper_harvest.rs +++ b/cranelift/codegen/src/souper_harvest.rs @@ -129,6 +129,7 @@ fn harvest_candidate_lhs( | ir::Opcode::Clz |...
1
2
0
b2acec116480509b0b5defa2802fdaa24e39d113
Nick Fitzgerald
2020-09-10T18:33:24
Harvest integer comparisons into Souper left-hand side candidates
diff --git a/cranelift/codegen/src/souper_harvest.rs b/cranelift/codegen/src/souper_harvest.rs index 1ca7aaa22..e97b8c0fa 100644 --- a/cranelift/codegen/src/souper_harvest.rs +++ b/cranelift/codegen/src/souper_harvest.rs @@ -365,6 +365,28 @@ fn harvest_candidate_lhs( let a = arg(allocs, 0); ...
1
22
0
5a871711215aac0623ec205c708559bf8ea62440
Nick Fitzgerald
2020-09-02T22:57:18
Do not use the `matches!` macro so we work with older rustc versions
diff --git a/cranelift/codegen/src/souper_harvest.rs b/cranelift/codegen/src/souper_harvest.rs index 1e0d0eb38..1ca7aaa22 100644 --- a/cranelift/codegen/src/souper_harvest.rs +++ b/cranelift/codegen/src/souper_harvest.rs @@ -420,7 +420,10 @@ fn harvest_candidate_lhs( _ => ast::AssignmentRhs::Var, ...
1
4
1
3a6dd832c0fcc51d72e7ef866cda246e8bafe849
Nick Fitzgerald
2020-09-02T22:26:42
Harvest left-hand side superoptimization candidates. Given a clif function, harvest all its integer subexpressions, so that they can be fed into [Souper](https://github.com/google/souper) as candidates for superoptimization. For some of these candidates, Souper will successfully synthesize a right-hand side that is eq...
diff --git a/Cargo.lock b/Cargo.lock index 96d40bf92..38cecde0e 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -390,6 +390,7 @@ dependencies = [ "regalloc", "serde", "smallvec", + "souper-ir", "target-lexicon", "thiserror", "wast", @@ -566,6 +567,7 @@ dependencies = [ "log", "peepmatic-souper", "pretty_e...
8
642
2
43d2799fa254f608395a39f54d9b10bb3e3aae44
Nick Fitzgerald
2020-09-14T20:19:54
clif-util: add the `souper-to-peepmatic` subcommand (#2200) This adds a subcommand to the `clif-util` CLI for exposing the Souper->Peepmatic translation machinery that was introduced in #2192.
diff --git a/cranelift/src/clif-util.rs b/cranelift/src/clif-util.rs index 5dc834730..2948c544f 100644 --- a/cranelift/src/clif-util.rs +++ b/cranelift/src/clif-util.rs @@ -29,6 +29,9 @@ mod print_cfg; mod run; mod utils; +#[cfg(feature = "peepmatic-souper")] +mod souper_to_peepmatic; + #[cfg(feature = "wasm")] m...
2
68
0
39600437d94f6d50176efc468315636a453c11b6
Nick Fitzgerald
2020-09-11T21:20:40
peepmatic-souper: Clean up souper-to-peepmatic name conversion
diff --git a/cranelift/peepmatic/crates/souper/src/lib.rs b/cranelift/peepmatic/crates/souper/src/lib.rs index 66078bfb5..705abe549 100644 --- a/cranelift/peepmatic/crates/souper/src/lib.rs +++ b/cranelift/peepmatic/crates/souper/src/lib.rs @@ -105,7 +105,7 @@ fn convert_lhs(statements: &ast::Arena<ast::Statement>, lhs...
1
6
6
fa6db181a2c13cb405b93c96f41b945dc61fcaa1
Nick Fitzgerald
2020-09-11T21:17:19
Canonicalize commutative instructions to `_imm` form during Souper->Peepmatic
diff --git a/cranelift/peepmatic/crates/souper/src/lib.rs b/cranelift/peepmatic/crates/souper/src/lib.rs index 05cf360fe..66078bfb5 100644 --- a/cranelift/peepmatic/crates/souper/src/lib.rs +++ b/cranelift/peepmatic/crates/souper/src/lib.rs @@ -235,17 +235,9 @@ fn convert_operand( ast::Instruction:...
1
65
59
07d0d32b696dadc704d4e051d6765c984cff08c3
Johnnie Birch
2020-08-19T18:39:44
Adds i64x2.mul for the new backend targeting x64
diff --git a/cranelift/codegen/src/isa/x64/lower.rs b/cranelift/codegen/src/isa/x64/lower.rs index fdaf0be6e..a6079c654 100644 --- a/cranelift/codegen/src/isa/x64/lower.rs +++ b/cranelift/codegen/src/isa/x64/lower.rs @@ -531,6 +531,107 @@ fn lower_insn_to_regs<C: LowerCtx<I = Inst>>( Opcode::Imul =...
1
101
0
22369cfa0dbbbb6e7e843d5acc2e8a8bbbe419f4
Joey Gouly
2020-09-11T17:06:19
arm64: Combine mul + add into madd Copyright (c) 2020, Arm Limited.
diff --git a/cranelift/codegen/src/isa/aarch64/lower_inst.rs b/cranelift/codegen/src/isa/aarch64/lower_inst.rs index dbabc9d58..5e2fed906 100644 --- a/cranelift/codegen/src/isa/aarch64/lower_inst.rs +++ b/cranelift/codegen/src/isa/aarch64/lower_inst.rs @@ -74,23 +74,51 @@ pub(crate) fn lower_insn_to_regs<C: LowerCtx<I ...
1
40
12
3849dc18b1bf3560c43950f049fe553034c424b2
Benjamin Bouvier
2020-09-08T16:23:11
machinst x64: revamp integer immediate emission; In particular: - try to optimize the integer emission into a 32-bit emission, when the high bits are all zero, and stop relying on the caller of `imm_r` to ensure this. - rename `Inst::imm_r`/`Inst::Imm_R` to `Inst::imm`/`Inst::Imm`. - generate a sign-extending mov 32-...
diff --git a/cranelift/codegen/src/isa/x64/inst/args.rs b/cranelift/codegen/src/isa/x64/inst/args.rs index fcb9955cb..4b236ee16 100644 --- a/cranelift/codegen/src/isa/x64/inst/args.rs +++ b/cranelift/codegen/src/isa/x64/inst/args.rs @@ -1001,6 +1001,14 @@ pub enum OperandSize { } impl OperandSize { + pub(crate) ...
5
224
167
d9052d0a9c497d60522a8b69a36ba1430c0bfb85
Benjamin Bouvier
2020-09-08T14:19:06
machinst x64: generate copies of constants during lowering;
diff --git a/cranelift/codegen/src/isa/aarch64/lower.rs b/cranelift/codegen/src/isa/aarch64/lower.rs index e7f4b9a62..3fd0a4e74 100644 --- a/cranelift/codegen/src/isa/aarch64/lower.rs +++ b/cranelift/codegen/src/isa/aarch64/lower.rs @@ -185,12 +185,12 @@ pub(crate) fn put_input_in_reg<C: LowerCtx<I = Inst>>( let f...
2
24
2