ac: fix get_image_coords() for radeonsi

Because this was setting image to true we would end up calling
si_load_image_desc() when we sould be calling
si_load_sampler_desc().

This fixes an assert() in Deus Ex: MD

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
This commit is contained in:
Timothy Arceri 2018-07-27 15:32:36 +10:00
parent 914bd3014f
commit e29f0ede75
1 changed files with 2 additions and 1 deletions

View File

@ -2244,7 +2244,8 @@ static void get_image_coords(struct ac_nir_context *ctx,
fmask_load_address[1],
fmask_load_address[2],
sample_index,
get_image_descriptor(ctx, instr, AC_DESC_FMASK, false));
get_sampler_desc(ctx, nir_instr_as_deref(instr->src[0].ssa->parent_instr),
AC_DESC_FMASK, NULL, false, false));
}
if (count == 1 && !gfx9_1d) {
if (instr->src[1].ssa->num_components)