a named variable in TIR
More...
#include <var.h>
◆ ContainerType
type indicate the container type
◆ Var() [1/4]
| tvm::tirx::Var::Var |
( |
ffi::UnsafeInit |
tag | ) |
|
|
inlineexplicit |
◆ Var() [2/4]
| tvm::tirx::Var::Var |
( |
ffi::ObjectPtr< VarNode > |
n | ) |
|
|
inlineexplicit |
◆ Var() [3/4]
Constructor.
- Parameters
-
| name_hint | variable name |
| dtype | data type |
| span | The location of this object in the source code. |
◆ Var() [4/4]
| tvm::tirx::Var::Var |
( |
ffi::String |
name_hint, |
|
|
Type |
type_annotation, |
|
|
Span |
span = Span() |
|
) |
| |
|
explicit |
Constructor which provides a more detailed type annotation.
- Parameters
-
| name_hint | variable name. |
| type_annotation | The type annotation. |
| span | The location of this object in the source code. |
◆ copy_with_dtype()
| Var tvm::tirx::Var::copy_with_dtype |
( |
PrimType |
dtype | ) |
const |
Make a new copy of the variable with specified dtype.
- Parameters
-
- Returns
- The new variable
◆ copy_with_name()
| Var tvm::tirx::Var::copy_with_name |
( |
const ffi::String & |
name | ) |
const |
Make a new copy of var with same type, but a different nam.
- Parameters
-
| name | The new name to be used. |
- Returns
- the new Var copy
◆ CopyWithSuffix()
| Var tvm::tirx::Var::CopyWithSuffix |
( |
const ffi::String & |
suffix | ) |
const |
Make a new copy of var with same type, append suffix.
- Parameters
-
| suffix | The suffix to be appended. |
- Returns
- the new Var copy
◆ get()
| const VarNode* tvm::tirx::Var::get |
( |
| ) |
const |
|
inline |
Get pointer to the internal value.
- Returns
- the corresponding Variable.
◆ operator->()
| const VarNode* tvm::tirx::Var::operator-> |
( |
| ) |
const |
|
inline |
Get pointer to the internal value.
- Returns
- the corresponding Variable.
◆ _type_container_is_exact
| constexpr bool tvm::tirx::Var::_type_container_is_exact = true |
|
staticconstexpr |
The documentation for this class was generated from the following file: