[llvm] [RISCV] Combine vslide{up,down} x, poison -> x (PR #169013)

Luke Lau via llvm-commits llvm-commits at lists.llvm.org
Fri Nov 21 10:14:50 PST 2025


================
@@ -21834,6 +21834,11 @@ SDValue RISCVTargetLowering::PerformDAGCombine(SDNode *N,
       return N->getOperand(0);
     break;
   }
+  case RISCVISD::VSLIDEDOWN_VL:
+  case RISCVISD::VSLIDEUP_VL:
+    if (N->getOperand(1)->isUndef())
----------------
lukel97 wrote:

Ok, just want to check then should we add a test case with undef anyway?

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


More information about the llvm-commits mailing list