getSplatIndex assumes that the first element of the mask contains the splat index
authorMon P Wang <wangmp@apple.com>
Thu, 18 Feb 2010 22:33:18 +0000 (22:33 +0000)
committerMon P Wang <wangmp@apple.com>
Thu, 18 Feb 2010 22:33:18 +0000 (22:33 +0000)
commit1c40e188c579c49f811eee499af2f371298c758c
treec00e810801c29f52f5ab3f92ba61583d12ac7cd3
parent39a4bb35276206d7ef0ff51dbc984aaf50bf659d
getSplatIndex assumes that the first element of the mask contains the splat index
which is not always true if the mask contains undefs. Modified it to return
the first non undef value.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@96621 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/CodeGen/SelectionDAGNodes.h
test/CodeGen/X86/vec_shuffle-36.ll