tilelang.cpu.language.kernel¶
CPU dialect of T.Kernel: the common launch plus CPU launch annotations.
Functions¶
|
Construct a kernel launch frame for CPU: a grid of tile programs. |
Module Contents¶
- tilelang.cpu.language.kernel.Kernel(*blocks, prelude=None)¶
Construct a kernel launch frame for CPU: a grid of tile programs.
The grid becomes the outer loop nest of the generated function and each tile program runs as a plain serial body;
T.Parallelloops are lowered to serial loops. There are no SIMT threads, so this dialect has nothreadsandT.get_thread_binding()is rejected at compile time.- Parameters:
*blocks (int | PrimExpr) – Grid extent along each axis (1-3 dimensions). The launch yields one program index per axis.
prelude (str, optional) – C source injected before the generated kernel, e.g.
#includelines or helper functions.
- Return type:
Examples
with T.Kernel(T.ceildiv(N, 128)) as bx: for i in T.Parallel(128): ...