tvm
Public Types | Public Member Functions | Static Public Member Functions | List of all members
tvm::IRModule Class Reference

Managed reference class to IRModuleNode. More...

#include <module.h>

Inheritance diagram for tvm::IRModule:
Collaboration diagram for tvm::IRModule:

Public Types

using ContainerType = IRModuleNode
 Declare the container type. More...
 

Public Member Functions

 IRModule (Map< GlobalVar, BaseFunc > functions, SourceMap map={}, DictAttrs attrs=DictAttrs(), Map< String, Array< GlobalInfo >> global_infos={})
 constructor More...
 
 IRModule ()
 default constructor More...
 
 IRModule (ObjectPtr< Object > n)
 constructor More...
 
IRModuleNodeoperator-> () const
 
IRModule ShallowCopyIRModule (IRModule mod)
 Create a shallow copy of an IRModule. More...
 
 TVM_DEFINE_OBJECT_REF_COW_METHOD (IRModuleNode)
 

Static Public Member Functions

static IRModule FromExpr (const RelaxExpr &expr, const Map< GlobalVar, BaseFunc > &global_funcs={})
 As for FromExprInContext, but assuming expr is bound to 'main' and no imports. More...
 

Detailed Description

Managed reference class to IRModuleNode.

See also
IRModuleNode

Member Typedef Documentation

◆ ContainerType

Declare the container type.

Constructor & Destructor Documentation

◆ IRModule() [1/3]

tvm::IRModule::IRModule ( Map< GlobalVar, BaseFunc functions,
SourceMap  map = {},
DictAttrs  attrs = DictAttrs(),
Map< String, Array< GlobalInfo >>  global_infos = {} 
)
explicit

constructor

Parameters
functionsFunctions in the module.
mapThe module source map.
attrsThe module meta-data attributes.
global_infosGlobal infos in the module.

◆ IRModule() [2/3]

tvm::IRModule::IRModule ( )
inline

default constructor

◆ IRModule() [3/3]

tvm::IRModule::IRModule ( ObjectPtr< Object >  n)
inlineexplicit

constructor

Parameters
nThe object pointer.

Member Function Documentation

◆ FromExpr()

static IRModule tvm::IRModule::FromExpr ( const RelaxExpr expr,
const Map< GlobalVar, BaseFunc > &  global_funcs = {} 
)
static

As for FromExprInContext, but assuming expr is bound to 'main' and no imports.

◆ operator->()

IRModuleNode* tvm::IRModule::operator-> ( ) const
inline
Returns
mutable pointers to the node.

◆ ShallowCopyIRModule()

IRModule tvm::IRModule::ShallowCopyIRModule ( IRModule  mod)

Create a shallow copy of an IRModule.

Parameters
modThe module to copy.
Returns
The copied module.

◆ TVM_DEFINE_OBJECT_REF_COW_METHOD()

tvm::IRModule::TVM_DEFINE_OBJECT_REF_COW_METHOD ( IRModuleNode  )

The documentation for this class was generated from the following file: