From: Caio Marcelo de Oliveira Filho Date: Fri, 19 Apr 2019 19:18:02 +0000 (-0700) Subject: anv: Implement VK_KHR_shader_clock X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=f7ca072ab21b3ac1976b31ad81891f3626e3b876;p=mesa.git anv: Implement VK_KHR_shader_clock Reviewed-by: Lionel Landwerlin --- diff --git a/src/intel/vulkan/anv_device.c b/src/intel/vulkan/anv_device.c index 323bb61ce39..37dabd76278 100644 --- a/src/intel/vulkan/anv_device.c +++ b/src/intel/vulkan/anv_device.c @@ -1201,6 +1201,14 @@ void anv_GetPhysicalDeviceFeatures2( break; } + case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SHADER_CLOCK_FEATURES_KHR: { + VkPhysicalDeviceShaderClockFeaturesKHR *features = + (VkPhysicalDeviceShaderClockFeaturesKHR *)ext; + features->shaderSubgroupClock = true; + features->shaderDeviceClock = false; + break; + } + case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SHADER_DRAW_PARAMETERS_FEATURES: { VkPhysicalDeviceShaderDrawParametersFeatures *features = (void *)ext; features->shaderDrawParameters = true; diff --git a/src/intel/vulkan/anv_extensions.py b/src/intel/vulkan/anv_extensions.py index dad49a1e564..1ef699c7d0e 100644 --- a/src/intel/vulkan/anv_extensions.py +++ b/src/intel/vulkan/anv_extensions.py @@ -108,6 +108,7 @@ EXTENSIONS = [ Extension('VK_KHR_sampler_ycbcr_conversion', 1, True), Extension('VK_KHR_shader_atomic_int64', 1, 'device->info.gen >= 9 && device->use_softpin'), + Extension('VK_KHR_shader_clock', 1, True), Extension('VK_KHR_shader_draw_parameters', 1, True), Extension('VK_KHR_shader_float16_int8', 1, 'device->info.gen >= 8'), Extension('VK_KHR_shader_float_controls', 1, 'device->info.gen >= 8'), diff --git a/src/intel/vulkan/anv_pipeline.c b/src/intel/vulkan/anv_pipeline.c index 64e60525d77..14343260882 100644 --- a/src/intel/vulkan/anv_pipeline.c +++ b/src/intel/vulkan/anv_pipeline.c @@ -192,6 +192,7 @@ anv_shader_compile_to_nir(struct anv_device *device, .post_depth_coverage = pdevice->info.gen >= 9, .runtime_descriptor_array = true, .float_controls = pdevice->info.gen >= 8, + .shader_clock = true, .shader_viewport_index_layer = true, .stencil_export = pdevice->info.gen >= 9, .storage_8bit = pdevice->info.gen >= 8,