summaryrefslogtreecommitdiffstats
path: root/src/intel/vulkan/anv_pipeline.c
diff options
context:
space:
mode:
authorJason Ekstrand <[email protected]>2017-10-03 15:23:07 -0700
committerJason Ekstrand <[email protected]>2018-03-07 12:13:47 -0800
commitdfe18be09e38c6c534474f3b666a1a57755c7731 (patch)
treeedffcf060107290246c78a37f01778218def7b07 /src/intel/vulkan/anv_pipeline.c
parentff9db1a4cc0eefece2d0485a169b2a289b2ff6ef (diff)
anv: Implement vkCmdDispatchBase
This is part of the device groups extension/feature but it's a decent chunk of work in its own right so it's worth breaking into its own patch. The mechanism we use is fairly straightforward: we just push the base work group id into the shader and add it to the work group id we get from dispatch. Reviewed-by: Samuel Iglesias Gonsálvez <[email protected]>
Diffstat (limited to 'src/intel/vulkan/anv_pipeline.c')
-rw-r--r--src/intel/vulkan/anv_pipeline.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/intel/vulkan/anv_pipeline.c b/src/intel/vulkan/anv_pipeline.c
index e16a7a19940..f02d54c132d 100644
--- a/src/intel/vulkan/anv_pipeline.c
+++ b/src/intel/vulkan/anv_pipeline.c
@@ -1042,6 +1042,8 @@ anv_pipeline_compile_cs(struct anv_pipeline *pipeline,
return vk_error(VK_ERROR_OUT_OF_HOST_MEMORY);
}
+ NIR_PASS_V(nir, anv_nir_add_base_work_group_id, &prog_data);
+
anv_fill_binding_table(&prog_data.base, 1);
const unsigned *shader_code =