MCPcopy Create free account
hub / github.com/apache/tvm / replace_all_uses

Method replace_all_uses

python/tvm/relax/binding_rewrite.py:61–72  ·  view source on GitHub ↗

Replace all uses of old_var with new_var. Parameters ---------- old_var : Var The old variable to replace. new_var : Var The new variable to replace with.

(self, old_var: Var, new_var: Var)

Source from the content-addressed store, hash-verified

59 )
60
61 def replace_all_uses(self, old_var: Var, new_var: Var) -> None:
62 """
63 Replace all uses of old_var with new_var.
64
65 Parameters
66 ----------
67 old_var : Var
68 The old variable to replace.
69 new_var : Var
70 The new variable to replace with.
71 """
72 _ffi_api.dfb_rewrite_replace_all_uses(self, old_var, new_var) # type: ignore
73
74 def add_binding(self, binding: Binding) -> None:
75 return _ffi_api.dfb_rewrite_add_binding(self, binding) # type: ignore

Callers 1

Calls

no outgoing calls

Tested by 1