-
Notifications
You must be signed in to change notification settings - Fork 76
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
[aievec] Add vector.transpose to aievec.shuffle lowering #1527
[aievec] Add vector.transpose to aievec.shuffle lowering #1527
Conversation
for (int64_t i = 0; i < static_cast<int64_t>(perm.size() - 2); ++i) | ||
if (perm[i] != i) | ||
return failure(); | ||
if (perm[perm.size() - 1] != static_cast<int64_t>(perm.size() - 2)) |
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.
Can we do perm.back()
here? It's easier to understand. Also, it seems that vector.transpose
doesn't prevent you from creating a 0-D vector and empty permutation attribute, so you might want to check the boundary.
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.
Empty and identity permutations fold away, so they can be safely ignored.
48b257e
to
25b1f54
Compare
25b1f54
to
7ab4ddd
Compare
7ab4ddd
to
3576dfb
Compare
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. As mentioned in the comment, we need a follow-up PR on the support of vector<2x8xi32>
or vector<2x32xi8>
.
Just for the record, there is no shuffle mode for |
No description provided.