tvm icon indicating copy to clipboard operation
tvm copied to clipboard

[Relax] Update GlobalVar name in AttachGlobalSymbol

Open Lunderberg opened this issue 1 year ago • 0 comments

Prior to this commit, the relax.transform.AttachGlobalSymbol pass could produce a PrimFunc whose "global_symbol" attribute does not match the name of the GlobalVar. As a result, the PackedFunc that is provided by the compiled module (defined by the "global_symbol") does not match the PackedFunc that is required by the Relax VM (defined by the GlobalVar name).

This commit updates AttachGlobalSymbol to replace the GlobalVar of any function whose "global_symbol" is updated.

Closes https://github.com/apache/tvm/issues/17176

Lunderberg avatar Jul 26 '24 16:07 Lunderberg