[llvm] [RISCV][VSETVLI] Prefer VTYPE for immediate known to be less than VLMAX (PR #69759)
Philip Reames via llvm-commits
llvm-commits at lists.llvm.org
Mon Oct 23 11:15:52 PDT 2023
================
@@ -406,13 +406,13 @@ define <16 x i32> @zextload_v16i8_v16i32(ptr %x) {
; LMULMAX1-NEXT: vslidedown.vi v11, v9, 8
; LMULMAX1-NEXT: vsetivli zero, 4, e32, m1, ta, ma
; LMULMAX1-NEXT: vzext.vf4 v10, v11
-; LMULMAX1-NEXT: vsetivli zero, 4, e8, mf2, ta, ma
+; LMULMAX1-NEXT: vsetvli zero, zero, e8, mf2, ta, ma
----------------
preames wrote:
You are unfortunately correct here. This is an absolutely silly choice for the specification to make. It doesn't disallow an implementation to have the sane semantics here, but you're right that we can't rely on this instruction being valid when VLMAX changes (even if VL doesn't.)
https://github.com/llvm/llvm-project/pull/69759
More information about the llvm-commits
mailing list