mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 18:18:06 +02:00
gallivm: add memory barrier support
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
This commit is contained in:
parent
abfb633968
commit
b9bf236c71
1 changed files with 11 additions and 0 deletions
|
|
@ -3858,6 +3858,16 @@ atomic_emit(
|
|||
}
|
||||
}
|
||||
|
||||
static void
|
||||
membar_emit(
|
||||
const struct lp_build_tgsi_action * action,
|
||||
struct lp_build_tgsi_context * bld_base,
|
||||
struct lp_build_emit_data * emit_data)
|
||||
{
|
||||
LLVMBuilderRef builder = bld_base->base.gallivm->builder;
|
||||
LLVMBuildFence(builder, LLVMAtomicOrderingSequentiallyConsistent, false, "");
|
||||
}
|
||||
|
||||
static void
|
||||
increment_vec_ptr_by_mask(struct lp_build_tgsi_context * bld_base,
|
||||
LLVMValueRef ptr,
|
||||
|
|
@ -4464,6 +4474,7 @@ lp_build_tgsi_soa(struct gallivm_state *gallivm,
|
|||
bld.bld_base.op_actions[TGSI_OPCODE_ATOMIMIN].emit = atomic_emit;
|
||||
bld.bld_base.op_actions[TGSI_OPCODE_ATOMIMAX].emit = atomic_emit;
|
||||
|
||||
bld.bld_base.op_actions[TGSI_OPCODE_MEMBAR].emit = membar_emit;
|
||||
if (params->gs_iface) {
|
||||
/* There's no specific value for this because it should always
|
||||
* be set, but apps using ext_geometry_shader4 quite often
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue