nir: Fix logic that ends combine barrier sequence
authorCaio Marcelo de Oliveira Filho <caio.oliveira@intel.com>
Sat, 6 Jun 2020 06:05:42 +0000 (23:05 -0700)
committerMarge Bot <eric+marge@anholt.net>
Mon, 8 Jun 2020 15:49:24 +0000 (15:49 +0000)
commitd1f6d2f3e8683f10773e7b349ab4ff6f181233a6
tree8a11b809b9f957ef76f112c349e54aef7ce1a558
parentfe214d60bc9e5245bf41c86146036fc61f4535e7
nir: Fix logic that ends combine barrier sequence

The combination must stop when we see a scoped barrier that have
execution scope, i.e. it has control barrier behavior.  The code was
mistakenly looking at the wrong scope.

Fixes: 345b5847b42 ("nir: Replace the scoped_memory barrier by a scoped_barrier")
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5365>
src/compiler/nir/nir_opt_barriers.c