[X86][SSE] Fixed PALIGNR target shuffle decode
authorSimon Pilgrim <llvm-dev@redking.me.uk>
Fri, 12 Aug 2016 10:10:51 +0000 (10:10 +0000)
committerSimon Pilgrim <llvm-dev@redking.me.uk>
Fri, 12 Aug 2016 10:10:51 +0000 (10:10 +0000)
commited96b9adfbda561d030a20c4fdd9ec6db594bbee
treea68ad72a281ca586468ac259210062008d30f418
parent635625855fc4e5dde3a393d09b27724e71abdf2b
[X86][SSE] Fixed PALIGNR target shuffle decode

The PALIGNR target shuffle decode was not taking into account that DecodePALIGNRMask (rather oddly) expects the operands to be in reverse order, nor was it detecting unary patterns, causing combines to combine with the incorrect input.

The cgbuiltin, auto upgrade and instruction comments code correctly swap the operands so are not affected.

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