[llvm] [SPIRV] Addition of matrix multiply accumulate operands (PR #138665)

Dmitry Sidorov via llvm-commits llvm-commits at lists.llvm.org
Thu May 15 09:43:04 PDT 2025


================
@@ -242,6 +242,37 @@ void SPIRVInstPrinter::printInst(const MCInst *MI, uint64_t Address,
           }
           break;
         }
+        case SPIRV::OpSubgroupMatrixMultiplyAccumulateINTEL: {
+          const unsigned NumOps = MI->getNumOperands();
+          if (NumFixedOps == NumOps)
+            break; // No extra operands, so no flags to process
+          OS << ' ';
+          // Extract the last operand only if it exists
+          if (NumOps > NumFixedOps) {
----------------
MrSidims wrote:

Do we need this check? I'd suggest to remove it and either:
add an assertion or fatal error that NumOps is never < NumFixedOps
or
merge this check with the check on line 247

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


More information about the llvm-commits mailing list