diff options
author | Timothy Arceri <[email protected]> | 2018-01-16 18:02:37 +1100 |
---|---|---|
committer | Timothy Arceri <[email protected]> | 2018-01-18 10:25:20 +1100 |
commit | 409e15f26fd245dfa6645214c433cfe4e7b9a988 (patch) | |
tree | 2f739f227d41e04784d295579a4e0e87a1880716 | |
parent | d139b5e4ccf0da19f37428434bf0ef7c76c85049 (diff) |
ac: fix nir_intrinsic_get_buffer_size for radeonsi
Reviewed-by: Samuel Pitoiset <[email protected]>
Reviewed-by: Nicolai Hähnle <[email protected]>
-rw-r--r-- | src/amd/common/ac_nir_to_llvm.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/amd/common/ac_nir_to_llvm.c b/src/amd/common/ac_nir_to_llvm.c index 25ce06138ba..1dc64f87cc9 100644 --- a/src/amd/common/ac_nir_to_llvm.c +++ b/src/amd/common/ac_nir_to_llvm.c @@ -2404,9 +2404,9 @@ static LLVMValueRef visit_load_push_constant(struct nir_to_llvm_context *ctx, static LLVMValueRef visit_get_buffer_size(struct ac_nir_context *ctx, const nir_intrinsic_instr *instr) { - LLVMValueRef ptr = get_src(ctx, instr->src[0]); + LLVMValueRef index = get_src(ctx, instr->src[0]); - return get_buffer_size(ctx, LLVMBuildLoad(ctx->ac.builder, ptr, ""), false); + return get_buffer_size(ctx, ctx->abi->load_ssbo(ctx->abi, index, false), false); } static void visit_store_ssbo(struct ac_nir_context *ctx, nir_intrinsic_instr *instr) |