From: Caio Marcelo de Oliveira Filho Date: Tue, 19 May 2020 00:43:34 +0000 (-0700) Subject: nir: Consider atomic counter intrinsics when setting writes_memory X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=c4544f47167ab5fe170e5131ad45b20b02507bce;p=mesa.git nir: Consider atomic counter intrinsics when setting writes_memory In i965 these get lowered after gather info, so let's consider them too. Fixes piglit.spec.arb_framebuffer_no_attachments.arb_framebuffer_no_attachments-atomic in Gen9, HSW and IVB. Fixes: 6a6c36e9776 ("intel/fs: Use writes_memory from shader_info") Reviewed-by: Kenneth Graunke Reviewed-by: Jason Ekstrand Part-of: --- diff --git a/src/compiler/nir/nir_gather_info.c b/src/compiler/nir/nir_gather_info.c index 09ecc28554b..d1c3e6168cf 100644 --- a/src/compiler/nir/nir_gather_info.c +++ b/src/compiler/nir/nir_gather_info.c @@ -394,6 +394,28 @@ gather_intrinsic_info(nir_intrinsic_instr *instr, nir_shader *shader, break; + case nir_intrinsic_atomic_counter_inc: + case nir_intrinsic_atomic_counter_inc_deref: + case nir_intrinsic_atomic_counter_add: + case nir_intrinsic_atomic_counter_add_deref: + case nir_intrinsic_atomic_counter_pre_dec: + case nir_intrinsic_atomic_counter_pre_dec_deref: + case nir_intrinsic_atomic_counter_post_dec: + case nir_intrinsic_atomic_counter_post_dec_deref: + case nir_intrinsic_atomic_counter_min: + case nir_intrinsic_atomic_counter_min_deref: + case nir_intrinsic_atomic_counter_max: + case nir_intrinsic_atomic_counter_max_deref: + case nir_intrinsic_atomic_counter_and: + case nir_intrinsic_atomic_counter_and_deref: + case nir_intrinsic_atomic_counter_or: + case nir_intrinsic_atomic_counter_or_deref: + case nir_intrinsic_atomic_counter_xor: + case nir_intrinsic_atomic_counter_xor_deref: + case nir_intrinsic_atomic_counter_exchange: + case nir_intrinsic_atomic_counter_exchange_deref: + case nir_intrinsic_atomic_counter_comp_swap: + case nir_intrinsic_atomic_counter_comp_swap_deref: case nir_intrinsic_bindless_image_atomic_add: case nir_intrinsic_bindless_image_atomic_and: case nir_intrinsic_bindless_image_atomic_comp_swap: