This patch adds a new shuffle kind useful for transposing a 2xn matrix. These transpose shuffle masks read corresponding even- or odd-numbered vector elements from two n-dimensional source vectors and write each result into consecutive elements of an n-dimensional destination vector. The transpose shuffle kind is meant to model the TRN1 and TRN2 AArch64 instructions. As such, this patch also considers transpose shuffles in the AArch64 implementation of getShuffleCost.
Details
Details
Diff Detail
Diff Detail
- Repository
- rL LLVM
Event Timeline
include/llvm/Analysis/TargetTransformInfo.h | ||
---|---|---|
642 ↗ | (On Diff #143623) | Not sure why indentation change is needed |
lib/Analysis/TargetTransformInfo.cpp | ||
707 ↗ | (On Diff #143623) | would it be more accurate to say '..such that one vector contains _interleaved_ elements from all the even numbered rows ..." |
737 ↗ | (On Diff #143623) | Test 4 and 5 could be perhaps combined into one loop? |
include/llvm/Analysis/TargetTransformInfo.h | ||
---|---|---|
642 ↗ | (On Diff #143623) | Ah, clang-format decided to do that. I will undo the formatting for now. |
lib/Analysis/TargetTransformInfo.cpp | ||
707 ↗ | (On Diff #143623) | Sounds good to me. |
737 ↗ | (On Diff #143623) | Yes, that would probably be a little more straightforward. Thanks! |
Comment Actions
LGTM. Probably wait a day before committing in case Renato/others have a comment/suggestion.