-
Notifications
You must be signed in to change notification settings - Fork 3.8k
[TVMScript] T.axis.remap syntax sugar for TVMScript printer
#13743
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
Thanks for contributing to TVM! Please refer to the contributing guidelines https://tvm.apache.org/docs/contribute/ for useful information and tips. Please request code reviews from Reviewers by @-ing them in a comment.
Generated by tvm-bot |
junrushao
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Will need to merge #13785 before getting this in
|
@tvm-bot rerun |
|
@cyx-6 you will have to rebase again :-) |
fix outdated code fix outdated unittest refactor
Co-authored-by: Junru Shao <junrushao1994@gmail.com>
…#13743) This PR implements the syntax sugar of `T.axis.remap` for new TVMScript printer. This syntax sugar will synthesize the `T.axis.remap` when there are more than 2 simple block iterating variable bindings. For example, it will change ```python for i, j, k in T.grid(128, 128, 128): with T.block("update"): vi = T.axis.spatial(128, i) vj = T.axis.spatial(128, j) vk = T.axis.reduce(128, k) ``` into ```python for i, j, k in T.grid(128, 128, 128): with T.block("update"): vi, vj, vk = T.axis.remap("SSR", [i, j, k]) ``` Co-authored-by: Junru Shao <junrushao1994@gmail.com>
This PR implements the syntax sugar of
T.axis.remapfor new TVMScript printer. This syntax sugar will synthesize theT.axis.remapwhen there are more than 2 simple block iterating variable bindings. For example, it will changeinto