[X86][SSE] Basic combining of unary target shuffles of binary target shuffles.
authorSimon Pilgrim <llvm-dev@redking.me.uk>
Thu, 10 Mar 2016 11:23:51 +0000 (11:23 +0000)
committerSimon Pilgrim <llvm-dev@redking.me.uk>
Thu, 10 Mar 2016 11:23:51 +0000 (11:23 +0000)
commit16d11785a5fbd982cf81b1585603d576d743f576
treed43c294f1622ccda5f8fb474123ba8c1e9d17b33
parent1ecd740cf0b99a7c2ac79fdfdf08338588296910
[X86][SSE] Basic combining of unary target shuffles of binary target shuffles.

This patch reorders the combining of target shuffle masks so that when a unary shuffle takes a binary shuffle as its input but only references one of its inputs it can correctly combine into a unary shuffle mask.

This is starting to encroach on the purpose of resolveTargetShuffleInputs, but I don't want to remove it until we definitely know we won't need it for full binary shuffle combining.

There is a lot more work before we can properly support binary target shuffle masks but this was an easy case to add support for.

Differential Revision: http://reviews.llvm.org/D17858

llvm-svn: 263102
llvm/lib/Target/X86/X86ISelLowering.cpp
llvm/test/CodeGen/X86/vector-shuffle-128-v2.ll
llvm/test/CodeGen/X86/vector-shuffle-combining-ssse3.ll