tilelang.language.warpgroup module#

The language interface for tl programs.

tilelang.language.warpgroup.WarpSpecialize(*warp_group_idx)#

Tools to construct a warp group frame.

Parameters:

warp_group_idx (int) – A integer representing warp group index Or a list of integers representing blockDim.(x|y|z) if the value is -1, we skip the threadIdx.x binding.

Returns:

  • res (Tuple[frame.LaunchThreadFrame]) – The result LaunchThreadFrame.

  • Examples – >>> T.ws(0) -> if tx < 128 >>> T.ws(1) -> if tx >= 128 and tx < 256 >>> T.ws(0, 1) -> if tx < 128 or (tx >= 128 and tx < 256)

class tilelang.language.warpgroup.WarpSpecializeFrame#

Bases: TIRFrame

WarpSpecializeFrame is a custom TIRFrame that manages warp group indices and handles the entry and exit of the kernel launch scope.

tilelang.language.warpgroup.ws(*warp_group_idx)#

Tools to construct a warp group frame.

Parameters:

warp_group_idx (int) – A integer representing warp group index Or a list of integers representing blockDim.(x|y|z) if the value is -1, we skip the threadIdx.x binding.

Returns:

  • res (Tuple[frame.LaunchThreadFrame]) – The result LaunchThreadFrame.

  • Examples – >>> T.ws(0) -> if tx < 128 >>> T.ws(1) -> if tx >= 128 and tx < 256 >>> T.ws(0, 1) -> if tx < 128 or (tx >= 128 and tx < 256)