MCPcopy Create free account
hub / github.com/FlaxEngine/FlaxEngine / MergeBlock

Method MergeBlock

Source/ThirdParty/VulkanMemoryAllocator/vk_mem_alloc.h:9485–9496  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

9483}
9484
9485void VmaBlockMetadata_TLSF::MergeBlock(Block* block, Block* prev)
9486{
9487 VMA_ASSERT(block->prevPhysical == prev && "Cannot merge separate physical regions!");
9488 VMA_ASSERT(!prev->IsFree() && "Cannot merge block that belongs to free list!");
9489
9490 block->offset = prev->offset;
9491 block->size += prev->size;
9492 block->prevPhysical = prev->prevPhysical;
9493 if (block->prevPhysical)
9494 block->prevPhysical->nextPhysical = block;
9495 m_BlockAllocator.Free(prev);
9496}
9497
9498VmaBlockMetadata_TLSF::Block* VmaBlockMetadata_TLSF::FindFreeBlock(VkDeviceSize size, uint32_t& listIndex) const
9499{

Callers

nothing calls this directly

Calls 2

IsFreeMethod · 0.45
FreeMethod · 0.45

Tested by

no test coverage detected