gallivm: optimize 16bit->32bit gather path a bit
authorRoland Scheidegger <sroland@vmware.com>
Tue, 6 Dec 2016 18:59:51 +0000 (19:59 +0100)
committerRoland Scheidegger <sroland@vmware.com>
Tue, 6 Dec 2016 19:06:06 +0000 (20:06 +0100)
commit8ac3c1bf1ab47d9b7e5fcddeb7620eedcec7bdb3
tree0071383a12fa4cecd96d7002baefacbea662ca7a
parentfd5f420fbb237a9662532a4111e409f5ec2eba8a
gallivm: optimize 16bit->32bit gather path a bit

LLVM can't really optimize anything which crosses scalar/vector boundaries,
so help a bit with some particular gather operations when the width is
expanded (only do it for 16->32bit expansion for now), by doing expansion
after fetch. That is probably a better solution anyway even if llvm would
recognize it, makes for cleaner IR...

Reviewed-by: Jose Fonseca <jfonseca@vmware.com>
src/gallium/auxiliary/gallivm/lp_bld_gather.c