projects
/
platform
/
upstream
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
65600a3
)
nir: remove gl_PrimitiveID output from MS when it's not used in FS
author
Marcin Ślusarz
<marcin.slusarz@intel.com>
Fri, 11 Mar 2022 10:01:38 +0000
(11:01 +0100)
committer
Marge Bot
<emma+marge@anholt.net>
Tue, 12 Apr 2022 09:35:26 +0000
(09:35 +0000)
Reviewed-by: Timur Kristóf <timur.kristof@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15340>
src/compiler/nir/nir_linking_helpers.c
patch
|
blob
|
history
diff --git
a/src/compiler/nir/nir_linking_helpers.c
b/src/compiler/nir/nir_linking_helpers.c
index
8f31dd4
..
6a574ec
100644
(file)
--- a/
src/compiler/nir/nir_linking_helpers.c
+++ b/
src/compiler/nir/nir_linking_helpers.c
@@
-148,7
+148,8
@@
nir_remove_unused_io_vars(nir_shader *shader,
used = used_by_other_stage;
if (var->data.location < VARYING_SLOT_VAR0 && var->data.location >= 0)
- continue;
+ if (shader->info.stage != MESA_SHADER_MESH || var->data.location != VARYING_SLOT_PRIMITIVE_ID)
+ continue;
if (var->data.always_active_io)
continue;