[Mesa-dev] [PATCH 3/5] ac/nir_to_llvm: fix regression in bindless support
Timothy Arceri
tarceri at itsqueeze.com
Wed Jan 9 08:53:55 UTC 2019
This wasn't ported over when deref support was implemented.
---
src/amd/common/ac_nir_to_llvm.c | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/src/amd/common/ac_nir_to_llvm.c b/src/amd/common/ac_nir_to_llvm.c
index 633cc0aa06..4f7b2e4dc2 100644
--- a/src/amd/common/ac_nir_to_llvm.c
+++ b/src/amd/common/ac_nir_to_llvm.c
@@ -3284,7 +3284,12 @@ static LLVMValueRef get_sampler_desc(struct ac_nir_context *ctx,
deref_instr = nir_src_as_deref(deref_instr->parent);
}
descriptor_set = deref_instr->var->data.descriptor_set;
- base_index = deref_instr->var->data.binding;
+
+ if (deref_instr->var->data.bindless) {
+ base_index = deref_instr->var->data.driver_location;
+ bindless = true;
+ } else
+ base_index = deref_instr->var->data.binding;
}
return ctx->abi->load_sampler_desc(ctx->abi,
--
2.20.1
More information about the mesa-dev
mailing list