Constant vk_mem_alloc::ffi::VmaAllocatorCreateFlagBits_VMA_ALLOCATOR_CREATE_AMD_DEVICE_COHERENT_MEMORY_BIT
source · [−]pub const VmaAllocatorCreateFlagBits_VMA_ALLOCATOR_CREATE_AMD_DEVICE_COHERENT_MEMORY_BIT: VmaAllocatorCreateFlagBits = 16;
Expand description
Enables usage of VK_AMD_device_coherent_memory extension.
You may set this flag only if you:
- found out that this device extension is supported and enabled it while creating Vulkan device passed as VmaAllocatorCreateInfo::device,
- checked that
VkPhysicalDeviceCoherentMemoryFeaturesAMD::deviceCoherentMemory
is true and set it while creating the Vulkan device, - want it to be used internally by this library.
The extension and accompanying device feature provide access to memory types with
VK_MEMORY_PROPERTY_DEVICE_COHERENT_BIT_AMD
and VK_MEMORY_PROPERTY_DEVICE_UNCACHED_BIT_AMD
flags.
They are useful mostly for writing breadcrumb markers - a common method for debugging GPU crash/hang/TDR.
When the extension is not enabled, such memory types are still enumerated, but their usage is illegal.
To protect from this error, if you don’t create the allocator with this flag, it will refuse to allocate any memory or create a custom pool in such memory type,
returning VK_ERROR_FEATURE_NOT_PRESENT
.