================
@@ -1153,8 +1159,7 @@ DemandedVL 
RISCVVLOptimizerImpl::getMinimumVLForUser(const MachineInstr &UserMI,
   if (RISCV::isVLKnownLE(*MRI, DemandedVLs.lookup(&UserMI).VL, VLOp))
     MinimumVL = DemandedVLs.lookup(&UserMI);
 
-  if ((IsVUNZIP && UserOp.getOperandNo() == 2) ||
-      (IsVZIP && UserOp.getOperandNo() == 4))
+  if (IsVUNZIP && UserOp.getOperandNo() == 2)
----------------
wangpc-pp wrote:

For `vzip.vv`, the two sources (operands 2 and 3) are read only for 
ceil(vl/2)/floor(vl/2) elements per the spec (`norm:vzip-vv_op`), but they 
inherit the full result-sized VL here. That's a safe upper bound, but it misses 
a chance to halve the demanded VL of a source producer. Could be a follow-up if 
not addressed here. BTW, we don't need to remove `IsVZIP` if we reduce vl for 
`vzip.vv` here. cc @lukel97 is it possible to model `ceil/floor` semantics here?

https://github.com/llvm/llvm-project/pull/210603
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to