|
tvm
|
Functions | |
| TVM_TIRX_DLL Pass | VerifyMemory () |
| Pass variant of VerifyMemory. | |
| TVM_TIRX_DLL Pass | DecorateDeviceScope () |
| Wrap a function body in a device scope region. | |
| TVM_TIRX_DLL Pass | CreateFunctionPass (std::function< ffi::Optional< Function >(Function, IRModule, PassContext)> pass_func, int opt_level, ffi::String name) |
| TVM_TIRX_DLL Pass | VectorizeLoop (bool enable_vectorize=true) |
| Lower vectorization loops. | |
| TVM_TIRX_DLL Pass | StorageRewrite () |
| Rewrite storage allocation pattern. Moves the allocation to outer most possible scope. Trying to share space between allocations to make a static allocation plan when possible. | |
| TVM_TIRX_DLL Pass | UnrollLoop () |
| unroll the constant loop marked by unroll. This pass also automatically attach pragma unroll tag to loops which meets the standard. | |
| TVM_TIRX_DLL Pass | RemoveNoOp () |
| Remove No Op from the Stmt. | |
| TVM_TIRX_DLL Pass | HoistIf () |
| Hoist loop-invariant If statements outside eligible loops. | |
| TVM_TIRX_DLL Pass | RenormalizeSplitPattern () |
| Renormalize the split pattern from floordiv(floormod()) to floormod(floordiv()). | |
| TVM_TIRX_DLL Pass | StmtSimplify () |
| Run statement-level arithmetic simplifications on the TIR Function. | |
| TVM_TIRX_DLL Pass | ConvertSSA () |
| Convert an IRModule to be SSA form. | |
| TVM_TIRX_DLL Pass | LowerThreadAllreduce () |
| Lower cross-thread reductions to target-specific communication. | |
| TVM_TIRX_DLL Pass | MakePackedAPI () |
| Transform the high-level Function to a low-level version that can be used as an API function. | |
| TVM_TIRX_DLL Pass | SplitHostDevice () |
| Annotate, split, and lower host/device functions. | |
| TVM_TIRX_DLL Pass | SkipAssert () |
| skip assert stmt. | |
| TVM_TIRX_DLL Pass | LowerTVMBuiltin () |
| Lower builtin intrinsics. | |
| TVM_TIRX_DLL Pass | LowerIntrin () |
| Lower the target specific function intrinsics in each of the function. | |
| TVM_TIRX_DLL Pass | LowerWarpMemory () |
| Lower warp memory access to low-level device related function calls. | |
| TVM_TIRX_DLL Pass | NarrowDataType (int target_bits) |
| Narrow down PrimExpr datatype in stmt to target_bits. | |
| TVM_TIRX_DLL Pass | ForceNarrowIndexToInt32 () |
| Force to narrow down indexing expressions and integer tensors to int32 dtype. | |
| TVM_TIRX_DLL Pass | BF16ComputeLegalize () |
| Legalize bf16 compute Ops. Add a cast to fp32 before Ops, then add a cast back to bf16. | |
| TVM_TIRX_DLL Pass | FP8ComputeLegalize (ffi::String promote_dtype="float16") |
| Legalize fp8 compute Ops. Add a cast to fp16/fp32 before Ops, then add a cast back to fp8. | |
| TVM_TIRX_DLL Pass | BF16StorageLegalize () |
| Legalize bf16 storage types to u16. | |
| TVM_TIRX_DLL Pass | FP8StorageLegalize () |
| Legalize fp8 storage types to u8. | |
| TVM_TIRX_DLL Pass | PointerValueTypeRewrite () |
| Rewrite the pointer content type of arguments, as well as Alloc internal to the function to use the most frequently accessed type for load/store to avoid pointer casting in backend when possible. | |
| TVM_TIRX_DLL Pass | FlattenTensor () |
| Flatten the multi-dimensional TensorLoad and TensorStore to single dimensional TensorLoad/TensorStore for the TIR not contains opaque block. | |
| TVM_TIRX_DLL Pass | CommonSubexprElim () |
| Implements Common Subexpression Elimination (CSE) for TIR which introduces Bind statements for duplicated sub-expressions. | |
| TVM_TIRX_DLL Pass | BindTarget (Target target) |
| Annotate a Function with a given target. | |
| TVM_TIRX_DLL Pass | AnnotateEntryFunc () |
| Set a Function as the entry point if it is only function in IRModule. | |
| TVM_TIRX_DLL Pass | Filter (ffi::TypedFunction< bool(Function)> fcond) |
| Filter Functions with a given condition. | |
| TVM_TIRX_DLL Pass | TileDispatch () |
| Lower TIRx op calls using registered op dispatchers for the given target. | |
| TVM_TIRX_DLL Pass | LowerTIRxCleanup () |
| Finalize TIRx lowering by applying layout rewriters and cleanup passes. | |
| TVM_TIRX_DLL Pass | LowerTIRx () |
| Lower the TIR to a lower level IR for the given target. | |
| TVM_TIRX_DLL Pass tvm::tirx::transform::AnnotateEntryFunc | ( | ) |
| TVM_TIRX_DLL Pass tvm::tirx::transform::BF16ComputeLegalize | ( | ) |
Legalize bf16 compute Ops. Add a cast to fp32 before Ops, then add a cast back to bf16.
| TVM_TIRX_DLL Pass tvm::tirx::transform::BF16StorageLegalize | ( | ) |
Legalize bf16 storage types to u16.
| TVM_TIRX_DLL Pass tvm::tirx::transform::BindTarget | ( | Target | target | ) |
Annotate a Function with a given target.
| TVM_TIRX_DLL Pass tvm::tirx::transform::CommonSubexprElim | ( | ) |
Implements Common Subexpression Elimination (CSE) for TIR which introduces Bind statements for duplicated sub-expressions.
| TVM_TIRX_DLL Pass tvm::tirx::transform::ConvertSSA | ( | ) |
Convert an IRModule to be SSA form.
This pass handles cases where the same tvm::Var appears in multiple functions within the same module. For example, after extracting a fragment from one function into another, where the same tvm::Var may be defined both as within the body of the original function, and as a parameter within the hoisted function.
| TVM_TIRX_DLL Pass tvm::tirx::transform::CreateFunctionPass | ( | std::function< ffi::Optional< Function >(Function, IRModule, PassContext)> | pass_func, |
| int | opt_level, | ||
| ffi::String | name | ||
| ) |
| TVM_TIRX_DLL Pass tvm::tirx::transform::DecorateDeviceScope | ( | ) |
Wrap a function body in a device scope region.
| TVM_TIRX_DLL Pass tvm::tirx::transform::Filter | ( | ffi::TypedFunction< bool(Function)> | fcond | ) |
Filter Functions with a given condition.
| TVM_TIRX_DLL Pass tvm::tirx::transform::FlattenTensor | ( | ) |
Flatten the multi-dimensional TensorLoad and TensorStore to single dimensional TensorLoad/TensorStore for the TIR not contains opaque block.
| TVM_TIRX_DLL Pass tvm::tirx::transform::ForceNarrowIndexToInt32 | ( | ) |
Force to narrow down indexing expressions and integer tensors to int32 dtype.
The function must not contain S-TIR blocks.
| TVM_TIRX_DLL Pass tvm::tirx::transform::FP8ComputeLegalize | ( | ffi::String | promote_dtype = "float16" | ) |
Legalize fp8 compute Ops. Add a cast to fp16/fp32 before Ops, then add a cast back to fp8.
| promote_dtype | The data type used for type promotion, defaults to float16 |
| TVM_TIRX_DLL Pass tvm::tirx::transform::FP8StorageLegalize | ( | ) |
Legalize fp8 storage types to u8.
| TVM_TIRX_DLL Pass tvm::tirx::transform::HoistIf | ( | ) |
Hoist loop-invariant If statements outside eligible loops.
| TVM_TIRX_DLL Pass tvm::tirx::transform::LowerIntrin | ( | ) |
Lower the target specific function intrinsics in each of the function.
| TVM_TIRX_DLL Pass tvm::tirx::transform::LowerThreadAllreduce | ( | ) |
Lower cross-thread reductions to target-specific communication.
| TVM_TIRX_DLL Pass tvm::tirx::transform::LowerTIRx | ( | ) |
Lower the TIR to a lower level IR for the given target.
| TVM_TIRX_DLL Pass tvm::tirx::transform::LowerTIRxCleanup | ( | ) |
Finalize TIRx lowering by applying layout rewriters and cleanup passes.
| TVM_TIRX_DLL Pass tvm::tirx::transform::LowerTVMBuiltin | ( | ) |
Lower builtin intrinsics.
| TVM_TIRX_DLL Pass tvm::tirx::transform::LowerWarpMemory | ( | ) |
Lower warp memory access to low-level device related function calls.
| TVM_TIRX_DLL Pass tvm::tirx::transform::MakePackedAPI | ( | ) |
Transform the high-level Function to a low-level version that can be used as an API function.
The main task of this function is to create code to :
let num_packed_args = len(api_args);
if num_packed_args is zero: f()
if num_packed_args is not zero: f(void *, TVMFFIAny* packed_args, int num_packed_args, api_arg_k, api_arg_k+1, ... api_arg_n, TVMFFIAny* out_ret_val)
where n == len(api_args), k == num_packed_args
| TVM_TIRX_DLL Pass tvm::tirx::transform::NarrowDataType | ( | int | target_bits | ) |
Narrow down PrimExpr datatype in stmt to target_bits.
| target_bits | The target bits |
| TVM_TIRX_DLL Pass tvm::tirx::transform::PointerValueTypeRewrite | ( | ) |
Rewrite the pointer content type of arguments, as well as Alloc internal to the function to use the most frequently accessed type for load/store to avoid pointer casting in backend when possible.
| TVM_TIRX_DLL Pass tvm::tirx::transform::RemoveNoOp | ( | ) |
| TVM_TIRX_DLL Pass tvm::tirx::transform::RenormalizeSplitPattern | ( | ) |
Renormalize the split pattern from floordiv(floormod()) to floormod(floordiv()).
| TVM_TIRX_DLL Pass tvm::tirx::transform::SkipAssert | ( | ) |
skip assert stmt.
| TVM_TIRX_DLL Pass tvm::tirx::transform::SplitHostDevice | ( | ) |
Annotate, split, and lower host/device functions.
This pass first annotates device regions within host functions, then splits them into host and device-side Functions, and finally lowers host-to-device calls into the device kernel launch ABI.
The resulting host-side function will keep the same tvm::attr::kTarget attribute (e.g. T.target("cuda", host=T.target("llvm"))). This ensures that MakePackedAPI knows which device type should be used for the input tensors.
The resulting device-side function will have the host stripped from its target attribute (e.g. T.target("cuda")).
| TVM_TIRX_DLL Pass tvm::tirx::transform::StmtSimplify | ( | ) |
Run statement-level arithmetic simplifications on the TIR Function.
| TVM_TIRX_DLL Pass tvm::tirx::transform::StorageRewrite | ( | ) |
Rewrite storage allocation pattern. Moves the allocation to outer most possible scope. Trying to share space between allocations to make a static allocation plan when possible.
| TVM_TIRX_DLL Pass tvm::tirx::transform::TileDispatch | ( | ) |
Lower TIRx op calls using registered op dispatchers for the given target.
Lowers CUDA index calls to ordinary bindings using the independent device-entry launch configuration, preserving execution-context information during dispatch.
| TVM_TIRX_DLL Pass tvm::tirx::transform::UnrollLoop | ( | ) |
unroll the constant loop marked by unroll. This pass also automatically attach pragma unroll tag to loops which meets the standard.
| TVM_TIRX_DLL Pass tvm::tirx::transform::VectorizeLoop | ( | bool | enable_vectorize = true | ) |
Lower vectorization loops.
Target-dependent vectorization uses the Function's target attribute, not an ambient target context or nested target attributes. Target-independent fixed-width loops do not require a target. Code needing different vectorization targets must be separated into functions before this pass.
| enable_vectorize | Whether vectorization is enabled. |
| TVM_TIRX_DLL Pass tvm::tirx::transform::VerifyMemory | ( | ) |