Skip to content

Commit fb2506c

Browse files
committed
address comments
1 parent 67edbab commit fb2506c

File tree

1 file changed

+14
-12
lines changed

1 file changed

+14
-12
lines changed

mlir/lib/Dialect/XeGPU/IR/XeGPUOps.cpp

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -646,19 +646,21 @@ LogicalResult DpasOp::verify() {
646646
if (numElems % factor != 0)
647647
return emitOpError("Expecting B operand to be a multiple of 32 bits.");
648648
return success();
649-
} else { // SIMD code
650-
if (lhsRank != 2 || (rhsRank != 2 && rhsRank != 3) || resRank != 2)
651-
return emitOpError(
652-
"expecting lhs and result to be a 2D vector, and rhs to be either "
653-
"2D or 3D (packed) vector.");
654-
auto bK = rhsRank == 3 ? rhsShape[0] * rhsShape[2] : rhsShape[0];
655-
if (bK != lhsShape[1])
656-
return emitOpError("K-dimension mismatch.");
657-
if (lhsShape[0] != resShape[0])
658-
return emitOpError("M-dimension mismatch.");
659-
if (rhsShape[1] != resShape[1])
660-
return emitOpError("N-dimension mismatch.");
661649
}
650+
651+
// SIMD code
652+
if (lhsRank != 2 || (rhsRank != 2 && rhsRank != 3) || resRank != 2)
653+
return emitOpError(
654+
"expecting lhs and result to be a 2D vector, and rhs to be either "
655+
"2D or 3D (packed) vector.");
656+
auto bK = rhsRank == 3 ? rhsShape[0] * rhsShape[2] : rhsShape[0];
657+
if (bK != lhsShape[1])
658+
return emitOpError("K-dimension mismatch.");
659+
if (lhsShape[0] != resShape[0])
660+
return emitOpError("M-dimension mismatch.");
661+
if (rhsShape[1] != resShape[1])
662+
return emitOpError("N-dimension mismatch.");
663+
662664
return success();
663665
}
664666

0 commit comments

Comments
 (0)