summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers
diff options
context:
space:
mode:
authorTimothy Arceri <[email protected]>2017-10-31 14:19:18 +1100
committerTimothy Arceri <[email protected]>2017-11-01 09:41:11 +1100
commite80bbd6f52341cbf9363f3c0c8b7ad3be851b1e6 (patch)
tree4c53626f3bf4bad4494d459c6321cf6cc7ba8735 /src/gallium/drivers
parentb697ece10aa041b8653eb184d73dcf5b846729a3 (diff)
radeonsi: fix culldist_writemask in nir path
The shared si_create_shader_selector() code already offsets the mask. Fixes the following piglit tests: arb_cull_distance/clip-cull-3.shader_test arb_cull_distance/clip-cull-4.shader_test Fixes: 29d7bdd179bb (radeonsi: scan NIR shaders to obtain required info) Reviewed-by: Marek Olšák <[email protected]>
Diffstat (limited to 'src/gallium/drivers')
-rw-r--r--src/gallium/drivers/radeonsi/si_shader_nir.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/gallium/drivers/radeonsi/si_shader_nir.c b/src/gallium/drivers/radeonsi/si_shader_nir.c
index e186661caf3..7a882273812 100644
--- a/src/gallium/drivers/radeonsi/si_shader_nir.c
+++ b/src/gallium/drivers/radeonsi/si_shader_nir.c
@@ -302,8 +302,7 @@ void si_nir_scan_shader(const struct nir_shader *nir,
info->num_written_clipdistance = nir->info.clip_distance_array_size;
info->num_written_culldistance = nir->info.cull_distance_array_size;
info->clipdist_writemask = u_bit_consecutive(0, info->num_written_clipdistance);
- info->culldist_writemask = u_bit_consecutive(info->num_written_clipdistance,
- info->num_written_culldistance);
+ info->culldist_writemask = u_bit_consecutive(0, info->num_written_culldistance);
if (info->processor == PIPE_SHADER_FRAGMENT)
info->uses_kill = nir->info.fs.uses_discard;