Skip to content

Commit

Permalink
Set pipeline to VK_NULL_HANDLE when fail on compile isnt supported (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
ziga-lunarg authored Dec 25, 2024
1 parent 616d52c commit 599920e
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions framework/encode/custom_vulkan_api_call_encoders.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -504,6 +504,10 @@ VKAPI_ATTR VkResult VKAPI_CALL CreateGraphicsPipelines(VkDevice
{
if (pCreateInfos[i].flags & VK_PIPELINE_CREATE_FAIL_ON_PIPELINE_COMPILE_REQUIRED_BIT)
{
for (uint32_t j = 0; j < createInfoCount; ++j)
{
pPipelines[j] = VK_NULL_HANDLE;
}
VulkanCaptureManager::Get()->WriteAnnotation(
format::AnnotationType::kText, format::kAnnotationPipelineCreationAttempt, "");
GFXRECON_LOG_WARNING(
Expand Down Expand Up @@ -595,6 +599,10 @@ VKAPI_ATTR VkResult VKAPI_CALL CreateComputePipelines(VkDevice
{
if (pCreateInfos[i].flags & VK_PIPELINE_CREATE_FAIL_ON_PIPELINE_COMPILE_REQUIRED_BIT)
{
for (uint32_t j = 0; j < createInfoCount; ++j)
{
pPipelines[j] = VK_NULL_HANDLE;
}
VulkanCaptureManager::Get()->WriteAnnotation(
format::AnnotationType::kText, format::kAnnotationPipelineCreationAttempt, "");
GFXRECON_LOG_WARNING(
Expand Down Expand Up @@ -686,6 +694,10 @@ VKAPI_ATTR VkResult VKAPI_CALL CreateRayTracingPipelinesNV(VkDevice
{
if (pCreateInfos[i].flags & VK_PIPELINE_CREATE_FAIL_ON_PIPELINE_COMPILE_REQUIRED_BIT)
{
for (uint32_t j = 0; j < createInfoCount; ++j)
{
pPipelines[j] = VK_NULL_HANDLE;
}
VulkanCaptureManager::Get()->WriteAnnotation(
format::AnnotationType::kText, format::kAnnotationPipelineCreationAttempt, "");
GFXRECON_LOG_WARNING(
Expand Down Expand Up @@ -780,6 +792,10 @@ VKAPI_ATTR VkResult VKAPI_CALL CreateRayTracingPipelinesKHR(VkDevice
{
if (pCreateInfos[i].flags & VK_PIPELINE_CREATE_FAIL_ON_PIPELINE_COMPILE_REQUIRED_BIT)
{
for (uint32_t j = 0; j < createInfoCount; ++j)
{
pPipelines[j] = VK_NULL_HANDLE;
}
VulkanCaptureManager::Get()->WriteAnnotation(
format::AnnotationType::kText, format::kAnnotationPipelineCreationAttempt, "");
GFXRECON_LOG_WARNING(
Expand Down

0 comments on commit 599920e

Please sign in to comment.