Uh oh!
There was an error while loading. Please reload this page.
More wasm SIMD updates - #1092
Conversation
rust-highfive
commented
Mar 19, 2021
r? @Amanieu (rust-highfive has picked a reviewer for you, use r? to override) |
alexcrichton
commented
Mar 19, 2021
I'll note that this is blocked on rust-lang/rust#83285 for landing, but I wanted to go ahead and put this up for review if others have time. |
Amanieu
commented
Mar 20, 2021
I had a quick look through and the changes LTGM. |
ed370fa to
c8bfaf9Comparealexcrichton
commented
Mar 20, 2021
I was struck with inspiration after reading over #1093 and I've updated this to also improve support for atomic intrinsics by always including them. Updates to the upstream proposal mean that this is now feasible (yay!) which means we are now also testing them on CI that they create the right instruction (and should catch bugs like #1093 earlier) This is still, however, waiting on a nightly to get fully enabled. I realized that I was testing with a build of Wasmtime, however, that had a compile-time feature enabled to get more SIMD things working so I updated the docker container for wasm tests to compile a local version of Wasmtime. This does add ~5min to the wasm builder, although Wasmtime will hopefully change in the near future so we can use the precompiled binaries again. |
* Sync with the latest LLVM which has a few new intrinsic names * Move explicit tests back to `assert_instr` since `assert_instr` now supports specifying const-generic arguments inline. * Enable tests where wasmtime implements the instruction as well as LLVM. * Ensure there are tests for all functions that can be tested at this time (those that aren't unimplemented in wasmtime). There's still a number of `assert_instr` tests that are commented out. These are either because they're unimplemented in wasmtime at the moment or LLVM doesn't have an implementation for the instruction yet.
While they're not very useful in single-threaded mode this makes them more useful for building libraries because you don't have to always recompile the standard library to get the desired effect. Additionally it helps us enable tests on CI for these functions, since the instructions will now validate without shared memory (thankfully!).
alexcrichton
commented
Mar 21, 2021
Ok should be good to go now! |
Amanieu
commented
Mar 21, 2021
As part of #1066 I changed the intrinsics in What do you think of changing this to use |
alexcrichton
commented
Mar 21, 2021
Oh perfect! I was going to bring that up on the stabilization issue because I agree that these should all have static assertions that only valid constants can be provided. I'll update all wasm bits to have a static assertion. |
alexcrichton
commented
Mar 21, 2021
Ok I've added a |
Amanieu
commented
Mar 21, 2021
Great work! |
assert_instrsinceassert_instrnowsupports specifying const-generic arguments inline.
time (those that aren't unimplemented in wasmtime).
There's still a number of
assert_instrtests that are commented out.These are either because they're unimplemented in wasmtime at the moment
or LLVM doesn't have an implementation for the instruction yet.