ac/nir_to_llvm: fix type handling in image code
authorTimothy Arceri <tarceri@itsqueeze.com>
Wed, 9 Jan 2019 02:15:05 +0000 (13:15 +1100)
committerTimothy Arceri <tarceri@itsqueeze.com>
Wed, 16 Jan 2019 23:35:36 +0000 (10:35 +1100)
commit292887ac0d55104e6c87c4d4a2d51e9f4731ccd2
tree167bbcae5d88da2dc3713506cdb4a1fbd3fb53a8
parent8a52e4cc4fad4f1c75acc0badd624778f9dfe202
ac/nir_to_llvm: fix type handling in image code

The current code only strips off arrays and cannot find the type
for images that are struct members.

Instead of trying to get the image type from the variable, we just
get it directly from the deref instruction.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
src/amd/common/ac_nir_to_llvm.c