[X86][AVX] Fold vt1 concat_vectors(vt2 undef, vt2 broadcast(x)) --> vt1 broadcast(x)
authorSimon Pilgrim <llvm-dev@redking.me.uk>
Thu, 31 Jan 2019 11:15:05 +0000 (11:15 +0000)
committerSimon Pilgrim <llvm-dev@redking.me.uk>
Thu, 31 Jan 2019 11:15:05 +0000 (11:15 +0000)
commit51c2efc104d14f763dbcaf5cd95fe4a3eb9561ac
treead7772aac0bbe538a61bca4eb8971998e244c7c6
parent9b127421b627a0e2dd0fa46fb327fb051fae918b
[X86][AVX] Fold vt1 concat_vectors(vt2 undef, vt2 broadcast(x)) --> vt1 broadcast(x)

If we're not inserting the broadcast into the lowest subvector then we can avoid the insertion by just performing a larger broadcast.

Avoids a regression when we enable AVX1 broadcasts in shuffle combining

llvm-svn: 352742
llvm/lib/Target/X86/X86ISelLowering.cpp
llvm/test/CodeGen/X86/insert-into-constant-vector.ll