You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The best practices layer spits out warnings like this:
Allocating 4096 memory of type 0x1 (id 0) in heap 0
vk Validation Performance Warning: [ UNASSIGNED-BestPractices-vkAllocateMemory-small-allocation ] Object 0: handle = 0x55e896a0f0b0, type = VK_OBJECT_TYPE_DEVICE; | MessageID = 0xdc18ad6b | vkAllocateMemory(): Allocating a VkDeviceMemory of size 4096. This is a very small allocation (current threshold is 262144 bytes). You should make large allocations and sub-allocate from one large VkDeviceMemory.
using VkDevice: anon (0x55e896a0f0b0)
vk Validation Performance Warning: [ UNASSIGNED-BestPractices-vkBindMemory-small-dedicated-allocation ] Object 0: handle = 0x55e896a0f0b0, type = VK_OBJECT_TYPE_DEVICE; | MessageID = 0xb3d4346b | vkBindImageMemory(): Trying to bind VkImage 0x157c000000157c[] to a memory block which is fully consumed by the image. The required size of the allocation is 4096, but smaller images like this should be sub-allocated from larger memory blocks. (Current threshold is 1048576 bytes.)
using VkDevice: anon (0x55e896a0f0b0)
vk Validation Performance Warning: [ UNASSIGNED-BestPractices-vkAllocateMemory-small-allocation ] Object 0: handle = 0x55e896a0f0b0, type = VK_OBJECT_TYPE_DEVICE; | MessageID = 0xdc18ad6b | vkAllocateMemory(): Allocating a VkDeviceMemory of size 4096. This is a very small allocation (current threshold is 262144 bytes). You should make large allocations and sub-allocate from one large VkDeviceMemory.
using VkDevice: anon (0x55e896a0f0b0)
Imported 4096 of memory from fd: 7 (dedicated)
vk Validation Performance Warning: [ UNASSIGNED-BestPractices-vkBindMemory-small-dedicated-allocation ] Object 0: handle = 0x55e896a0f0b0, type = VK_OBJECT_TYPE_DEVICE; | MessageID = 0xb3d4346b | vkBindImageMemory(): Trying to bind VkImage 0x157e000000157e[] to a memory block which is fully consumed by the image. The required size of the allocation is 4096, but smaller images like this should be sub-allocated from larger memory blocks. (Current threshold is 1048576 bytes.)
using VkDevice: anon (0x55e896a0f0b0)
However, this is in spite of the fact that I am trying to serve memory to an image which has VkMemoryDedicatedRequirementsKHR.requiresDedicatedAllocation set to true, so there is no other way I could be allocating/binding memory here - no matter how wasteful it may seem to the layer. (Moreoever, one of the two allocations isn't even an allocation - it's a memory import from an FD, the size of which we have no control over)
I suggest adding a simple check to the best practices layer to disable those two VUIDs when serving images that require dedicated allocations.
The text was updated successfully, but these errors were encountered:
The best practices layer spits out warnings like this:
However, this is in spite of the fact that I am trying to serve memory to an image which has
VkMemoryDedicatedRequirementsKHR.requiresDedicatedAllocation
set totrue
, so there is no other way I could be allocating/binding memory here - no matter how wasteful it may seem to the layer. (Moreoever, one of the two allocations isn't even an allocation - it's a memory import from an FD, the size of which we have no control over)I suggest adding a simple check to the best practices layer to disable those two VUIDs when serving images that require dedicated allocations.
The text was updated successfully, but these errors were encountered: