You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tvm.apache.org by GitBox <gi...@apache.org> on 2022/06/29 17:33:33 UTC

[GitHub] [tvm-rfcs] tqchen commented on pull request #84: [RFC] Name mangling in IRModules

tqchen commented on PR #84:
URL: https://github.com/apache/tvm-rfcs/pull/84#issuecomment-1170277851

   Thanks @gigiblender ! a few points for consideration:
   
   - Ideally NameSupply should interact well with our current linkage spec, e.g. if a function have an attribute `global_symbol`, it means the name is "final"(because external users are expecting to look it up with that name), likely we need to have global. Anything that does not have a `global_symbol` attr can subject to change.
   - Would be useful to initialize a NameSupply from an existing IRModule, so it does not need to be carried through out passes and is only needed for pass that regenerate global vars.
   
   In addition to that, it would be really nice to get some smart naming resolve mechanism.
   
   For example, it would be really nice to have the following effect (by parsing the suffix integer separately from prefix string
   
   ```python
   x = get_next_name("fun12", existing_names=["func12", "func13", "func4"])
   assert x == "func14"
   ```
   
   This is to avoid the case where we have "func12_0_0_0_0" when multiple set of prefixes are called and they usually looks confusion.
   
   
   
   


-- 
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: commits-unsubscribe@tvm.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org