[PowerPC] Improvements for BUILD_VECTOR Vol. 2
authorNemanja Ivanovic <nemanja.i.ibm@gmail.com>
Tue, 29 Nov 2016 23:36:03 +0000 (23:36 +0000)
committerNemanja Ivanovic <nemanja.i.ibm@gmail.com>
Tue, 29 Nov 2016 23:36:03 +0000 (23:36 +0000)
commit8c11e79b1773ba484db0a710aa90ebffbfea550c
tree66203792985562a476e45f99cad8fa5e10a0700e
parentc893278419b6837afc759cc946048f3bb8b0f188
[PowerPC] Improvements for BUILD_VECTOR Vol. 2

This patch corresponds to review:
https://reviews.llvm.org/D25980

This is the 2nd patch in a series of 4 that improve the lowering and combining
for BUILD_VECTOR nodes on PowerPC. This particular patch combines a build vector
of fp-to-int conversions into an fp-to-int conversion of a build vector of fp
values. For example:
Converts (build_vector (fp_to_[su]i $A), (fp_to_[su]i $B), ...)
Into (fp_to_[su]i (build_vector $A, $B, ...))).
Which is a natural match for much cleaner code.

llvm-svn: 288218
llvm/lib/Target/PowerPC/PPCISelLowering.cpp
llvm/lib/Target/PowerPC/PPCISelLowering.h