[Mlir-commits] [mlir] [mlir][spirv] Expand support for TOSA Extended Instruction Set (00100… (PR #176908)

Jakub Kuderski llvmlistbot at llvm.org
Tue Jan 20 05:59:02 PST 2026


================
@@ -20,6 +20,72 @@ namespace mlir::spirv {
 // TOSA Operator Verifiers.
 //===----------------------------------------------------------------------===//
 
+namespace {
+
+template <typename T>
+static LogicalResult verifyConvOp(T op) {
+  ShapedType inputTy = op.getInputType();
+  ShapedType biasTy = op.getBiasType();
+  ShapedType resultTy = op.getResultType();
+
+  Type inputETy = inputTy.getElementType();
+  Type biasETy = biasTy.getElementType();
+  Type resultETy = resultTy.getElementType();
----------------
kuhar wrote:

You could also have an interface that all the conv ops have to (statically) implement. This way we could avoid templates.

I realize the other spirv ops do it the same way as this, so fine to keep as-is.

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


More information about the Mlir-commits mailing list