Function Prototype

vkSetDeviceMemoryPriorityEXT

Change a memory allocation priority

To modify the priority of an existing memory allocation, call:

void vkSetDeviceMemoryPriorityEXT(
    VkDevice       device,
    VkDeviceMemory memory,
    float          priority);
  • device is the logical device that owns the memory.
  • memory is the VkDeviceMemory object to which the new priority will be applied.
  • priority is a floating-point value between 0 and 1, indicating the priority of the allocation relative to other memory allocations. Larger values are higher priority. The granularity of the priorities is implementation-dependent.

Memory allocations with higher priority may be more likely to stay in device-local memory when the system is under memory pressure.

Valid Usage

VUID-vkSetDeviceMemoryPriorityEXT-priority-06258

priority must be between 0 and 1, inclusive

Valid Usage (Implicit)

VUID-vkSetDeviceMemoryPriorityEXT-memory-parent

memory must have been created, allocated, or retrieved from device