Disable interval watchdog for sets32 in vktBindingDescriptorSetRandomTests
authorYiwei Zhang <zzyiwei@google.com>
Thu, 4 Aug 2022 18:38:51 +0000 (18:38 +0000)
committerMatthew Netsch <quic_mnetsch@quicinc.com>
Thu, 18 Aug 2022 17:26:46 +0000 (17:26 +0000)
There're certain sets32 tests doing super long shader compilations.To be
noted that the re-enablement is placed after fence waiting to favor
virtualization drivers that making asynchronous pipeline creation calls
to the host. The long blocking shader compilation will show up upon
guest waiting for the fence to signal.

Affects: dEQP-VK.binding_model.descriptorset_random.sets32.*

Components: Vulkan

VK-GL-CTS issue: 3878

Change-Id: Id25378e9546950bed463f1f278c6859306e0e0d8

external/vulkancts/modules/vulkan/binding_model/vktBindingDescriptorSetRandomTests.cpp

index 6893334..7d461f9 100644 (file)
@@ -2229,6 +2229,13 @@ tcu::TestStatus DescriptorSetRandomTestInstance::iterate (void)
        de::MovePtr<BufferWithMemory>   callableShaderBindingTable;
        de::MovePtr<RayTracingPipeline> rayTracingPipeline;
 
+       // Disable interval watchdog timer for long shader compilations that can
+       // happen when the number of descriptor sets gets to 32 and above.
+       if (m_data.numDescriptorSets >= 32)
+       {
+               m_context.getTestContext().touchWatchdogAndDisableIntervalTimeLimit();
+       }
+
        if (m_data.stage == STAGE_COMPUTE)
        {
                const Unique<VkShaderModule>    shader(createShaderModule(vk, device, m_context.getBinaryCollection().get("test"), 0));
@@ -2780,6 +2787,13 @@ tcu::TestStatus DescriptorSetRandomTestInstance::iterate (void)
 
        submitCommandsAndWait(vk, device, queue, cmdBuffer.get());
 
+       // Re-enable watchdog interval timer here to favor virtualized vulkan
+       // implementation that asynchronously creates the pipeline on the host.
+       if (m_data.numDescriptorSets >= 32)
+       {
+               m_context.getTestContext().touchWatchdogAndEnableIntervalTimeLimit();
+       }
+
        // Verify output image.
        deUint32 *ptr = (deUint32 *)copyBuffer->getAllocation().getHostPtr();
        invalidateAlloc(vk, device, copyBuffer->getAllocation());