MCPcopy Index your code
hub / github.com/apache/tvm / VMFuncScope

Class VMFuncScope

python/tvm/relax/exec_builder.py:46–60  ·  view source on GitHub ↗

An object corresponds to each VM function, working as a context manager.

Source from the content-addressed store, hash-verified

44
45
46class VMFuncScope:
47 """An object corresponds to each VM function, working as a context manager."""
48
49 stack: list["VMFuncScope"] = []
50
51 def __init__(self, exit_callback):
52 self.exit_callback = exit_callback
53
54 def __enter__(self):
55 VMFuncScope.stack.append(self)
56 return self
57
58 def __exit__(self, ptype, value, trace):
59 VMFuncScope.stack.pop()
60 self.exit_callback()
61
62
63@tvm_ffi.register_object("relax.ExecBuilder")

Callers 1

functionMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…