[Mesa-dev] [PATCH 09/15] spirv/nir: Set info.gs.uses_streams
Alejandro PiƱeiro
apinheiro at igalia.com
Fri Jul 20 15:08:38 UTC 2018
From: Neil Roberts <nroberts at igalia.com>
Whenever a non-zero stream is written to it now sets uses_streams to
true. This reflects the code in validate_geometry_shader_emissions for
GLSL.
---
src/compiler/spirv/spirv_to_nir.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/src/compiler/spirv/spirv_to_nir.c b/src/compiler/spirv/spirv_to_nir.c
index 2fef6b0bf15..0957efb2aa1 100644
--- a/src/compiler/spirv/spirv_to_nir.c
+++ b/src/compiler/spirv/spirv_to_nir.c
@@ -3224,6 +3224,10 @@ vtn_handle_barrier(struct vtn_builder *b, SpvOp opcode,
vtn_value(b, w[1], vtn_value_type_constant);
unsigned stream = stream_value->constant->values[0].u32[0];
nir_intrinsic_set_stream_id(intrin, stream);
+
+ if (stream > 0)
+ b->shader->info.gs.uses_streams = true;
+
break;
}
--
2.14.1
More information about the mesa-dev
mailing list