[PATCH] D78488: [SystemZ] Emit VLLEZ from tryShuffleWithZeroVec()

Jonas Paulsson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu May 21 01:36:16 PDT 2020


jonpa updated this revision to Diff 265447.
jonpa added a comment.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.

Patch rebased on again on top of https://reviews.llvm.org/D78486, and also reworked a bit according to latest changes to that patch.

With the current heuristics used here, which basically means to emit a VLLEZ + VLE only in specific cases where there for instance is no other use of the original load (see comments in tryVLLEZ), it seems that it no longer provides any benefit.

The original improvement I saw here was with imagick, but that is already improved with D78486 <https://reviews.llvm.org/D78486>, and improves no further with this. And per the heuristic of that patch that a single VPERM is better than two sequential instructions, it seems actually wrong to introduce a pair of VLLEZ + VLE.

(In order to get imagick to change at all with this I had to remove the checks for a single use of the load. I think that check is needed though, in order to be sure to only use max. two loads instead of one. Only one file on SPEC'17 changes with this as it is. I don't think it should be more aggressive. For instance the case with a single loaded element into a zero vector should already be handled, I hope. I am not quite sure if there could be some other cases that might make sense to handle with different heuristics in tryVLLEZ).

I think this can be abandoned once D78486 <https://reviews.llvm.org/D78486> has been committed.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D78488/new/

https://reviews.llvm.org/D78488

Files:
  llvm/lib/Target/SystemZ/SystemZISelLowering.cpp
  llvm/test/CodeGen/SystemZ/vec-move-25.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D78488.265447.patch
Type: text/x-patch
Size: 8039 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200521/63ca42db/attachment.bin>


More information about the llvm-commits mailing list