jinhongyii commented on code in PR #14219:
URL: https://github.com/apache/tvm/pull/14219#discussion_r1127329476


##########
python/tvm/meta_schedule/tune_context.py:
##########
@@ -44,7 +44,8 @@
 def _normalize_mod(mod: Union[PrimFunc, IRModule]) -> IRModule:
     """Normalize the input to an IRModule"""
     if isinstance(mod, PrimFunc):
-        mod = mod.with_attr("global_symbol", "main")
+        if not (mod.attrs and "global_symbol" in mod.attrs):
+            mod = mod.with_attr("global_symbol", "main")
         mod = mod.with_attr("tir.noalias", True)
         mod = IRModule({"main": mod})

Review Comment:
   Good thought! The inconsistency of global_symbol in the case I'm handling 
comes from the applying MS phase, so it seems I should change the code there 
and revert this change. I will send a fix PR later



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to