tvm_tirx.tirx.script.parallel#
- tvm_tirx.tirx.script.parallel(start, stop=None, *, annotations=None, step=None, dtype=None)#
The parallel For statement.
- Parameters:
start (Expr) – The minimum value of iteration.
stop (Expr) – The maximum value of iteration.
annotations (Dict[str, Any]) – The optional annotations of the For statement. On CPU,
{"codegen.parallel_stride_pattern": True}assigns iterations cyclically: workertexecutest, t + P, t + 2 * P, ...forPworkers. Absent or false selects contiguous chunks. Each loop selects its own policy. When migratingpragma_parallel_stride_pattern, annotate every intended loop, including later loops in the same launch outside the former attribute body.step (Expr) – The optional step value of iteration.
dtype (str, optional) – The dtype of the loop variable, either
"int32"or"uint32". When omitted it is inferred from the bounds.
- Returns:
res (_shared_frame.ForFrame) – The ForFrame.
- Return type: