[Mlir-commits] [mlir] [mlir][xegpu] Derive load_nd lane_data from the hardware block variant (PR #223164)
llvmlistbot at llvm.org
llvmlistbot at llvm.org
Sat Sep 12 11:09:37 PDT 2026
github-actions[bot] wrote:
<!--LLVM CODE FORMAT COMMENT: {clang-format}-->
:warning: C/C++ code formatter, clang-format found issues in your code. :warning:
<details>
<summary>
You can test this locally with the following command:
</summary>
``````````bash
git-clang-format --diff origin/main HEAD --extensions cpp,h -- mlir/include/mlir/Dialect/XeGPU/uArch/uArchBase.h mlir/lib/Dialect/XeGPU/Transforms/XeGPULayoutImpl.cpp --diff_from_common_commit
``````````
:warning:
The reproduction instructions above might return results for more than one PR
in a stack if you are using a stacked PR workflow. You can limit the results by
changing `origin/main` to the base branch/commit you want to compare against.
:warning:
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/mlir/lib/Dialect/XeGPU/Transforms/XeGPULayoutImpl.cpp b/mlir/lib/Dialect/XeGPU/Transforms/XeGPULayoutImpl.cpp
index b33470db6..1a4a3c873 100644
--- a/mlir/lib/Dialect/XeGPU/Transforms/XeGPULayoutImpl.cpp
+++ b/mlir/lib/Dialect/XeGPU/Transforms/XeGPULayoutImpl.cpp
@@ -1883,8 +1883,8 @@ xegpu::setupLoadNdAnchorLayout(xegpu::LayoutKind layoutKind,
if (llvm::is_contained(bHeights, static_cast<int>(height))) {
assert(isValidLaneLayout(consumerInstData, laneLayout, laneData) &&
"Expected the load layout to satisfy uArch block constraints");
- return buildInstDataLayoutWithLane(context, consumerInstData, laneLayout,
- laneData, orderAttr);
+ return buildInstDataLayoutWithLane(context, consumerInstData,
+ laneLayout, laneData, orderAttr);
}
}
@@ -1892,14 +1892,15 @@ xegpu::setupLoadNdAnchorLayout(xegpu::LayoutKind layoutKind,
// DPAS_MX scales land here. A scale whose innermost dim is too narrow to
// spread packed lanes over (width 16 for an 8-bit scale needing 16 lanes of
// 2 elements) cannot be loaded regularly; transformed, it packs down the
- // column instead, which fits. A vertical lane_layout is already a transpose.
+ // column instead, which fits. A vertical lane_layout is already a
+ // transpose.
if (!hasTranspose && !hasTransform &&
consumerInstData[rank - 1] %
(laneLayout[rank - 1] * laneData[rank - 1]) !=
0) {
hasTransform = true;
- laneData = get2DBlockLoadLaneData(elemTy, rank, hasTransform, hasTranspose,
- uArchInstruction, uArch);
+ laneData = get2DBlockLoadLaneData(elemTy, rank, hasTransform,
+ hasTranspose, uArchInstruction, uArch);
}
auto instData = get2DBlockIOInstDataLayout(
``````````
</details>
https://github.com/llvm/llvm-project/pull/223164
More information about the Mlir-commits
mailing list