From 685d2e1ff51eb668a715d5f7e59999cd404b64ef Mon Sep 17 00:00:00 2001 From: Tobin Ehlis Date: Mon, 18 Apr 2016 15:45:20 -0600 Subject: layers: Cleanup core_validation fence tracking There were two separate mechanisms for tracking fence state in core_validation. This change removes the last[Retired|Submitted]Id per queue method. We also no longer over-write the fence createInfo to track fence state, but just use the needsSignaled bool for all fence state tracking. Finally, there was a validation test/check flagging an error if an unsignaled fence was reset, but this is valid based on the spec so removed the check and changed test to be a positive test expected to pass. --- layers/core_validation.h | 25 ++----------------------- 1 file changed, 2 insertions(+), 23 deletions(-) (limited to 'layers/core_validation.h') diff --git a/layers/core_validation.h b/layers/core_validation.h index 0831c775..8ab1bdfb 100644 --- a/layers/core_validation.h +++ b/layers/core_validation.h @@ -170,23 +170,6 @@ struct MT_PASS_ATTACHMENT_INFO { VkAttachmentStoreOp store_op; }; -// Associate fenceId with a fence object -struct MT_FENCE_INFO { - uint64_t fenceId; // Sequence number for fence at last submit - VkQueue queue; // Queue that this fence is submitted against or NULL - VkSwapchainKHR swapchain; // Swapchain that this fence is submitted against or NULL - bool firstTimeFlag; // Fence was created in signaled state, avoid warnings for first use - VkFenceCreateInfo createInfo; -}; - -// Track Queue information -struct MT_QUEUE_INFO { - uint64_t lastRetiredId; - uint64_t lastSubmittedId; - list pQueueCommandBuffers; - list pMemRefList; -}; - struct MT_DESCRIPTOR_SET_INFO { std::vector images; std::vector buffers; @@ -572,19 +555,17 @@ class PHYS_DEV_PROPERTIES_NODE { class FENCE_NODE : public BASE_NODE { public: using BASE_NODE::in_use; -#if MTMERGE - uint64_t fenceId; // Sequence number for fence at last submit + VkSwapchainKHR swapchain; // Swapchain that this fence is submitted against or NULL bool firstTimeFlag; // Fence was created in signaled state, avoid warnings for first use VkFenceCreateInfo createInfo; -#endif VkQueue queue; vector cmdBuffers; bool needsSignaled; vector priorFences; // Default constructor - FENCE_NODE() : queue(NULL), needsSignaled(VK_FALSE){}; + FENCE_NODE() : queue(VK_NULL_HANDLE), needsSignaled(false){}; }; class SEMAPHORE_NODE : public BASE_NODE { @@ -606,8 +587,6 @@ class QUEUE_NODE { VkDevice device; vector lastFences; #if MTMERGE - uint64_t lastRetiredId; - uint64_t lastSubmittedId; // MTMTODO : merge cmd_buffer data structs here list pQueueCommandBuffers; list pMemRefList; -- cgit v1.2.3