24 #ifndef TVM_RUNTIME_VM_BYTECODE_H_ 25 #define TVM_RUNTIME_VM_BYTECODE_H_ 28 #include <tvm/runtime/logging.h> 243 const std::vector<RegName>& args);
254 DLDataType dtype,
RegName dst);
265 DLDataType dtype,
RegName dst);
285 const std::vector<RegName>& free_vars,
RegName dst);
404 #endif // TVM_RUNTIME_VM_BYTECODE_H_ std::ostream & operator<<(std::ostream &os, const ObjectRef &n)
Definition: repr_printer.h:97
Index num_freevar
The number of free variables to capture.
Definition: bytecode.h:193
Index clo_index
The index into the function table.
Definition: bytecode.h:191
Index packed_index
The index into the packed function table.
Definition: bytecode.h:131
RegName result
The register to return.
Definition: bytecode.h:123
Index false_offset
The program counter offset for the false branch.
Definition: bytecode.h:147
int64_t * shape
The shape of tensor.
Definition: bytecode.h:99
Opcode op
The instruction opcode.
Definition: bytecode.h:85
Index pc_offset
The jump offset.
Definition: bytecode.h:167
Index src_device_index
The index of the source device to copy from.
Definition: bytecode.h:217
runtime implementation for LibTorch/TorchScript.
Definition: analyzer.h:36
Index output_size
The number of outputs produced by the packed function.
Definition: bytecode.h:135
RegName tensor
Definition: bytecode.h:208
Index val
Definition: bytecode.h:163
DLDataType dtype
The datatype of tensor to be allocated.
Definition: bytecode.h:101
A single virtual machine instruction.
Definition: bytecode.h:83
Index const_index
Definition: bytecode.h:159
RegName * closure_args
The closure arguments as an array.
Definition: bytecode.h:119
DLDataType dtype_hint
The hint of the dtype.
Definition: bytecode.h:203
RegName dst
The destination register.
Definition: bytecode.h:88
Index dst_device_index
The index of the destination deviceto copy to.
Definition: bytecode.h:219
Index func_index
The function to call.
Definition: bytecode.h:151
Index device_index
The index of the device on which the allocation will be made.
Definition: bytecode.h:205
RegName newshape
Definition: bytecode.h:212
Index offset
The offset into the storage to allocate from.
Definition: bytecode.h:95
RegName object
The register to project from.
Definition: bytecode.h:171
Index field_index
The field to read out.
Definition: bytecode.h:173
RegName src
Definition: bytecode.h:215
uint32_t ndim
The number of dimensions.
Definition: bytecode.h:97
int64_t RegName
A register name.
Definition: bytecode.h:38
RegName target
The register containing the target value.
Definition: bytecode.h:143
Index arity
The arity of the packed function.
Definition: bytecode.h:133
RegName closure
The register containing the closure.
Definition: bytecode.h:115
Tensor shape(const Tensor &src, DataType dtype, const std::string name="T_shape", const std::string tag=kInjective)
Get the shape of input tensor.
Definition: transform.h:1768
RegName storage
The storage to allocate from.
Definition: bytecode.h:93
int64_t Index
An alias for the integer type used ubiquitously in the VM.
Definition: bytecode.h:43
Index num_args
The number of arguments to the function.
Definition: bytecode.h:153
Index alignment
The alignment of the allocation.
Definition: bytecode.h:201
Opcode
An enumeration of Relay's opcodes.
Definition: bytecode.h:50
Index true_offset
The program counter offset for the true branch.
Definition: bytecode.h:145
RegName * datatype_fields
The fields as an array.
Definition: bytecode.h:186
RegName allocation_size
The size of the allocation.
Definition: bytecode.h:199
Index num_closure_args
The number of arguments to the closure.
Definition: bytecode.h:117
RegName * free_vars
The free variables as an array.
Definition: bytecode.h:195
RegName * invoke_args_registers
The registers containing the arguments.
Definition: bytecode.h:155
Index constructor_tag
The datatype's constructor tag.
Definition: bytecode.h:182
RegName shape_register
The register to read the shape out of.
Definition: bytecode.h:109
RegName from
The source register for a move operation.
Definition: bytecode.h:127
RegName test
The register containing the test value.
Definition: bytecode.h:141
Index num_fields
The number of fields to store in the datatype.
Definition: bytecode.h:184
RegName * packed_args
The arguments to pass to the packed function.
Definition: bytecode.h:137