[Mlir-commits] [mlir] [MLIR][XeGPU] Sg to Lane distribute convert_layout redistributing broadcasted data (PR #215645)

Jianhui Li llvmlistbot at llvm.org
Mon Aug 31 23:10:08 PDT 2026


Jianhui-Li wrote:

> About generalizing the condition:

> On equal participant lanes — both readings reject the case this PR is for:
> 
> effective lane_layout	product	parent product
> input `slice<layout<lane_layout = [8, 1, 2], order = [0, 2, 1]>, dims = [0]>`	`[1, 2]`	2	16
> target `layout<lane_layout = [8, 1]>`	`[8, 1]`	8	8
> So I required the input to cover the subgroup and the target's count to divide it, with lanes [8, 16) checked to be replicas of [0, 8) — which is what `computeStaticDistributedCoords` gives them, and what `convert_layout_partial_subgroup` already assumes. Strict equality would instead need the target written as `slice<layout<lane_layout = [8, 1, 2]>, dims = [2]>`. Which do you prefer?

I think it is OK to assume the xegpu implementation always replicates the distribution to non-participant lanes when the layout only covers part of subgroup.  

https://github.com/llvm/llvm-project/pull/215645


More information about the Mlir-commits mailing list