[llvm] [RISCV] Support vXf16 vector_shuffle with Zvfhmin. (PR #97491)

Luke Lau via llvm-commits llvm-commits at lists.llvm.org
Wed Jul 3 00:27:56 PDT 2024


https://github.com/lukel97 commented:

There's one vector_shuffle lowering path that emits a scalar load + splat which looks to crash with zvfhmin

```llvm
define <4 x half> @vrgather_shuffle_vv_v4f16(ptr %p) {
  %v = load <4 x half>, ptr %p
  %s = shufflevector <4 x half> %v, <4 x half> undef, <4 x i32> <i32 1, i32 1, i32 1, i32 1>
  ret <4 x half> %s
}
```

It ends up emitting an illegal load: `t24: f16,ch = load<(load (s16) from %ir.p + 2, basealign 8)> t0, t23, undef:i64`

https://github.com/llvm/llvm-project/pull/97491


More information about the llvm-commits mailing list