[Mlir-commits] [mlir] [MLIR][XeVM] Add xevm blockload and blockstore op definition. (PR #158118)
Charitha Saumya
llvmlistbot at llvm.org
Tue Sep 16 11:47:18 PDT 2025
================
@@ -306,6 +307,36 @@ LogicalResult BlockPrefetch2dOp::verify() {
return success();
}
+template <typename OpType, typename = std::enable_if_t<llvm::is_one_of<
+ OpType, BlockLoadOp, BlockStoreOp>::value>>
+LogicalResult verify1DBlockArg(OpType op) {
+ VectorType vTy;
+ if constexpr (std::is_same_v<OpType, BlockLoadOp>)
+ vTy = op.getResult().getType();
+ else
+ vTy = op.getVal().getType();
+ int elemTySize = vTy.getElementType().getIntOrFloatBitWidth() / 8;
+ if (elemTySize == 1) {
+ llvm::SmallSet<int, 5> validSizes{1, 2, 4, 8, 16};
----------------
charithaintc wrote:
nit: seems target specific? add a TODO or move to a dedicated location for HW specifics.
https://github.com/llvm/llvm-project/pull/158118
More information about the Mlir-commits
mailing list