GpuLaneIndex¶
The lane of the running thread within its iteration.
声明¶
语法¶
GpuLaneIndex(ttype type, expr? value)
参数¶
Argument |
描述 |
|---|---|
|
the type of the expression, an integer. |
|
always |
返回值¶
The value of the expression.
描述¶
In a kernel whose layout has lanes (see
gpu_kernel_layout), each iteration
runs on lanes consecutive threads of one SIMD-group. The thread index
(GpuThreadIndex) numbers the iterations, and
GpuLaneIndex tells apart the lanes of one: it counts from zero to
lanes - 1. A loop whose iterations the lanes share starts at its first
iteration plus the lane and steps by lanes iterations. Only such a kernel
has one.
示例¶
(GpuLaneIndex
:type (Integer
:kind 4
)
:value nil
)
也可以看看¶
GpuLaneIndex, GpuLaneBroadcast, GpuLaneBarrier, gpu_kernel_layout