[x86] Teach the new vector shuffle lowering a fancier way to lower
authorChandler Carruth <chandlerc@gmail.com>
Thu, 25 Sep 2014 10:21:15 +0000 (10:21 +0000)
committerChandler Carruth <chandlerc@gmail.com>
Thu, 25 Sep 2014 10:21:15 +0000 (10:21 +0000)
commit05901d80badd51fae6e17eb4fd8d53d6e5a7bdce
treedddef560d7e06c1e2906e1acf9ecc3234340ba65
parentf220c5387bde32ec9cdd7beb244bd7c133901e15
[x86] Teach the new vector shuffle lowering a fancier way to lower
256-bit vectors with lane-crossing.

Rather than immediately decomposing to 128-bit vectors, try flipping the
256-bit vector lanes, shuffling them and blending them together. This
reduces our worst case shuffle by a pretty significant margin across the
board.

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