19 #ifndef TVM_SCRIPT_IR_BUILDER_IR_FRAME_H_ 20 #define TVM_SCRIPT_IR_BUILDER_IR_FRAME_H_ 31 namespace ir_builder {
53 v->Visit(
"global_vars", &global_var_map);
54 v->Visit(
"functions", &functions);
55 v->Visit(
"attrs", &attrs);
58 static constexpr
const char*
_type_key =
"script.ir_builder.IRModuleFrame";
81 #endif // TVM_SCRIPT_IR_BUILDER_IR_FRAME_H_ Managed reference to an IRBuilderFrameNode.
Definition: base.h:100
#define TVM_DEFINE_MUTABLE_NOTNULLABLE_OBJECT_REF_METHODS(TypeName, ParentType, ObjectName)
Definition: object.h:758
Map< String, GlobalVar > global_var_map
A map from string names to global variables that ensures global uniqueness.
Definition: frame.h:42
Definitions and helper macros for IR/AST nodes.
runtime implementation for LibTorch/TorchScript.
Definition: analyzer.h:36
Map< String, ObjectRef > attrs
IRModule's attributes.
Definition: frame.h:49
void ExitWithScope() final
The method called when exiting RAII scope.
Managed reference to IRModuleFrameNode.
Definition: frame.h:70
Map< GlobalVar, BaseFunc > functions
A map from GlobalVar to all global functions.
Definition: frame.h:47
Visitor class to get the attributes of an AST/IR node. The content is going to be called for each fie...
Definition: reflection.h:52
void VisitAttrs(tvm::AttrVisitor *v)
Definition: base.h:69
TVM_DECLARE_FINAL_OBJECT_INFO(IRModuleFrameNode, IRBuilderFrameNode)
A frame that represents the IRModule frame with functions and global variables.
Definition: frame.h:39
Map container of NodeRef->NodeRef in DSL graph. Map implements copy on write semantics, which means map is mutable but copy will happen when array is referenced in more than two places.
Definition: map.h:1271
static constexpr const char * _type_key
Definition: frame.h:58
void VisitAttrs(tvm::AttrVisitor *v)
Definition: frame.h:51