This is an archive of the discontinued LLVM Phabricator instance.

[X86][SSE] Lower shuffle as ANY_EXTEND_VECTOR_INREG
ClosedPublic

Authored by RKSimon on Aug 5 2019, 6:01 AM.

Details

Summary

On SSE41+ targets we always lower vector shuffles to ZERO_EXTEND_VECTOR_INREG, even if we don't need the extended bits.

This patch relaxes this so that we lower to ANY_EXTEND_VECTOR_INREG if we can, meaning that shuffle combines have a better idea of what elements need to be kept zero. This helps the multiple reduction code as we can now combine away a lot more of the pack+extend codes.

Diff Detail

Repository
rL LLVM

Event Timeline

RKSimon created this revision.Aug 5 2019, 6:01 AM
Herald added a project: Restricted Project. · View Herald TranscriptAug 5 2019, 6:01 AM
RKSimon updated this revision to Diff 214361.Aug 9 2019, 5:08 AM
RKSimon edited the summary of this revision. (Show Details)

rebased - the widening legalization has made this a lot more trivial

spatel accepted this revision.Aug 9 2019, 7:00 AM

LGTM

This revision is now accepted and ready to land.Aug 9 2019, 7:00 AM
This revision was automatically updated to reflect the committed changes.