lavapipe: EXT_primitives_generated_query

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15636>
This commit is contained in:
Mike Blumenkrantz 2022-03-22 12:33:29 -04:00 committed by Marge Bot
parent 8c3b4dd996
commit 0918095b9a
2 changed files with 12 additions and 0 deletions

View file

@ -153,6 +153,7 @@ static const struct vk_device_extension_table lvp_device_extensions_supported =
.EXT_pipeline_creation_cache_control = true,
.EXT_post_depth_coverage = true,
.EXT_private_data = true,
.EXT_primitives_generated_query = true,
.EXT_primitive_topology_list_restart = true,
.EXT_sampler_filter_minmax = true,
.EXT_scalar_block_layout = true,
@ -745,6 +746,14 @@ VKAPI_ATTR void VKAPI_CALL lvp_GetPhysicalDeviceFeatures2(
features->pipelineCreationCacheControl = true;
break;
}
case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_PRIMITIVES_GENERATED_QUERY_FEATURES_EXT: {
VkPhysicalDevicePrimitivesGeneratedQueryFeaturesEXT *features =
(VkPhysicalDevicePrimitivesGeneratedQueryFeaturesEXT *)ext;
features->primitivesGeneratedQuery = true;
features->primitivesGeneratedQueryWithRasterizerDiscard = true;
features->primitivesGeneratedQueryWithNonZeroStreams = true;
break;
}
case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_LINE_RASTERIZATION_FEATURES_EXT: {
VkPhysicalDeviceLineRasterizationFeaturesEXT *features =
(VkPhysicalDeviceLineRasterizationFeaturesEXT *)ext;

View file

@ -46,6 +46,9 @@ VKAPI_ATTR VkResult VKAPI_CALL lvp_CreateQueryPool(
case VK_QUERY_TYPE_PIPELINE_STATISTICS:
pipeq = PIPE_QUERY_PIPELINE_STATISTICS;
break;
case VK_QUERY_TYPE_PRIMITIVES_GENERATED_EXT:
pipeq = PIPE_QUERY_PRIMITIVES_GENERATED;
break;
default:
return VK_ERROR_FEATURE_NOT_PRESENT;
}