Is there any way to imply variable reference using name instead of pointer?

Hi all, I’m just curious is it possible in tvm to imply the same variable reference using its symbolic value? For example, I want to build up an id function in TIR, I would have written as:

from tvm import te, tir
import tvm

id_func = tir.PrimFunc(

But this would not compile since tvm refers to pointer equality, and does not consider the te.var('a') in the parameter list and body to be the same. So, is pointer-equality the only way to go?

te.var constructs a new variable, so calling it twice will construct two variables (with the same name, which doesn’t have any meaning). Two objects are the same variable if they share the same VarNode.