A dialect-agnostic IRBuilder that constructs any IR of TVM. An idiomatic use of this class is to put this inside the RAII with-scope, call dialect-specific methods accordingly. Upon exiting the scope.
More...
#include <base.h>
A dialect-agnostic IRBuilder that constructs any IR of TVM. An idiomatic use of this class is to put this inside the RAII with-scope, call dialect-specific methods accordingly. Upon exiting the scope.
{
T::MatchBuffer(...);
}
}
RAII wrapper function to enter and exit a context object similar to python's with syntax.
Definition with_context.h:59
Managed reference to an IRBuilderNode.
Definition base.h:214
◆ FindFrame()
| ffi::Optional< TFrame > tvm::script::ir_builder::IRBuilderNode::FindFrame |
( |
| ) |
const |
|
inline |
Find a frame of the given type in the stack this->frames from top to bottom.
- Template Parameters
-
| T | The type of the frame to find. |
- Returns
- The frame if found, otherwise std::nullopt.
- Examples
- /workspace/include/tvm/script/ir_builder/base.h.
◆ Get()
| TObjectRef tvm::script::ir_builder::IRBuilderNode::Get |
( |
| ) |
const |
|
inline |
◆ GetCurrentSourceSpan()
| Span tvm::script::ir_builder::IRBuilderNode::GetCurrentSourceSpan |
( |
| ) |
const |
◆ GetLastFrame()
| ffi::Optional< TFrame > tvm::script::ir_builder::IRBuilderNode::GetLastFrame |
( |
| ) |
const |
|
inline |
Get the frame on top of the stack this->frames if its type is TFrame.
- Template Parameters
-
| TFrame | The assumed type of the last frame on stack. |
- Returns
- The frame if the stack is non-empty and the top of the stack is of type
TFrame. Otherwise std::nullopt.
- Examples
- /workspace/include/tvm/script/ir_builder/base.h.
◆ PopSourceSpan()
| void tvm::script::ir_builder::IRBuilderNode::PopSourceSpan |
( |
| ) |
|
◆ PushSourceSpan()
| void tvm::script::ir_builder::IRBuilderNode::PushSourceSpan |
( |
Span |
span | ) |
|
◆ RegisterReflection()
| static void tvm::script::ir_builder::IRBuilderNode::RegisterReflection |
( |
| ) |
|
|
inlinestatic |
◆ SetCurrentSourceSpan()
| ffi::ObjectRef tvm::script::ir_builder::IRBuilderNode::SetCurrentSourceSpan |
( |
ffi::ObjectRef |
obj | ) |
const |
◆ TVM_FFI_DECLARE_OBJECT_INFO_FINAL()
| tvm::script::ir_builder::IRBuilderNode::TVM_FFI_DECLARE_OBJECT_INFO_FINAL |
( |
"script.ir_builder.IRBuilder" |
, |
|
|
IRBuilderNode |
, |
|
|
ffi::Object |
|
|
) |
| |
◆ _type_mutable
◆ frames
| ffi::Array<IRBuilderFrame> tvm::script::ir_builder::IRBuilderNode::frames |
◆ result
| ffi::Optional<ffi::ObjectRef> tvm::script::ir_builder::IRBuilderNode::result |
◆ source_spans
| std::vector<Span> tvm::script::ir_builder::IRBuilderNode::source_spans |
The documentation for this class was generated from the following file:
- include/tvm/script/ir_builder/base.h