gallivm/nir: fixup atomic path for explicit pointers.

Reviewed-by: Mihai Preda <mhpreda@gmail.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18932>
This commit is contained in:
Dave Airlie
2022-09-26 18:16:08 +10:00
committed by Marge Bot
parent 09d4eb92e8
commit 61b2d2e0a8
@@ -4669,7 +4669,9 @@ lp_build_do_atomic_soa(struct gallivm_state *gallivm,
LLVMVectorType(ref_type, type.length);
LLVMValueRef atom_res = lp_build_alloca(gallivm, atom_res_elem_type, "");
offset = LLVMBuildGEP(gallivm->builder, base_ptr, &offset, 1, "");
offset = LLVMBuildGEP2(gallivm->builder,
LLVMInt8TypeInContext(gallivm->context),
base_ptr, &offset, 1, "");
struct lp_build_loop_state loop_state;
lp_build_loop_begin(&loop_state, gallivm, lp_build_const_int32(gallivm, 0));