[PowerPC] Improve handling of some BUILD_VECTOR nodes
authorNemanja Ivanovic <nemanja.i.ibm@gmail.com>
Mon, 23 Mar 2020 22:34:05 +0000 (17:34 -0500)
committerNemanja Ivanovic <nemanja.i.ibm@gmail.com>
Mon, 23 Mar 2020 22:34:29 +0000 (17:34 -0500)
commitbfa9ce1cb27a6abac071c0b8fab76d647098eaeb
tree9fb4312608e6d4314aec88e48d93cc15f64734c6
parentc5c4109071ce22e5d3cd8404a7e4d64debdf377a
[PowerPC] Improve handling of some BUILD_VECTOR nodes

An analysis of real world code turned up a number of patterns with BUILD_VECTOR
of nodes resulting from operations on extracted vector elements for which we
produce poor code. This addresses those cases. No attempt is made for
completeness as that would entail a large amount of work for something that
there is no evidence of in real code.

Differential revision: https://reviews.llvm.org/D72660
llvm/lib/Target/PowerPC/PPCInstrVSX.td
llvm/test/CodeGen/PowerPC/build-vector-tests.ll
llvm/test/CodeGen/PowerPC/reduce_scalarization02.ll
llvm/test/CodeGen/PowerPC/vec_conv_fp32_to_i64_elts.ll
llvm/test/CodeGen/PowerPC/vsx.ll