[llvm] [GISEL] Add IRTranslation for shufflevector on scalable vector types (PR #80378)

Thorsten Schütt via llvm-commits llvm-commits at lists.llvm.org
Thu Feb 8 02:11:13 PST 2024


================
@@ -1636,6 +1636,24 @@ void MachineVerifier::verifyPreISelGenericInstruction(const MachineInstr *MI) {
 
     break;
   }
+
+  case TargetOpcode::G_SPLAT_VECTOR: {
+    LLT DstTy = MRI->getType(MI->getOperand(0).getReg());
+    LLT SrcTy = MRI->getType(MI->getOperand(1).getReg());
+
+    if (!DstTy.isVector())
+      report("Destination type must be a vector", MI);
----------------
tschuett wrote:

If we limit G_SPLAT_VECTOR to scalable vectors, this should for check for  `isScalableVector()`.

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


More information about the llvm-commits mailing list