[Mesa-dev] [PATCH] r600: don't emit atomic save if we have no atomic counters.
Gert Wollny
gw.fossdev at gmail.com
Mon Nov 13 19:36:33 UTC 2017
Obviously, you can now disregard my other email about the performance
regression, this fixes it.
Tested-By: Gert Wollny <gw.fossdev at gmail.com>
Best wishes,
Am Freitag, den 10.11.2017, 13:47 +1000 schrieb Dave Airlie:
> From: Dave Airlie <airlied at redhat.com>
>
> Otherwise we end up emitting the fence.
>
> Signed-off-by: Dave Airlie <airlied at redhat.com>
> ---
> src/gallium/drivers/r600/evergreen_state.c | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/src/gallium/drivers/r600/evergreen_state.c
> b/src/gallium/drivers/r600/evergreen_state.c
> index c1d13fd..30819ae 100644
> --- a/src/gallium/drivers/r600/evergreen_state.c
> +++ b/src/gallium/drivers/r600/evergreen_state.c
> @@ -4634,6 +4634,9 @@ void evergreen_emit_atomic_buffer_save(struct
> r600_context *rctx,
> unsigned reloc;
>
> mask = *atomic_used_mask_p;
> + if (!mask)
> + return;
> +
> while (mask) {
> unsigned atomic_index = u_bit_scan(&mask);
> struct r600_shader_atomic *atomic =
> &combined_atomics[atomic_index];
More information about the mesa-dev
mailing list