Caleb Zulawski
18077e9fd6
[WebAssembly] Re-land 8392bf6000ad
...
Correctly handle single-element vectors to fix an assertion failure. Add tests
that were missing from the original commit.
Differential Revision: D151782
2023-06-09 08:42:27 -07:00
Thomas Lively
100c756d96
Revert "Improve WebAssembly vector bitmask, mask reduction, and extending"
...
This reverts commit 8392bf6000ad039bd0e55383d40a05ddf7b4af13.
The commit missed some edge cases that led to crashes. Reverting to resolve
downstream breakage while a fix is pending.
2023-06-08 14:36:29 -07:00
Caleb Zulawski
8392bf6000
Improve WebAssembly vector bitmask, mask reduction, and extending
...
This is inspired by a recently filed Rust issue noting poor codegen for vector masks (https://github.com/rust-lang/portable-simd/issues/351 ).
Reviewed By: tlively
Differential Revision: https://reviews.llvm.org/D151782
2023-06-07 10:20:22 -07:00
Luke Lau
fb6602616c
[WebAssembly] Explicitly add {z,s}ext so extends are selected
...
During DAG legalization, {u,s}itofp instructions on v2i8, v2i16, v4i8
and v4i16 types ended up being legalized into scalar instructions, when
they could just be extended to v2i32/v4i32 instead.
Fixes https://github.com/llvm/llvm-project/issues/57182
Differential Revision: https://reviews.llvm.org/D140916
2023-01-06 12:28:29 +00:00
Luke Lau
2671aa7e84
[WebAssembly][NFC] Add test case for {u,s}itofp on SIMD types
...
These test cases should be updated in a following patch once fixed
Part of https://github.com/llvm/llvm-project/issues/57182
2023-01-03 19:13:16 +00:00