summaryrefslogtreecommitdiffstats
path: root/src/compiler/spirv
diff options
context:
space:
mode:
authorJason Ekstrand <[email protected]>2019-01-22 13:55:20 -0600
committerJason Ekstrand <[email protected]>2019-02-01 17:34:02 +0000
commitab940b0d972d9825a2d0ab26a7128ea61ba527b2 (patch)
tree68d97fc94720aba4941036239025b7814b34508d /src/compiler/spirv
parent7223590c42ebd0c4661e3200b78a181a84bbf405 (diff)
spirv: Support LocalSizeId and LocalSizeHintId execution modes
Reviewed-by: Caio Marcelo de Oliveira Filho <[email protected]>
Diffstat (limited to 'src/compiler/spirv')
-rw-r--r--src/compiler/spirv/spirv_to_nir.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/compiler/spirv/spirv_to_nir.c b/src/compiler/spirv/spirv_to_nir.c
index ff9635a1895..1cbc926c818 100644
--- a/src/compiler/spirv/spirv_to_nir.c
+++ b/src/compiler/spirv/spirv_to_nir.c
@@ -3826,7 +3826,15 @@ vtn_handle_execution_mode(struct vtn_builder *b, struct vtn_value *entry_point,
b->shader->info.cs.local_size[1] = mode->literals[1];
b->shader->info.cs.local_size[2] = mode->literals[2];
break;
+
+ case SpvExecutionModeLocalSizeId:
+ b->shader->info.cs.local_size[0] = vtn_constant_uint(b, mode->literals[0]);
+ b->shader->info.cs.local_size[1] = vtn_constant_uint(b, mode->literals[1]);
+ b->shader->info.cs.local_size[2] = vtn_constant_uint(b, mode->literals[2]);
+ break;
+
case SpvExecutionModeLocalSizeHint:
+ case SpvExecutionModeLocalSizeHintId:
break; /* Nothing to do with this */
case SpvExecutionModeOutputVertices: