[Mlir-commits] [mlir] [mlir][ArmSME] Support 2-way widening outer products (PR #78975)
Benjamin Maxwell
llvmlistbot at llvm.org
Tue Jan 30 07:56:40 PST 2024
================
@@ -814,6 +814,295 @@ let arguments = (ins
}];
}
+class OuterProductWideningBase<string mnemonic,
+ list<Type> allowedInputVectorTypes,
+ list<Type> allowedResultVectorTypes,
+ int numOuterProducts> :
+ ArmSME_Op<mnemonic, [
+ ArmSMETileOpInterface,
+ AttrSizedOperandSegments,
+ AllTypesMatch<["lhs", "rhs"]>,
+ HasMatchingMaskTypeConstraint<"lhs", "lhsMask">,
+ HasMatchingMaskTypeConstraint<"rhs", "rhsMask">,
+ PredOpTrait<
+ "both `lhsMask` and `rhsMask` should be provided or neither",
+ CPred<"bool(getLhsMask()) == bool(getRhsMask())">
+ >,
+ OptionalTypesMatchWith<"result and acc have the same type",
+ "result", "acc", "::llvm::cast<Type>($_self)">,
+ // this trait ensures the input type match the correct output type for ops
+ // that takes multiple inputs and outputs (i.e., 4-way).
----------------
MacDue wrote:
```suggestion
// This trait ensures the input types match the correct output type for ops
// that takes multiple inputs and outputs (i.e., 4-way).
```
https://github.com/llvm/llvm-project/pull/78975
More information about the Mlir-commits
mailing list