Skip to content

Commit 80214dd

Browse files
Fix build after e14ea66
Signed-off-by: Whitney Tsang <[email protected]>
1 parent bf96bc1 commit 80214dd

File tree

3 files changed

+9
-15
lines changed

3 files changed

+9
-15
lines changed

third_party/intel/lib/Analysis/Utility.cpp

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -174,13 +174,11 @@ bool cvtIsSubGroupShuffle(RankedTensorType srcTy, RankedTensorType dstTy) {
174174
StringAttr kWarp = str_attr("warp");
175175
StringAttr kBlock = str_attr("block");
176176

177-
std::optional<LinearLayout> srcLayout =
178-
toLinearLayout(srcTy.getShape(), srcTy.getEncoding(), {});
177+
std::optional<LinearLayout> srcLayout = toLinearLayout(srcTy);
179178
if (!srcLayout)
180179
return false;
181180

182-
std::optional<LinearLayout> dstLayout =
183-
toLinearLayout(dstTy.getShape(), dstTy.getEncoding(), {});
181+
std::optional<LinearLayout> dstLayout = toLinearLayout(dstTy);
184182
if (!dstLayout)
185183
return false;
186184

@@ -262,13 +260,11 @@ bool cvtIsSubGroupTranspose(RankedTensorType srcTy, RankedTensorType dstTy) {
262260
StringAttr kWarp = str_attr("warp");
263261
StringAttr kBlock = str_attr("block");
264262

265-
std::optional<LinearLayout> srcLayout =
266-
toLinearLayout(srcTy.getShape(), srcTy.getEncoding(), {});
263+
std::optional<LinearLayout> srcLayout = toLinearLayout(srcTy);
267264
if (!srcLayout)
268265
return false;
269266

270-
std::optional<LinearLayout> dstLayout =
271-
toLinearLayout(dstTy.getShape(), dstTy.getEncoding(), {});
267+
std::optional<LinearLayout> dstLayout = toLinearLayout(dstTy);
272268
if (!dstLayout)
273269
return false;
274270

third_party/intel/lib/Dialect/TritonIntelGPU/IR/Dialect.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1094,8 +1094,8 @@ struct TritonIntelGPUInferLayoutInterface
10941094
return success();
10951095
}
10961096
// Check whether the encodings are structurally the same.
1097-
const auto &expectedLL = triton::gpu::toLinearLayout(shape, expected, {});
1098-
const auto &gotLL = triton::gpu::toLinearLayout(shape, got, {});
1097+
const auto &expectedLL = triton::gpu::toLinearLayout(shape, expected);
1098+
const auto &gotLL = triton::gpu::toLinearLayout(shape, got);
10991099
if (expectedLL != gotLL) {
11001100
return emitOptionalError(loc, "Expected result encoding ", expected,
11011101
" but was ", got);
@@ -1117,7 +1117,7 @@ struct TritonIntelGPUInferLayoutInterface
11171117
// Once LinearLayouts are more widely used, we can remove
11181118
// inferReshapeOpLegacyEncoding and simply use LLs.
11191119
auto *ctx = getContext();
1120-
auto src = toLinearLayout(srcShape, srcEnc, {});
1120+
auto src = toLinearLayout(srcShape, srcEnc);
11211121

11221122
if (product(srcShape) != product(dstShape)) {
11231123
return emitOptionalError(loc, "numel of dst shape does not match "

third_party/intel/lib/TritonIntelGPUToLLVM/ConvertLayoutOpToLLVM.cpp

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,10 +28,8 @@ struct ConvertLayoutOpUsingLinearLayoutsConversion
2828
auto dstTy = op.getType();
2929

3030
LinearLayout conversion = minimalCvtLayout(srcTy, dstTy);
31-
LinearLayout srcLayout =
32-
toLinearLayout(srcTy.getShape(), srcTy.getEncoding(), {});
33-
LinearLayout dstLayout =
34-
toLinearLayout(dstTy.getShape(), dstTy.getEncoding(), {});
31+
LinearLayout srcLayout = toLinearLayout(srcTy);
32+
LinearLayout dstLayout = toLinearLayout(dstTy);
3533

3634
StringAttr kLane = str_attr("lane");
3735

0 commit comments

Comments
 (0)