Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GPU-AV: Data races between command buffer submission, allocation and recording #8698

Open
glebov-andrey opened this issue Oct 15, 2024 · 0 comments
Labels
GPU-AV GPU Assisted Validation

Comments

@glebov-andrey
Copy link

Environment:

  • OS: Linux
  • GPU and driver version: AMD RX 6900 XT (Mesa 24.0.9-0ubuntu0.2)
  • SDK or header version if building from repo: bbb0d49 (current main)
  • Options enabled (synchronization, best practices, etc.): GPU-AV

Describe the Issue

There are data races between submitting a command buffer, allocating another one and/or recording a command buffer (perhaps only vkCmdBindDescriptorSets).
The races are between the same functions VmaDeviceMemoryBlock::GetMappedData() inside vmaCreateBuffer and VmaDeviceMemoryBlock::Unmap() inside vmaUnmapMemory.

Here's the rough setup:

  • N worker threads each have their own set of 3 command pools (per frame in flight + 1)
  • Command buffers are allocated when the free list for the current thread + frame is empty
  • Command buffers are only recorded in the thread which allocated them
  • Submission happens potentially on another worker thread, in a scheduled order.
  • Command buffers are reused after 3 frames pass on the CPU (no more than 2 frames can run concurrently on the GPU, guaranteed by waiting for a timeline semaphore on the CPU)
TSAN error 1 (submit & allocate):
WARNING: ThreadSanitizer: data race (pid=25535)
  Read of size 8 at 0x721800046438 by thread T6 (mutexes: write M0):
    #0 VmaDeviceMemoryBlock::GetMappedData() const VVL/layers/external/vma/vk_mem_alloc.h:5950:42 (libVkLayer_khronos_validation.so+0x9f85ed) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #1 VmaBlockVector::AllocatePage(unsigned long, unsigned long, VmaAllocationCreateInfo const&, VmaSuballocationType, VmaAllocation_T**) VVL/layers/external/vma/vk_mem_alloc.h:12504:64 (libVkLayer_khronos_validation.so+0x9d879c) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #2 VmaBlockVector::Allocate(unsigned long, unsigned long, VmaAllocationCreateInfo const&, VmaSuballocationType, unsigned long, VmaAllocation_T**) VVL/layers/external/vma/vk_mem_alloc.h:12401:19 (libVkLayer_khronos_validation.so+0x9d8052) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #3 VmaAllocator_T::AllocateMemoryOfType(VmaPool_T*, unsigned long, unsigned long, bool, VkBuffer_T*, VkImage_T*, unsigned int, VmaAllocationCreateInfo const&, unsigned int, VmaSuballocationType, VmaDedicatedAllocationList&, VmaBlockVector&, unsigned long, VmaAllocation_T**) VVL/layers/external/vma/vk_mem_alloc.h:14558:27 (libVkLayer_khronos_validation.so+0x9e65f0) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #4 VmaAllocator_T::AllocateMemory(VkMemoryRequirements const&, bool, bool, VkBuffer_T*, VkImage_T*, unsigned int, VmaAllocationCreateInfo const&, VmaSuballocationType, unsigned long, VmaAllocation_T**) VVL/layers/external/vma/vk_mem_alloc.h:15077:19 (libVkLayer_khronos_validation.so+0x9e8e88) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #5 vmaCreateBuffer VVL/layers/external/vma/vk_mem_alloc.h:17067:26 (libVkLayer_khronos_validation.so+0x9f01e8) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #6 gpuav::DeviceMemoryBlock::CreateBuffer(Location const&, VkBufferCreateInfo const*, VmaAllocationCreateInfo const*) VVL/layers/gpu/resources/gpuav_resources.cpp:176:9 (libVkLayer_khronos_validation.so+0x108f6fa) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #7 gpuav::CommandBuffer::AllocateResources(Location const&) VVL/layers/gpu/resources/gpuav_subclasses.cpp:203:30 (libVkLayer_khronos_validation.so+0x107b540) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #8 gpuav::CommandBuffer::CommandBuffer(gpuav::Validator&, VkCommandBuffer_T*, VkCommandBufferAllocateInfo const*, vvl::CommandPool const*) VVL/layers/gpu/resources/gpuav_subclasses.cpp:132:5 (libVkLayer_khronos_validation.so+0x107b048) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #9 void std::_Construct<gpuav::CommandBuffer, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(gpuav::CommandBuffer*, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/stl_construct.h:119:25 (libVkLayer_khronos_validation.so+0xff0dae) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #10 void std::allocator_traits<std::allocator<void>>::construct<gpuav::CommandBuffer, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(std::allocator<void>&, gpuav::CommandBuffer*, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/alloc_traits.h:661:4 (libVkLayer_khronos_validation.so+0xff07d9) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #11 std::_Sp_counted_ptr_inplace<gpuav::CommandBuffer, std::allocator<void>, (__gnu_cxx::_Lock_policy)2>::_Sp_counted_ptr_inplace<gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(std::allocator<void>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr_base.h:604:4 (libVkLayer_khronos_validation.so+0xff07d9)
    #12 std::__shared_count<(__gnu_cxx::_Lock_policy)2>::__shared_count<gpuav::CommandBuffer, std::allocator<void>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(gpuav::CommandBuffer*&, std::_Sp_alloc_shared_tag<std::allocator<void>>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr_base.h:972:6 (libVkLayer_khronos_validation.so+0xff0464) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #13 std::__shared_ptr<gpuav::CommandBuffer, (__gnu_cxx::_Lock_policy)2>::__shared_ptr<std::allocator<void>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(std::_Sp_alloc_shared_tag<std::allocator<void>>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr_base.h:1712:14 (libVkLayer_khronos_validation.so+0xff0334) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #14 std::shared_ptr<gpuav::CommandBuffer>::shared_ptr<std::allocator<void>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(std::_Sp_alloc_shared_tag<std::allocator<void>>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr.h:464:4 (libVkLayer_khronos_validation.so+0xff0252) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #15 std::shared_ptr<std::enable_if<!is_array<gpuav::CommandBuffer>::value, gpuav::CommandBuffer>::type> std::make_shared<gpuav::CommandBuffer, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr.h:1009:14 (libVkLayer_khronos_validation.so+0xfe8561) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #16 gpuav::Validator::CreateCmdBufferState(VkCommandBuffer_T*, VkCommandBufferAllocateInfo const*, vvl::CommandPool const*) VVL/layers/gpu/core/gpuav_setup.cpp:72:57 (libVkLayer_khronos_validation.so+0xfe30c3) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #17 vvl::CommandPool::Allocate(VkCommandBufferAllocateInfo const*, VkCommandBuffer_T* const*) VVL/layers/state_tracker/cmd_buffer_state.cpp:131:32 (libVkLayer_khronos_validation.so+0x10bd072) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #18 ValidationStateTracker::PostCallRecordAllocateCommandBuffers(VkDevice_T*, VkCommandBufferAllocateInfo const*, VkCommandBuffer_T**, RecordObject const&) VVL/layers/state_tracker/state_tracker.cpp:2260:15 (libVkLayer_khronos_validation.so+0x1275cdb) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #19 vulkan_layer_chassis::AllocateCommandBuffers(VkDevice_T*, VkCommandBufferAllocateInfo const*, VkCommandBuffer_T**) VVL/layers/vulkan/generated/chassis.cpp:4227:24 (libVkLayer_khronos_validation.so+0xa83ed0) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)

  Previous write of size 8 at 0x721800046438 by thread T3 (mutexes: read M1, write M2):
    #0 VmaDeviceMemoryBlock::Unmap(VmaAllocator_T*, unsigned int) VVL/layers/external/vma/vk_mem_alloc.h:11881:27 (libVkLayer_khronos_validation.so+0x9d4e92) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #1 VmaAllocator_T::Unmap(VmaAllocation_T*) VVL/layers/external/vma/vk_mem_alloc.h:15595:21 (libVkLayer_khronos_validation.so+0x9ea8e9) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #2 vmaUnmapMemory VVL/layers/external/vma/vk_mem_alloc.h:16797:16 (libVkLayer_khronos_validation.so+0x9ef2a6) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #3 gpuav::DeviceMemoryBlock::UnmapMemory() const VVL/layers/gpu/resources/gpuav_resources.cpp:157:47 (libVkLayer_khronos_validation.so+0x108f25d) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #4 gpuav::CommandBuffer::UpdateBdaRangesBuffer(Location const&) VVL/layers/gpu/resources/gpuav_subclasses.cpp:334:26 (libVkLayer_khronos_validation.so+0x107c87d) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #5 gpuav::CommandBuffer::PreProcess(Location const&) VVL/layers/gpu/resources/gpuav_subclasses.cpp:438:17 (libVkLayer_khronos_validation.so+0x107d12e) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #6 gpuav::Queue::PreSubmit(std::vector<vvl::QueueSubmission, std::allocator<vvl::QueueSubmission>>&&) VVL/layers/gpu/resources/gpuav_subclasses.cpp:625:21 (libVkLayer_khronos_validation.so+0x107e77f) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #7 ValidationStateTracker::PreCallRecordQueueSubmit2(VkQueue_T*, unsigned int, VkSubmitInfo2 const*, VkFence_T*, RecordObject const&) VVL/layers/state_tracker/state_tracker.cpp:1298:48 (libVkLayer_khronos_validation.so+0x126ce84) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #8 vulkan_layer_chassis::QueueSubmit2(VkQueue_T*, unsigned int, VkSubmitInfo2 const*, VkFence_T*) VVL/layers/vulkan/generated/chassis.cpp:7914:24 (libVkLayer_khronos_validation.so+0xaa8bb4) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)

  Location is heap block of size 96 at 0x7218000463e0 allocated by main thread:
    #0 aligned_alloc <null> (libclang_rt.tsan-x86_64.so+0x673b8) (BuildId: 83a3c8d2530f3f7484f54738b3cc92e3ba2a603f)
    #1 vma_aligned_alloc(unsigned long, unsigned long) VVL/layers/external/vma/vk_mem_alloc.h:2786:12 (libVkLayer_khronos_validation.so+0x9f2b65) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #2 VmaMalloc(VkAllocationCallbacks const*, unsigned long, unsigned long) VVL/layers/external/vma/vk_mem_alloc.h:3791:18 (libVkLayer_khronos_validation.so+0x9f2ab3) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #3 VmaMalloc(VmaAllocator_T*, unsigned long, unsigned long) VVL/layers/external/vma/vk_mem_alloc.h:11673:12 (libVkLayer_khronos_validation.so+0x9f3559) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #4 VmaDeviceMemoryBlock* VmaAllocate<VmaDeviceMemoryBlock>(VmaAllocator_T*) VVL/layers/external/vma/vk_mem_alloc.h:11684:16 (libVkLayer_khronos_validation.so+0x9dbb4f) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #5 VmaBlockVector::CreateBlock(unsigned long, unsigned long*) VVL/layers/external/vma/vk_mem_alloc.h:12885:42 (libVkLayer_khronos_validation.so+0x9d77e9) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #6 VmaBlockVector::AllocatePage(unsigned long, unsigned long, VmaAllocationCreateInfo const&, VmaSuballocationType, VmaAllocation_T**) VVL/layers/external/vma/vk_mem_alloc.h:12584:13 (libVkLayer_khronos_validation.so+0x9d8d68) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #7 VmaBlockVector::Allocate(unsigned long, unsigned long, VmaAllocationCreateInfo const&, VmaSuballocationType, unsigned long, VmaAllocation_T**) VVL/layers/external/vma/vk_mem_alloc.h:12401:19 (libVkLayer_khronos_validation.so+0x9d8052) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #8 VmaAllocator_T::AllocateMemoryOfType(VmaPool_T*, unsigned long, unsigned long, bool, VkBuffer_T*, VkImage_T*, unsigned int, VmaAllocationCreateInfo const&, unsigned int, VmaSuballocationType, VmaDedicatedAllocationList&, VmaBlockVector&, unsigned long, VmaAllocation_T**) VVL/layers/external/vma/vk_mem_alloc.h:14558:27 (libVkLayer_khronos_validation.so+0x9e65f0) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #9 VmaAllocator_T::AllocateMemory(VkMemoryRequirements const&, bool, bool, VkBuffer_T*, VkImage_T*, unsigned int, VmaAllocationCreateInfo const&, VmaSuballocationType, unsigned long, VmaAllocation_T**) VVL/layers/external/vma/vk_mem_alloc.h:15077:19 (libVkLayer_khronos_validation.so+0x9e8e88) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #10 vmaCreateBuffer VVL/layers/external/vma/vk_mem_alloc.h:17067:26 (libVkLayer_khronos_validation.so+0x9f01e8) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #11 gpuav::DeviceMemoryBlock::CreateBuffer(Location const&, VkBufferCreateInfo const*, VmaAllocationCreateInfo const*) VVL/layers/gpu/resources/gpuav_resources.cpp:176:9 (libVkLayer_khronos_validation.so+0x108f6fa) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #12 gpuav::CommandBuffer::AllocateResources(Location const&) VVL/layers/gpu/resources/gpuav_subclasses.cpp:203:30 (libVkLayer_khronos_validation.so+0x107b540) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #13 gpuav::CommandBuffer::CommandBuffer(gpuav::Validator&, VkCommandBuffer_T*, VkCommandBufferAllocateInfo const*, vvl::CommandPool const*) VVL/layers/gpu/resources/gpuav_subclasses.cpp:132:5 (libVkLayer_khronos_validation.so+0x107b048) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #14 void std::_Construct<gpuav::CommandBuffer, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(gpuav::CommandBuffer*, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/stl_construct.h:119:25 (libVkLayer_khronos_validation.so+0xff0dae) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #15 void std::allocator_traits<std::allocator<void>>::construct<gpuav::CommandBuffer, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(std::allocator<void>&, gpuav::CommandBuffer*, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/alloc_traits.h:661:4 (libVkLayer_khronos_validation.so+0xff07d9) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #16 std::_Sp_counted_ptr_inplace<gpuav::CommandBuffer, std::allocator<void>, (__gnu_cxx::_Lock_policy)2>::_Sp_counted_ptr_inplace<gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(std::allocator<void>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr_base.h:604:4 (libVkLayer_khronos_validation.so+0xff07d9)
    #17 std::__shared_count<(__gnu_cxx::_Lock_policy)2>::__shared_count<gpuav::CommandBuffer, std::allocator<void>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(gpuav::CommandBuffer*&, std::_Sp_alloc_shared_tag<std::allocator<void>>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr_base.h:972:6 (libVkLayer_khronos_validation.so+0xff0464) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #18 std::__shared_ptr<gpuav::CommandBuffer, (__gnu_cxx::_Lock_policy)2>::__shared_ptr<std::allocator<void>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(std::_Sp_alloc_shared_tag<std::allocator<void>>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr_base.h:1712:14 (libVkLayer_khronos_validation.so+0xff0334) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #19 std::shared_ptr<gpuav::CommandBuffer>::shared_ptr<std::allocator<void>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(std::_Sp_alloc_shared_tag<std::allocator<void>>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr.h:464:4 (libVkLayer_khronos_validation.so+0xff0252) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #20 std::shared_ptr<std::enable_if<!is_array<gpuav::CommandBuffer>::value, gpuav::CommandBuffer>::type> std::make_shared<gpuav::CommandBuffer, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr.h:1009:14 (libVkLayer_khronos_validation.so+0xfe8561) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #21 gpuav::Validator::CreateCmdBufferState(VkCommandBuffer_T*, VkCommandBufferAllocateInfo const*, vvl::CommandPool const*) VVL/layers/gpu/core/gpuav_setup.cpp:72:57 (libVkLayer_khronos_validation.so+0xfe30c3) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #22 vvl::CommandPool::Allocate(VkCommandBufferAllocateInfo const*, VkCommandBuffer_T* const*) VVL/layers/state_tracker/cmd_buffer_state.cpp:131:32 (libVkLayer_khronos_validation.so+0x10bd072) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #23 ValidationStateTracker::PostCallRecordAllocateCommandBuffers(VkDevice_T*, VkCommandBufferAllocateInfo const*, VkCommandBuffer_T**, RecordObject const&) VVL/layers/state_tracker/state_tracker.cpp:2260:15 (libVkLayer_khronos_validation.so+0x1275cdb) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #24 vulkan_layer_chassis::AllocateCommandBuffers(VkDevice_T*, VkCommandBufferAllocateInfo const*, VkCommandBuffer_T**) VVL/layers/vulkan/generated/chassis.cpp:4227:24 (libVkLayer_khronos_validation.so+0xa83ed0) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
TSAN error 2 (submit & record):
WARNING: ThreadSanitizer: data race (pid=11987)
  Read of size 8 at 0x72180005fd58 by thread T4 (mutexes: write M0, write M1, write M2):
    #0 VmaDeviceMemoryBlock::GetMappedData() const VVL/layers/external/vma/vk_mem_alloc.h:5950:42 (libVkLayer_khronos_validation.so+0x9f85ed) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #1 VmaBlockVector::AllocatePage(unsigned long, unsigned long, VmaAllocationCreateInfo const&, VmaSuballocationType, VmaAllocation_T**) VVL/layers/external/vma/vk_mem_alloc.h:12504:64 (libVkLayer_khronos_validation.so+0x9d879c) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #2 VmaBlockVector::Allocate(unsigned long, unsigned long, VmaAllocationCreateInfo const&, VmaSuballocationType, unsigned long, VmaAllocation_T**) VVL/layers/external/vma/vk_mem_alloc.h:12401:19 (libVkLayer_khronos_validation.so+0x9d8052) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #3 VmaAllocator_T::AllocateMemoryOfType(VmaPool_T*, unsigned long, unsigned long, bool, VkBuffer_T*, VkImage_T*, unsigned int, VmaAllocationCreateInfo const&, unsigned int, VmaSuballocationType, VmaDedicatedAllocationList&, VmaBlockVector&, unsigned long, VmaAllocation_T**) VVL/layers/external/vma/vk_mem_alloc.h:14558:27 (libVkLayer_khronos_validation.so+0x9e65f0) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #4 VmaAllocator_T::AllocateMemory(VkMemoryRequirements const&, bool, bool, VkBuffer_T*, VkImage_T*, unsigned int, VmaAllocationCreateInfo const&, VmaSuballocationType, unsigned long, VmaAllocation_T**) VVL/layers/external/vma/vk_mem_alloc.h:15077:19 (libVkLayer_khronos_validation.so+0x9e8e88) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #5 vmaCreateBuffer VVL/layers/external/vma/vk_mem_alloc.h:17067:26 (libVkLayer_khronos_validation.so+0x9f01e8) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #6 gpuav::DeviceMemoryBlock::CreateBuffer(Location const&, VkBufferCreateInfo const*, VmaAllocationCreateInfo const*) VVL/layers/gpu/resources/gpuav_resources.cpp:176:9 (libVkLayer_khronos_validation.so+0x108f6fa) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #7 gpuav::DescriptorSet::GetCurrentState(gpuav::Validator&, Location const&) VVL/layers/gpu/descriptor_validation/gpuav_descriptor_set.cpp:252:24 (libVkLayer_khronos_validation.so+0xfc5e00) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #8 gpuav::UpdateBoundDescriptors(gpuav::Validator&, gpuav::CommandBuffer&, VkPipelineBindPoint, Location const&) VVL/layers/gpu/descriptor_validation/gpuav_descriptor_validation.cpp:116:62 (libVkLayer_khronos_validation.so+0xfbc0c5) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #9 gpuav::Validator::PostCallRecordCmdBindDescriptorSets(VkCommandBuffer_T*, VkPipelineBindPoint, VkPipelineLayout_T*, unsigned int, unsigned int, VkDescriptorSet_T* const*, unsigned int, unsigned int const*, RecordObject const&) VVL/layers/gpu/core/gpuav_record.cpp:231:5 (libVkLayer_khronos_validation.so+0xfda6d3) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #10 vulkan_layer_chassis::CmdBindDescriptorSets(VkCommandBuffer_T*, VkPipelineBindPoint, VkPipelineLayout_T*, unsigned int, unsigned int, VkDescriptorSet_T* const*, unsigned int, unsigned int const*) VVL/layers/vulkan/generated/chassis.cpp:4756:24 (libVkLayer_khronos_validation.so+0xa8928b) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)

  Previous write of size 8 at 0x72180005fd58 by thread T5 (mutexes: read M3, write M4):
    #0 VmaDeviceMemoryBlock::Unmap(VmaAllocator_T*, unsigned int) VVL/layers/external/vma/vk_mem_alloc.h:11881:27 (libVkLayer_khronos_validation.so+0x9d4e92) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #1 VmaAllocator_T::Unmap(VmaAllocation_T*) VVL/layers/external/vma/vk_mem_alloc.h:15595:21 (libVkLayer_khronos_validation.so+0x9ea8e9) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #2 vmaUnmapMemory VVL/layers/external/vma/vk_mem_alloc.h:16797:16 (libVkLayer_khronos_validation.so+0x9ef2a6) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #3 gpuav::DeviceMemoryBlock::UnmapMemory() const VVL/layers/gpu/resources/gpuav_resources.cpp:157:47 (libVkLayer_khronos_validation.so+0x108f25d) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #4 gpuav::CommandBuffer::UpdateBdaRangesBuffer(Location const&) VVL/layers/gpu/resources/gpuav_subclasses.cpp:334:26 (libVkLayer_khronos_validation.so+0x107c87d) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #5 gpuav::CommandBuffer::PreProcess(Location const&) VVL/layers/gpu/resources/gpuav_subclasses.cpp:438:17 (libVkLayer_khronos_validation.so+0x107d12e) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #6 gpuav::Queue::PreSubmit(std::vector<vvl::QueueSubmission, std::allocator<vvl::QueueSubmission>>&&) VVL/layers/gpu/resources/gpuav_subclasses.cpp:625:21 (libVkLayer_khronos_validation.so+0x107e77f) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #7 ValidationStateTracker::PreCallRecordQueueSubmit2(VkQueue_T*, unsigned int, VkSubmitInfo2 const*, VkFence_T*, RecordObject const&) VVL/layers/state_tracker/state_tracker.cpp:1298:48 (libVkLayer_khronos_validation.so+0x126ce84) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #8 vulkan_layer_chassis::QueueSubmit2(VkQueue_T*, unsigned int, VkSubmitInfo2 const*, VkFence_T*) VVL/layers/vulkan/generated/chassis.cpp:7914:24 (libVkLayer_khronos_validation.so+0xaa8bb4) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)

  Location is heap block of size 96 at 0x72180005fd00 allocated by thread T6:
    #0 aligned_alloc <null> (libclang_rt.tsan-x86_64.so+0x673b8) (BuildId: 83a3c8d2530f3f7484f54738b3cc92e3ba2a603f)
    #1 vma_aligned_alloc(unsigned long, unsigned long) VVL/layers/external/vma/vk_mem_alloc.h:2786:12 (libVkLayer_khronos_validation.so+0x9f2b65) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #2 VmaMalloc(VkAllocationCallbacks const*, unsigned long, unsigned long) VVL/layers/external/vma/vk_mem_alloc.h:3791:18 (libVkLayer_khronos_validation.so+0x9f2ab3) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #3 VmaMalloc(VmaAllocator_T*, unsigned long, unsigned long) VVL/layers/external/vma/vk_mem_alloc.h:11673:12 (libVkLayer_khronos_validation.so+0x9f3559) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #4 VmaDeviceMemoryBlock* VmaAllocate<VmaDeviceMemoryBlock>(VmaAllocator_T*) VVL/layers/external/vma/vk_mem_alloc.h:11684:16 (libVkLayer_khronos_validation.so+0x9dbb4f) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #5 VmaBlockVector::CreateBlock(unsigned long, unsigned long*) VVL/layers/external/vma/vk_mem_alloc.h:12885:42 (libVkLayer_khronos_validation.so+0x9d77e9) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #6 VmaBlockVector::AllocatePage(unsigned long, unsigned long, VmaAllocationCreateInfo const&, VmaSuballocationType, VmaAllocation_T**) VVL/layers/external/vma/vk_mem_alloc.h:12584:13 (libVkLayer_khronos_validation.so+0x9d8d68) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #7 VmaBlockVector::Allocate(unsigned long, unsigned long, VmaAllocationCreateInfo const&, VmaSuballocationType, unsigned long, VmaAllocation_T**) VVL/layers/external/vma/vk_mem_alloc.h:12401:19 (libVkLayer_khronos_validation.so+0x9d8052) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #8 VmaAllocator_T::AllocateMemoryOfType(VmaPool_T*, unsigned long, unsigned long, bool, VkBuffer_T*, VkImage_T*, unsigned int, VmaAllocationCreateInfo const&, unsigned int, VmaSuballocationType, VmaDedicatedAllocationList&, VmaBlockVector&, unsigned long, VmaAllocation_T**) VVL/layers/external/vma/vk_mem_alloc.h:14558:27 (libVkLayer_khronos_validation.so+0x9e65f0) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #9 VmaAllocator_T::AllocateMemory(VkMemoryRequirements const&, bool, bool, VkBuffer_T*, VkImage_T*, unsigned int, VmaAllocationCreateInfo const&, VmaSuballocationType, unsigned long, VmaAllocation_T**) VVL/layers/external/vma/vk_mem_alloc.h:15077:19 (libVkLayer_khronos_validation.so+0x9e8e88) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #10 vmaCreateBuffer VVL/layers/external/vma/vk_mem_alloc.h:17067:26 (libVkLayer_khronos_validation.so+0x9f01e8) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #11 gpuav::DeviceMemoryBlock::CreateBuffer(Location const&, VkBufferCreateInfo const*, VmaAllocationCreateInfo const*) VVL/layers/gpu/resources/gpuav_resources.cpp:176:9 (libVkLayer_khronos_validation.so+0x108f6fa) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #12 gpuav::CommandBuffer::AllocateResources(Location const&) VVL/layers/gpu/resources/gpuav_subclasses.cpp:203:30 (libVkLayer_khronos_validation.so+0x107b540) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #13 gpuav::CommandBuffer::CommandBuffer(gpuav::Validator&, VkCommandBuffer_T*, VkCommandBufferAllocateInfo const*, vvl::CommandPool const*) VVL/layers/gpu/resources/gpuav_subclasses.cpp:132:5 (libVkLayer_khronos_validation.so+0x107b048) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #14 void std::_Construct<gpuav::CommandBuffer, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(gpuav::CommandBuffer*, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/stl_construct.h:119:25 (libVkLayer_khronos_validation.so+0xff0dae) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #15 void std::allocator_traits<std::allocator<void>>::construct<gpuav::CommandBuffer, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(std::allocator<void>&, gpuav::CommandBuffer*, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/alloc_traits.h:661:4 (libVkLayer_khronos_validation.so+0xff07d9) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #16 std::_Sp_counted_ptr_inplace<gpuav::CommandBuffer, std::allocator<void>, (__gnu_cxx::_Lock_policy)2>::_Sp_counted_ptr_inplace<gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(std::allocator<void>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr_base.h:604:4 (libVkLayer_khronos_validation.so+0xff07d9)
    #17 std::__shared_count<(__gnu_cxx::_Lock_policy)2>::__shared_count<gpuav::CommandBuffer, std::allocator<void>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(gpuav::CommandBuffer*&, std::_Sp_alloc_shared_tag<std::allocator<void>>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr_base.h:972:6 (libVkLayer_khronos_validation.so+0xff0464) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #18 std::__shared_ptr<gpuav::CommandBuffer, (__gnu_cxx::_Lock_policy)2>::__shared_ptr<std::allocator<void>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(std::_Sp_alloc_shared_tag<std::allocator<void>>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr_base.h:1712:14 (libVkLayer_khronos_validation.so+0xff0334) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #19 std::shared_ptr<gpuav::CommandBuffer>::shared_ptr<std::allocator<void>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(std::_Sp_alloc_shared_tag<std::allocator<void>>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr.h:464:4 (libVkLayer_khronos_validation.so+0xff0252) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #20 std::shared_ptr<std::enable_if<!is_array<gpuav::CommandBuffer>::value, gpuav::CommandBuffer>::type> std::make_shared<gpuav::CommandBuffer, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr.h:1009:14 (libVkLayer_khronos_validation.so+0xfe8561) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #21 gpuav::Validator::CreateCmdBufferState(VkCommandBuffer_T*, VkCommandBufferAllocateInfo const*, vvl::CommandPool const*) VVL/layers/gpu/core/gpuav_setup.cpp:72:57 (libVkLayer_khronos_validation.so+0xfe30c3) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #22 vvl::CommandPool::Allocate(VkCommandBufferAllocateInfo const*, VkCommandBuffer_T* const*) VVL/layers/state_tracker/cmd_buffer_state.cpp:131:32 (libVkLayer_khronos_validation.so+0x10bd072) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #23 ValidationStateTracker::PostCallRecordAllocateCommandBuffers(VkDevice_T*, VkCommandBufferAllocateInfo const*, VkCommandBuffer_T**, RecordObject const&) VVL/layers/state_tracker/state_tracker.cpp:2260:15 (libVkLayer_khronos_validation.so+0x1275cdb) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #24 vulkan_layer_chassis::AllocateCommandBuffers(VkDevice_T*, VkCommandBufferAllocateInfo const*, VkCommandBuffer_T**) VVL/layers/vulkan/generated/chassis.cpp:4227:24 (libVkLayer_khronos_validation.so+0xa83ed0) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
TSAN error 3 (record & allocate):
WARNING: ThreadSanitizer: data race (pid=11987)
  Write of size 8 at 0x721800046018 by thread T4 (mutexes: write M0, write M1, write M2):
    #0 VmaDeviceMemoryBlock::Unmap(VmaAllocator_T*, unsigned int) VVL/layers/external/vma/vk_mem_alloc.h:11881:27 (libVkLayer_khronos_validation.so+0x9d4e92) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #1 VmaAllocator_T::Unmap(VmaAllocation_T*) VVL/layers/external/vma/vk_mem_alloc.h:15595:21 (libVkLayer_khronos_validation.so+0x9ea8e9) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #2 vmaUnmapMemory VVL/layers/external/vma/vk_mem_alloc.h:16797:16 (libVkLayer_khronos_validation.so+0x9ef2a6) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #3 gpuav::DeviceMemoryBlock::UnmapMemory() const VVL/layers/gpu/resources/gpuav_resources.cpp:157:47 (libVkLayer_khronos_validation.so+0x108f25d) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #4 gpuav::DescriptorSet::GetCurrentState(gpuav::Validator&, Location const&) VVL/layers/gpu/descriptor_validation/gpuav_descriptor_set.cpp:291:24 (libVkLayer_khronos_validation.so+0xfc60c4) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #5 gpuav::UpdateBoundDescriptors(gpuav::Validator&, gpuav::CommandBuffer&, VkPipelineBindPoint, Location const&) VVL/layers/gpu/descriptor_validation/gpuav_descriptor_validation.cpp:116:62 (libVkLayer_khronos_validation.so+0xfbc0c5) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #6 gpuav::Validator::PostCallRecordCmdBindDescriptorSets(VkCommandBuffer_T*, VkPipelineBindPoint, VkPipelineLayout_T*, unsigned int, unsigned int, VkDescriptorSet_T* const*, unsigned int, unsigned int const*, RecordObject const&) VVL/layers/gpu/core/gpuav_record.cpp:231:5 (libVkLayer_khronos_validation.so+0xfda6d3) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #7 vulkan_layer_chassis::CmdBindDescriptorSets(VkCommandBuffer_T*, VkPipelineBindPoint, VkPipelineLayout_T*, unsigned int, unsigned int, VkDescriptorSet_T* const*, unsigned int, unsigned int const*) VVL/layers/vulkan/generated/chassis.cpp:4756:24 (libVkLayer_khronos_validation.so+0xa8928b) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)

  Previous read of size 8 at 0x721800046018 by thread T5 (mutexes: write M3):
    #0 VmaDeviceMemoryBlock::GetMappedData() const VVL/layers/external/vma/vk_mem_alloc.h:5950:42 (libVkLayer_khronos_validation.so+0x9f85ed) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #1 VmaBlockVector::AllocatePage(unsigned long, unsigned long, VmaAllocationCreateInfo const&, VmaSuballocationType, VmaAllocation_T**) VVL/layers/external/vma/vk_mem_alloc.h:12504:64 (libVkLayer_khronos_validation.so+0x9d879c) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #2 VmaBlockVector::Allocate(unsigned long, unsigned long, VmaAllocationCreateInfo const&, VmaSuballocationType, unsigned long, VmaAllocation_T**) VVL/layers/external/vma/vk_mem_alloc.h:12401:19 (libVkLayer_khronos_validation.so+0x9d8052) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #3 VmaAllocator_T::AllocateMemoryOfType(VmaPool_T*, unsigned long, unsigned long, bool, VkBuffer_T*, VkImage_T*, unsigned int, VmaAllocationCreateInfo const&, unsigned int, VmaSuballocationType, VmaDedicatedAllocationList&, VmaBlockVector&, unsigned long, VmaAllocation_T**) VVL/layers/external/vma/vk_mem_alloc.h:14558:27 (libVkLayer_khronos_validation.so+0x9e65f0) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #4 VmaAllocator_T::AllocateMemory(VkMemoryRequirements const&, bool, bool, VkBuffer_T*, VkImage_T*, unsigned int, VmaAllocationCreateInfo const&, VmaSuballocationType, unsigned long, VmaAllocation_T**) VVL/layers/external/vma/vk_mem_alloc.h:15077:19 (libVkLayer_khronos_validation.so+0x9e8e88) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #5 vmaCreateBuffer VVL/layers/external/vma/vk_mem_alloc.h:17067:26 (libVkLayer_khronos_validation.so+0x9f01e8) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #6 gpuav::DeviceMemoryBlock::CreateBuffer(Location const&, VkBufferCreateInfo const*, VmaAllocationCreateInfo const*) VVL/layers/gpu/resources/gpuav_resources.cpp:176:9 (libVkLayer_khronos_validation.so+0x108f6fa) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #7 gpuav::CommandBuffer::AllocateResources(Location const&) VVL/layers/gpu/resources/gpuav_subclasses.cpp:203:30 (libVkLayer_khronos_validation.so+0x107b540) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #8 gpuav::CommandBuffer::CommandBuffer(gpuav::Validator&, VkCommandBuffer_T*, VkCommandBufferAllocateInfo const*, vvl::CommandPool const*) VVL/layers/gpu/resources/gpuav_subclasses.cpp:132:5 (libVkLayer_khronos_validation.so+0x107b048) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #9 void std::_Construct<gpuav::CommandBuffer, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(gpuav::CommandBuffer*, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/stl_construct.h:119:25 (libVkLayer_khronos_validation.so+0xff0dae) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #10 void std::allocator_traits<std::allocator<void>>::construct<gpuav::CommandBuffer, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(std::allocator<void>&, gpuav::CommandBuffer*, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/alloc_traits.h:661:4 (libVkLayer_khronos_validation.so+0xff07d9) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #11 std::_Sp_counted_ptr_inplace<gpuav::CommandBuffer, std::allocator<void>, (__gnu_cxx::_Lock_policy)2>::_Sp_counted_ptr_inplace<gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(std::allocator<void>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr_base.h:604:4 (libVkLayer_khronos_validation.so+0xff07d9)
    #12 std::__shared_count<(__gnu_cxx::_Lock_policy)2>::__shared_count<gpuav::CommandBuffer, std::allocator<void>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(gpuav::CommandBuffer*&, std::_Sp_alloc_shared_tag<std::allocator<void>>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr_base.h:972:6 (libVkLayer_khronos_validation.so+0xff0464) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #13 std::__shared_ptr<gpuav::CommandBuffer, (__gnu_cxx::_Lock_policy)2>::__shared_ptr<std::allocator<void>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(std::_Sp_alloc_shared_tag<std::allocator<void>>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr_base.h:1712:14 (libVkLayer_khronos_validation.so+0xff0334) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #14 std::shared_ptr<gpuav::CommandBuffer>::shared_ptr<std::allocator<void>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(std::_Sp_alloc_shared_tag<std::allocator<void>>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr.h:464:4 (libVkLayer_khronos_validation.so+0xff0252) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #15 std::shared_ptr<std::enable_if<!is_array<gpuav::CommandBuffer>::value, gpuav::CommandBuffer>::type> std::make_shared<gpuav::CommandBuffer, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr.h:1009:14 (libVkLayer_khronos_validation.so+0xfe8561) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #16 gpuav::Validator::CreateCmdBufferState(VkCommandBuffer_T*, VkCommandBufferAllocateInfo const*, vvl::CommandPool const*) VVL/layers/gpu/core/gpuav_setup.cpp:72:57 (libVkLayer_khronos_validation.so+0xfe30c3) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #17 vvl::CommandPool::Allocate(VkCommandBufferAllocateInfo const*, VkCommandBuffer_T* const*) VVL/layers/state_tracker/cmd_buffer_state.cpp:131:32 (libVkLayer_khronos_validation.so+0x10bd072) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #18 ValidationStateTracker::PostCallRecordAllocateCommandBuffers(VkDevice_T*, VkCommandBufferAllocateInfo const*, VkCommandBuffer_T**, RecordObject const&) VVL/layers/state_tracker/state_tracker.cpp:2260:15 (libVkLayer_khronos_validation.so+0x1275cdb) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #19 vulkan_layer_chassis::AllocateCommandBuffers(VkDevice_T*, VkCommandBufferAllocateInfo const*, VkCommandBuffer_T**) VVL/layers/vulkan/generated/chassis.cpp:4227:24 (libVkLayer_khronos_validation.so+0xa83ed0) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)

  Location is heap block of size 96 at 0x721800045fc0 allocated by main thread:
    #0 aligned_alloc <null> (libclang_rt.tsan-x86_64.so+0x673b8) (BuildId: 83a3c8d2530f3f7484f54738b3cc92e3ba2a603f)
    #1 vma_aligned_alloc(unsigned long, unsigned long) VVL/layers/external/vma/vk_mem_alloc.h:2786:12 (libVkLayer_khronos_validation.so+0x9f2b65) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #2 VmaMalloc(VkAllocationCallbacks const*, unsigned long, unsigned long) VVL/layers/external/vma/vk_mem_alloc.h:3791:18 (libVkLayer_khronos_validation.so+0x9f2ab3) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #3 VmaMalloc(VmaAllocator_T*, unsigned long, unsigned long) VVL/layers/external/vma/vk_mem_alloc.h:11673:12 (libVkLayer_khronos_validation.so+0x9f3559) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #4 VmaDeviceMemoryBlock* VmaAllocate<VmaDeviceMemoryBlock>(VmaAllocator_T*) VVL/layers/external/vma/vk_mem_alloc.h:11684:16 (libVkLayer_khronos_validation.so+0x9dbb4f) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #5 VmaBlockVector::CreateBlock(unsigned long, unsigned long*) VVL/layers/external/vma/vk_mem_alloc.h:12885:42 (libVkLayer_khronos_validation.so+0x9d77e9) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #6 VmaBlockVector::AllocatePage(unsigned long, unsigned long, VmaAllocationCreateInfo const&, VmaSuballocationType, VmaAllocation_T**) VVL/layers/external/vma/vk_mem_alloc.h:12584:13 (libVkLayer_khronos_validation.so+0x9d8d68) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #7 VmaBlockVector::Allocate(unsigned long, unsigned long, VmaAllocationCreateInfo const&, VmaSuballocationType, unsigned long, VmaAllocation_T**) VVL/layers/external/vma/vk_mem_alloc.h:12401:19 (libVkLayer_khronos_validation.so+0x9d8052) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #8 VmaAllocator_T::AllocateMemoryOfType(VmaPool_T*, unsigned long, unsigned long, bool, VkBuffer_T*, VkImage_T*, unsigned int, VmaAllocationCreateInfo const&, unsigned int, VmaSuballocationType, VmaDedicatedAllocationList&, VmaBlockVector&, unsigned long, VmaAllocation_T**) VVL/layers/external/vma/vk_mem_alloc.h:14558:27 (libVkLayer_khronos_validation.so+0x9e65f0) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #9 VmaAllocator_T::AllocateMemory(VkMemoryRequirements const&, bool, bool, VkBuffer_T*, VkImage_T*, unsigned int, VmaAllocationCreateInfo const&, VmaSuballocationType, unsigned long, VmaAllocation_T**) VVL/layers/external/vma/vk_mem_alloc.h:15077:19 (libVkLayer_khronos_validation.so+0x9e8e88) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #10 vmaCreateBuffer VVL/layers/external/vma/vk_mem_alloc.h:17067:26 (libVkLayer_khronos_validation.so+0x9f01e8) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #11 gpuav::DeviceMemoryBlock::CreateBuffer(Location const&, VkBufferCreateInfo const*, VmaAllocationCreateInfo const*) VVL/layers/gpu/resources/gpuav_resources.cpp:176:9 (libVkLayer_khronos_validation.so+0x108f6fa) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #12 gpuav::CommandBuffer::AllocateResources(Location const&) VVL/layers/gpu/resources/gpuav_subclasses.cpp:203:30 (libVkLayer_khronos_validation.so+0x107b540) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #13 gpuav::CommandBuffer::CommandBuffer(gpuav::Validator&, VkCommandBuffer_T*, VkCommandBufferAllocateInfo const*, vvl::CommandPool const*) VVL/layers/gpu/resources/gpuav_subclasses.cpp:132:5 (libVkLayer_khronos_validation.so+0x107b048) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #14 void std::_Construct<gpuav::CommandBuffer, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(gpuav::CommandBuffer*, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/stl_construct.h:119:25 (libVkLayer_khronos_validation.so+0xff0dae) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #15 void std::allocator_traits<std::allocator<void>>::construct<gpuav::CommandBuffer, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(std::allocator<void>&, gpuav::CommandBuffer*, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/alloc_traits.h:661:4 (libVkLayer_khronos_validation.so+0xff07d9) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #16 std::_Sp_counted_ptr_inplace<gpuav::CommandBuffer, std::allocator<void>, (__gnu_cxx::_Lock_policy)2>::_Sp_counted_ptr_inplace<gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(std::allocator<void>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr_base.h:604:4 (libVkLayer_khronos_validation.so+0xff07d9)
    #17 std::__shared_count<(__gnu_cxx::_Lock_policy)2>::__shared_count<gpuav::CommandBuffer, std::allocator<void>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(gpuav::CommandBuffer*&, std::_Sp_alloc_shared_tag<std::allocator<void>>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr_base.h:972:6 (libVkLayer_khronos_validation.so+0xff0464) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #18 std::__shared_ptr<gpuav::CommandBuffer, (__gnu_cxx::_Lock_policy)2>::__shared_ptr<std::allocator<void>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(std::_Sp_alloc_shared_tag<std::allocator<void>>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr_base.h:1712:14 (libVkLayer_khronos_validation.so+0xff0334) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #19 std::shared_ptr<gpuav::CommandBuffer>::shared_ptr<std::allocator<void>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(std::_Sp_alloc_shared_tag<std::allocator<void>>, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr.h:464:4 (libVkLayer_khronos_validation.so+0xff0252) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #20 std::shared_ptr<std::enable_if<!is_array<gpuav::CommandBuffer>::value, gpuav::CommandBuffer>::type> std::make_shared<gpuav::CommandBuffer, gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&>(gpuav::Validator&, VkCommandBuffer_T*&, VkCommandBufferAllocateInfo const*&, vvl::CommandPool const*&) /usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/shared_ptr.h:1009:14 (libVkLayer_khronos_validation.so+0xfe8561) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #21 gpuav::Validator::CreateCmdBufferState(VkCommandBuffer_T*, VkCommandBufferAllocateInfo const*, vvl::CommandPool const*) VVL/layers/gpu/core/gpuav_setup.cpp:72:57 (libVkLayer_khronos_validation.so+0xfe30c3) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #22 vvl::CommandPool::Allocate(VkCommandBufferAllocateInfo const*, VkCommandBuffer_T* const*) VVL/layers/state_tracker/cmd_buffer_state.cpp:131:32 (libVkLayer_khronos_validation.so+0x10bd072) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #23 ValidationStateTracker::PostCallRecordAllocateCommandBuffers(VkDevice_T*, VkCommandBufferAllocateInfo const*, VkCommandBuffer_T**, RecordObject const&) VVL/layers/state_tracker/state_tracker.cpp:2260:15 (libVkLayer_khronos_validation.so+0x1275cdb) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)
    #24 vulkan_layer_chassis::AllocateCommandBuffers(VkDevice_T*, VkCommandBufferAllocateInfo const*, VkCommandBuffer_T**) VVL/layers/vulkan/generated/chassis.cpp:4227:24 (libVkLayer_khronos_validation.so+0xa83ed0) (BuildId: 116bb3f83830d9d8e894cbf9f3dec2294bac2744)

The full TSAN reports with mutex information are attached, because they exceed the maximum comment length.
vvl-vma-data-races.md

Core and sync. validation (including QueueSubmit) don't report any errors.

Expected behavior

No data races

@spencer-lunarg spencer-lunarg added the GPU-AV GPU Assisted Validation label Oct 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
GPU-AV GPU Assisted Validation
Projects
None yet
Development

No branches or pull requests

2 participants