File tree Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -1836,6 +1836,9 @@ VMA_CALL_PRE void VMA_CALL_POST vmaDestroyPool(
18361836\param allocator Allocator object.
18371837\param pool Pool object.
18381838\param[out] pPoolStats Statistics of specified pool.
1839+
1840+ Note that when using the pool from multiple threads, returned information may immediately
1841+ become outdated.
18391842*/
18401843VMA_CALL_PRE void VMA_CALL_POST vmaGetPoolStatistics(
18411844 VmaAllocator VMA_NOT_NULL allocator,
@@ -11605,6 +11608,10 @@ void VmaBlockVector::Free(const VmaAllocation hAllocation)
1160511608 }
1160611609
1160711610 IncrementallySortBlocks();
11611+
11612+ m_hAllocator->m_Budget.RemoveAllocation(m_hAllocator->MemoryTypeIndexToHeapIndex(m_MemoryTypeIndex), hAllocation->GetSize());
11613+ hAllocation->Destroy(m_hAllocator);
11614+ m_hAllocator->m_AllocationObjectAllocator.Free(hAllocation);
1160811615 }
1160911616
1161011617 // Destruction of a free block. Deferred until this point, outside of mutex
@@ -11615,10 +11622,6 @@ void VmaBlockVector::Free(const VmaAllocation hAllocation)
1161511622 pBlockToDelete->Destroy(m_hAllocator);
1161611623 vma_delete(m_hAllocator, pBlockToDelete);
1161711624 }
11618-
11619- m_hAllocator->m_Budget.RemoveAllocation(m_hAllocator->MemoryTypeIndexToHeapIndex(m_MemoryTypeIndex), hAllocation->GetSize());
11620- hAllocation->Destroy(m_hAllocator);
11621- m_hAllocator->m_AllocationObjectAllocator.Free(hAllocation);
1162211625}
1162311626
1162411627VkDeviceSize VmaBlockVector::CalcMaxBlockSize() const
You can’t perform that action at this time.
0 commit comments