[x86] Dramatically improve v8i16 shuffle lowering by not using its
authorChandler Carruth <chandlerc@gmail.com>
Thu, 19 Feb 2015 14:08:24 +0000 (14:08 +0000)
committerChandler Carruth <chandlerc@gmail.com>
Thu, 19 Feb 2015 14:08:24 +0000 (14:08 +0000)
commit7f583a4201d91c973e1c9c7e6783f61cd5cf21e1
tree346a31ce88345c6572597011c10ae06e61386ca4
parent943b2ca2de1daeb1d028584ccf935cef43970863
[x86] Dramatically improve v8i16 shuffle lowering by not using its
terribly complex partial blend logic.

This code path was one of the more complex and bug prone when it first
went in and it hasn't faired much better. Ultimately, with the simpler
basis for unpack lowering and support bit-math blending, this is
completely obsolete. In the worst case without this we generate
different but equivalent instructions. However, in many cases we
generate much better code. This is especially true when blends or pshufb
is available.

This does expose one (minor) weakness of the unpack lowering that I'll
try to address.

In case you were wondering, this is actually a big part of what I've
been trying to pull off in the recent string of commits.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@229853 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/X86/X86ISelLowering.cpp
test/CodeGen/X86/sse3.ll
test/CodeGen/X86/vector-shuffle-128-v16.ll
test/CodeGen/X86/vector-shuffle-128-v8.ll
test/CodeGen/X86/vector-shuffle-256-v16.ll