CONCAT_VECTOR of BUILD_VECTOR - minor fix
authorSimon Pilgrim <llvm-dev@redking.me.uk>
Tue, 21 Apr 2015 08:05:43 +0000 (08:05 +0000)
committerSimon Pilgrim <llvm-dev@redking.me.uk>
Tue, 21 Apr 2015 08:05:43 +0000 (08:05 +0000)
commitd2f0700f15d36540617e5591cb0356fb6018d4f5
tree2fc2f0af8bd3c158d699f43d6d4282207dd1cd4e
parent775c174b7bf5a80b93ad1107c374c1c40a9a8458
CONCAT_VECTOR of BUILD_VECTOR - minor fix

Fixed issue with the combine of CONCAT_VECTOR of 2 BUILD_VECTOR nodes - the optimisation wasn't ensuring that the scalar operands of both nodes were the same type/size for implicit truncation.

Test case spotted by Patrik Hagglund

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235371 91177308-0d34-0410-b5e6-96231b3b80d8
lib/CodeGen/SelectionDAG/SelectionDAG.cpp
test/CodeGen/X86/fold-vector-shuffle-crash.ll