glsl: Use nir_opt_barrier_modes() to drop unnecessary barriers
iris shader-db stats on Alchemist:
total instructions in shared programs:
23150249 ->
23142733 (-0.03%)
instructions in affected programs: 157322 -> 149806 (-4.78%)
helped: 105
HURT: 2
helped stats (abs) min: 2 max: 821 x̄: 71.61 x̃: 15
helped stats (rel) min: 0.13% max: 27.56% x̄: 6.21% x̃: 2.35%
HURT stats (abs) min: 1 max: 2 x̄: 1.50 x̃: 1
HURT stats (rel) min: 0.18% max: 0.23% x̄: 0.20% x̃: 0.20%
95% mean confidence interval for instructions value: -101.99 -38.50
95% mean confidence interval for instructions %-change: -7.59% -4.58%
Instructions are helped.
total sends in shared programs: 1036916 -> 1035366 (-0.15%)
sends in affected programs: 15274 -> 13724 (-10.15%)
helped: 108 / HURT: 0
helped stats (abs) min: 1 max: 162 x̄: 14.35 x̃: 3
helped stats (rel) min: 0.88% max: 33.83% x̄: 9.81% x̃: 5.05%
95% mean confidence interval for sends value: -20.79 -7.92
95% mean confidence interval for sends %-change: -11.66% -7.95%
Reviewed-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24842>