Module: Mesa
Branch: master
Commit: 485346b05a6ab2791579219ef74809faf383a15c
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=485346b05a6ab2791579219ef74809faf383a15c

Author: Samuel Pitoiset <samuel.pitoi...@gmail.com>
Date:   Fri Feb  9 13:54:30 2018 +0100

ac/nir: drop nir_to_llvm_context from visit_vulkan_resource_reindex()

Signed-off-by: Samuel Pitoiset <samuel.pitoi...@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <b...@basnieuwenhuizen.nl>

---

 src/amd/common/ac_nir_to_llvm.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/src/amd/common/ac_nir_to_llvm.c b/src/amd/common/ac_nir_to_llvm.c
index 13fa22d444..f23805667c 100644
--- a/src/amd/common/ac_nir_to_llvm.c
+++ b/src/amd/common/ac_nir_to_llvm.c
@@ -2382,13 +2382,13 @@ radv_load_resource(struct ac_shader_abi *abi, 
LLVMValueRef index,
        return desc_ptr;
 }
 
-static LLVMValueRef visit_vulkan_resource_reindex(struct nir_to_llvm_context 
*ctx,
+static LLVMValueRef visit_vulkan_resource_reindex(struct ac_nir_context *ctx,
                                                   nir_intrinsic_instr *instr)
 {
-       LLVMValueRef ptr = get_src(ctx->nir, instr->src[0]);
-       LLVMValueRef index = get_src(ctx->nir, instr->src[1]);
+       LLVMValueRef ptr = get_src(ctx, instr->src[0]);
+       LLVMValueRef index = get_src(ctx, instr->src[1]);
 
-       LLVMValueRef result = LLVMBuildGEP(ctx->builder, ptr, &index, 1, "");
+       LLVMValueRef result = LLVMBuildGEP(ctx->ac.builder, ptr, &index, 1, "");
        LLVMSetMetadata(result, ctx->ac.uniform_md_kind, ctx->ac.empty_md);
        return result;
 }
@@ -4393,7 +4393,7 @@ static void visit_intrinsic(struct ac_nir_context *ctx,
                break;
        }
        case nir_intrinsic_vulkan_resource_reindex:
-               result = visit_vulkan_resource_reindex(ctx->nctx, instr);
+               result = visit_vulkan_resource_reindex(ctx, instr);
                break;
        case nir_intrinsic_store_ssbo:
                visit_store_ssbo(ctx, instr);

_______________________________________________
mesa-commit mailing list
mesa-commit@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to